Skip to main content

Tracer

The tracer is part of the LinethLineth (Formerly the Linea Stack) The open-source ZK-rollup stack, codebase, and technical protocol that's the foundation of Linea Mainnet. Operators can deploy this stack to launch their own Ethereum-compatible L2 or L3 networks. sequencer. The tracer is a Besu plugin bundled with Linea BesuLinea Besu The execution client that Linea Mainnet and other Lineth deployments run to execute transactions and maintain EVM state. Linea Besu is a build of the Besu execution client, extended with plugins such as the sequencer and tracer that add ZK-rollup functionality.. It generates the data the prover needs to create ZK proofsZero-knowledge proof A cryptographic method that allows an individual to prove that a statement is true without conveying any additional information. This is useful for scaling blockchain networks through rollups, because it reduces the amount of information you have to provide to lower layers., and the data the sequencer needs to keep blocks provable.

A trace records the operations the EVMEthereum Virtual Machine (EVM) A stack-based virtual machine that executes bytecode. In Ethereum, the execution model specifies how the system state is altered given a series of bytecode instructions and a small tuple of environmental data. This is specified through a formal model of a virtual state machine. performs during execution: the state of the network, and the state of the accounts involved in a transaction, at each granular step of that transaction's execution.

How it works

The tracer produces data on request, at two points in the pipeline.

While the sequencer builds a block, the tracer counts the trace lines each candidate transaction would generate, so the sequencer can reject transactions that exceed a module limit and stop adding transactions once the block reaches its limits.

Once blocks are built, the coordinator uses the tracer to prepare them for proving:

  1. The coordinator requests the trace counts for each new block.
  2. Using those counts, it decides how many consecutive blocks to conflate into one batch.
  3. When it closes a batch, it requests the conflated traces for that block range. The tracer re-executes those blocks, writes a single trace file, and returns its location.
  4. The coordinator passes the trace file to the prover, which uses it to generate the execution proof.

Both paths are exposed through the Traces API, which internal protocol services call over RPC. Trace generation runs inside Linea Besu because replaying blocks requires an execution client, but the batch boundaries are decided by the coordinator, not the sequencer.

See also

Was this page helpful?