asterisc

package
v1.9.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 5, 2024 License: MIT Imports: 17 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AsteriscPreStateProvider

type AsteriscPreStateProvider struct {
	// contains filtered or unexported fields
}

func NewPrestateProvider

func NewPrestateProvider(prestate string) *AsteriscPreStateProvider

func (*AsteriscPreStateProvider) AbsolutePreStateCommitment

func (p *AsteriscPreStateProvider) AbsolutePreStateCommitment(_ context.Context) (common.Hash, error)

func (*AsteriscPreStateProvider) PrestatePath added in v1.9.1

func (p *AsteriscPreStateProvider) PrestatePath() string

type AsteriscTraceProvider

type AsteriscTraceProvider struct {
	types.PrestateProvider
	// contains filtered or unexported fields
}

func NewTraceProvider

func NewTraceProvider(logger log.Logger, m vm.Metricer, cfg vm.Config, vmCfg vm.OracleServerExecutor, prestateProvider types.PrestateProvider, asteriscPrestate string, localInputs utils.LocalGameInputs, dir string, gameDepth types.Depth) *AsteriscTraceProvider

func (*AsteriscTraceProvider) Get

func (*AsteriscTraceProvider) GetL2BlockNumberChallenge added in v1.7.6

func (p *AsteriscTraceProvider) GetL2BlockNumberChallenge(_ context.Context) (*types.InvalidL2BlockNumberChallenge, error)

func (*AsteriscTraceProvider) GetStepData

type AsteriscTraceProviderForTest

type AsteriscTraceProviderForTest struct {
	*AsteriscTraceProvider
}

AsteriscTraceProviderForTest is a AsteriscTraceProvider that can find the step referencing the preimage read Only to be used for testing

func NewTraceProviderForTest

func NewTraceProviderForTest(logger log.Logger, m vm.Metricer, cfg *config.Config, localInputs utils.LocalGameInputs, dir string, gameDepth types.Depth) *AsteriscTraceProviderForTest

func (*AsteriscTraceProviderForTest) FindStep

func (p *AsteriscTraceProviderForTest) FindStep(ctx context.Context, start uint64, preimage utils.PreimageOpt) (uint64, error)

type VMState

type VMState struct {
	PC        uint64      `json:"pc"`
	Exited    bool        `json:"exited"`
	Step      uint64      `json:"step"`
	Witness   []byte      `json:"witness"`
	StateHash common.Hash `json:"stateHash"`
}

The state struct will be read from json. other fields included in json are specific to FPVM implementation, and not required for trace provider.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL