execution

package
v0.29.6 Latest Latest
Warning

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

Go to latest
Published: Jan 19, 2023 License: AGPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateChunk

func GenerateChunk(colIndex int,
	startState, endState flow.StateCommitment,
	blockID, eventsCollection flow.Identifier, txNumber uint64) *flow.Chunk

GenerateChunk creates a chunk from the provided computation data.

func GenerateChunkDataPack

func GenerateChunkDataPack(
	chunkID flow.Identifier,
	startState flow.StateCommitment,
	collection *flow.Collection,
	proof flow.StorageProof,
) *flow.ChunkDataPack

func GenerateExecutionResultAndChunkDataPacks

func GenerateExecutionResultAndChunkDataPacks(
	metrics module.ExecutionMetrics,
	prevResultId flow.Identifier,
	startState flow.StateCommitment,
	result *ComputationResult) (
	endState flow.StateCommitment,
	chdps []*flow.ChunkDataPack,
	executionResult *flow.ExecutionResult,
	err error,
)

func GenerateExecutionResultForBlock

func GenerateExecutionResultForBlock(
	previousErID flow.Identifier,
	block *flow.Block,
	chunks []*flow.Chunk,
	serviceEvents []flow.Event,
	executionDataID flow.Identifier,
) (*flow.ExecutionResult, error)

GenerateExecutionResultForBlock creates new ExecutionResult for a block from the provided chunk results.

Types

type ComputationOrder

type ComputationOrder struct {
	Block      *entity.ExecutableBlock
	View       *delta.View
	StartState flow.StateCommitment
}

type ComputationResult

type ComputationResult struct {
	ExecutableBlock        *entity.ExecutableBlock
	StateSnapshots         []*delta.SpockSnapshot
	StateCommitments       []flow.StateCommitment
	Proofs                 [][]byte
	Events                 []flow.EventsList
	EventsHashes           []flow.Identifier
	ServiceEvents          flow.EventsList
	TransactionResults     []flow.TransactionResult
	TransactionResultIndex []int
	ComputationIntensities meter.MeteredComputationIntensities
	TrieUpdates            []*ledger.TrieUpdate
	ExecutionDataID        flow.Identifier
	SpockSignatures        []crypto.Signature
}

func NewEmptyComputationResult

func NewEmptyComputationResult(block *entity.ExecutableBlock) *ComputationResult

func (*ComputationResult) AddCollection

func (cr *ComputationResult) AddCollection(snapshot *delta.SpockSnapshot)

func (*ComputationResult) AddTransactionResult

func (cr *ComputationResult) AddTransactionResult(
	collectionIndex int,
	txn *fvm.TransactionProcedure,
)

func (*ComputationResult) BlockStats

func (*ComputationResult) CollectionStats

func (cr *ComputationResult) CollectionStats(
	collectionIndex int,
) module.ExecutionResultStats

Jump to

Keyboard shortcuts

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