This repo contains two take-home assignments for the Senior Rust Engineer role at Scroll.
Assignment 1 (scroll-revm
): Building on revm, create an EVM variant with a custom precompile. This custom precompile takes an address as its input, then reads the account's contract bytecode and returns the number of zero bytes in it. Add this custom precompile by implementing PrecompileCountZeroBytes
and modifying create_evm
. For details on revm, please refer to the revm book and the docs.
Assignment 2 (exex-scroll-indexer
): Building on reth, implement an Executable Extension (ExEx) that indexes all Scroll batches into a local database. Your indexer should process two events: CommitBatch
and RevertBatch
. Implement the indexer by completing the scroll_indexer_exex
function. Feel free to refer to reth's ExEx examples.
- Clone this repo.
- Modify
scroll-revm/src/main.rs
andexex-scroll-indexer/src/main.rs
. - Commit your changes.
- Create a private repo on GitHub. (Please do not push your solution to a public repo!)
- Push your changes.
- Add Thegaram as an Admin to the repo.
- Correctness.
- Readability, clean code, maintainability.
- Test coverage (if applicable).
- Performance (if applicable).