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

feat: Cairo 1 programs and Hint processor #97

Merged
merged 45 commits into from
Jul 16, 2024

Conversation

zmalatrax
Copy link
Collaborator

@zmalatrax zmalatrax commented Jun 28, 2024

WIP
This PR allows executing Cairo programs (v2.6.4, maybe previous version before Sierra changes).
It uses the *.casm.json compilation artifacts from the command sierra-compile-json

Currently to run Cairo programs, a flag --cairo-1 has been added to the cairo run subcommand. It successfully ran add.cairo.

cairo run --cairo-1 cairo_programs/cairo/add.casm.json

Some refactoring are still needed I think, and then implementing the Cairo 1 hint processor is the next step (which is pretty straightforward).

Still needs to update the CI and add more tests for Cairo programs

@zmalatrax zmalatrax self-assigned this Jun 28, 2024
@zmalatrax
Copy link
Collaborator Author

zmalatrax commented Jun 28, 2024

Trunk tries to format Cairo programs with the Cairo Zero cairo-format

The new cairo format should be configured and used on Cairo programs.

.gitignore Outdated Show resolved Hide resolved
src/cli.ts Outdated Show resolved Hide resolved
src/vm/program.ts Outdated Show resolved Hide resolved
src/cli.ts Outdated Show resolved Hide resolved
@zmalatrax zmalatrax force-pushed the feat/cairo-1-hint-processor branch from cdfe7f7 to 14d5947 Compare July 15, 2024 18:36
This was linked to issues Jul 15, 2024
@ClementWalter ClementWalter marked this pull request as ready for review July 16, 2024 09:31
@ClementWalter ClementWalter merged commit dcaee45 into main Jul 16, 2024
3 checks passed
@ClementWalter ClementWalter deleted the feat/cairo-1-hint-processor branch July 16, 2024 09:32
@zmalatrax zmalatrax linked an issue Jul 16, 2024 that may be closed by this pull request
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.

AllocSegment TestLessThan feat: implement Cairo Hint processor
2 participants