Skip to content

Conversation

@allnil
Copy link

@allnil allnil commented Apr 12, 2024

that's a draft #1251
Gonna play with opcodes and see how it works
starting with BYTE
hope CI will be green soon :)

@DaniPopes
Copy link
Collaborator

DaniPopes commented Apr 12, 2024

I wouldn't expect that shift + bitand is better here since Uint::byte compiles to indexing into the byte array on little-endian.

I would probably look into the conversion macros and bit shifts in ruint.


If you want to see the assembly for the opcode functions you can add this to the crate root:

pub fn make_me_a_table() -> opcode::InstructionTable<DummyHost> {
    core::hint::black_box(opcode::make_instruction_table::<_, primitives::CancunSpec>())
}

And then run cargo asm -p revm-interpreter --lib opcode_name (using cargo-show-asm).

@allnil
Copy link
Author

allnil commented Apr 13, 2024

@DaniPopes
thank you! I'll definitely try this!

@rakita
Copy link
Member

rakita commented May 4, 2024

Closing it. If you have new changes be free to reopen it.

@rakita rakita closed this May 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants