mirror of
https://github.com/logos-storage/plonky2.git
synced 2026-02-25 08:13:07 +00:00
Impl chain_id opcode for interpreter
This commit is contained in:
parent
ae8ee27eb8
commit
9e6f284b26
@ -353,7 +353,7 @@ impl<'a> Interpreter<'a> {
|
||||
0x43 => self.run_number(), // "NUMBER",
|
||||
0x44 => self.run_difficulty(), // "DIFFICULTY",
|
||||
0x45 => todo!(), // "GASLIMIT",
|
||||
0x46 => todo!(), // "CHAINID",
|
||||
0x46 => self.run_chainid(), // "CHAINID",
|
||||
0x48 => self.run_basefee(), // "BASEFEE",
|
||||
0x49 => self.run_prover_input()?, // "PROVER_INPUT",
|
||||
0x50 => self.run_pop(), // "POP",
|
||||
@ -679,6 +679,10 @@ impl<'a> Interpreter<'a> {
|
||||
self.push(self.get_global_metadata_field(GlobalMetadata::BlockBaseFee))
|
||||
}
|
||||
|
||||
fn run_chainid(&mut self) {
|
||||
self.push(self.get_global_metadata_field(GlobalMetadata::BlockChainId))
|
||||
}
|
||||
|
||||
fn run_prover_input(&mut self) -> anyhow::Result<()> {
|
||||
let prover_input_fn = self
|
||||
.prover_inputs_map
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user