proving

package
v0.5.6 Latest Latest
Warning

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

Go to latest
Published: May 8, 2023 License: MIT Imports: 8 Imported by: 1

Documentation

Index

Constants

View Source
const (
	NumWorkers = 1 // Number of workers creating a proof in parallel. Each one will max out one CPU core.

	BlocksPerWorker = 1 << 24 // How many AES blocks are contained per batch sent to a worker. Larger values will increase memory usage, but speed up the proof generation.
)

TODO (mafa): these should be configurable by a node.

Variables

This section is empty.

Functions

func Generate added in v0.4.0

func Generate(ctx context.Context, ch shared.Challenge, cfg config.Config, logger shared.Logger, opts ...OptionFunc) (*shared.Proof, *shared.ProofMetadata, error)

TODO (mafa): replace Logger with zap.

Types

type OptionFunc added in v0.4.0

type OptionFunc func(*option) error

func WithDataSource added in v0.4.0

func WithDataSource(cfg config.Config, nodeId, commitmentAtxId []byte, datadir string) OptionFunc

WithDataSource sets the data source to use for the proof.

func WithNonces added in v0.5.1

func WithNonces(nonces uint) OptionFunc

func WithPowScryptParams added in v0.5.1

func WithPowScryptParams(params config.ScryptParams) OptionFunc

func WithThreads added in v0.5.2

func WithThreads(threads uint) OptionFunc

Jump to

Keyboard shortcuts

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