Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Assembler restructure #75

Merged
merged 23 commits into from
Oct 10, 2023
Merged

Conversation

mmk-1
Copy link
Contributor

@mmk-1 mmk-1 commented Sep 28, 2023

  • Renamed Instruction to AST in grammar.go to avoid confusion with Instruction struct in pkg/vm
  • Changed the pipeline of bytecode generation by the assembler
  • With this PR the pipeline will change to AST -> []Instruction -> bytecode
  • Will resolve issue Restructuring assembler pipeline #70
  • Changed the enum mapping in instruction.go to match the whitepaper convention.
  • Added a few tests to assembler_test.go

@mmk-1 mmk-1 marked this pull request as ready for review October 9, 2023 16:06
Copy link
Contributor

@rodrigo-pino rodrigo-pino left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great work overall! The only thing I don't think is good is the need for an Immediate as part of an Instruction field

pkg/assembler/assembler.go Outdated Show resolved Hide resolved
pkg/assembler/grammar.go Outdated Show resolved Hide resolved
pkg/assembler/instruction.go Outdated Show resolved Hide resolved
pkg/assembler/instruction.go Outdated Show resolved Hide resolved
pkg/assembler/grammar.go Outdated Show resolved Hide resolved
pkg/assembler/instruction_test.go Outdated Show resolved Hide resolved
pkg/assembler/instruction_test.go Outdated Show resolved Hide resolved
pkg/assembler/instruction.go Outdated Show resolved Hide resolved
pkg/assembler/instruction.go Outdated Show resolved Hide resolved
pkg/assembler/assembler_test.go Outdated Show resolved Hide resolved
Copy link
Contributor

@rodrigo-pino rodrigo-pino left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very good job!!! 🔥

@rodrigo-pino rodrigo-pino merged commit 9c2c6e0 into NethermindEth:main Oct 10, 2023
4 checks passed
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.

2 participants