Skip to content

Conversation

@Maillew
Copy link

@Maillew Maillew commented Oct 15, 2025

Description

Adds support for AOT Metered Cost Execution

Testing

Modified existing fn check_aot_equivalence function in stark_utils.rs to assert consistency between AOT and Interpreted metered cost execution

Added additional tests in extensions/native/circuit/tests/integration_test.rs to test various scenarios surrounding metered_cost

Closes INT-5255

@github-actions

This comment was marked as resolved.

@Maillew Maillew changed the title Feat/aot metered cost feat: aot metered cost Oct 15, 2025
@Maillew Maillew force-pushed the feat/aot-metered-cost branch from 9b405e3 to 6e34a08 Compare October 16, 2025 18:06
@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@Maillew Maillew force-pushed the feat/aot-metered-cost branch from 2c7426e to 5d52991 Compare October 16, 2025 21:33
@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@Maillew Maillew force-pushed the feat/aot-metered-cost branch from d45154e to 6a06185 Compare October 16, 2025 23:04
@Maillew Maillew marked this pull request as ready for review October 16, 2025 23:44
@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@Maillew Maillew force-pushed the feat/aot-metered-cost branch from 5235ff8 to b125b27 Compare October 17, 2025 20:44
@Maillew Maillew marked this pull request as draft October 17, 2025 22:43
@Maillew Maillew self-assigned this Oct 17, 2025
@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@shuklaayush
Copy link
Contributor

looks like test_invalid_setup is stuck in an infinite loop somewhere

Copy link
Contributor

Choose a reason for hiding this comment

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

  1. Thanks for re-organizing to share code.
  2. I didn't catch this before, but if each of asm_bridge_* is actually a new crate, they should not go inside arch/ or even inside the vm/ folder. I'd suggest making crates/asm and then separate folders for each crate inside.


// Helper to run AOT metered-cost and compare against interpreter baseline.
#[cfg(feature = "aot")]
macro_rules! run_aot_metered_cost_and_compare {
Copy link
Contributor

Choose a reason for hiding this comment

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

did this need to be a macro and not just a function?

Copy link
Contributor

@jonathanpwang jonathanpwang left a comment

Choose a reason for hiding this comment

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

LGTM and generally helped reorganize things structurally, but please address the comment that we shouldn't have crates inside vm/src/arch. These crates should be outside, e.g. crates/asm

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions
Copy link

group app.proof_time_ms app.cycles app.cells_used leaf.proof_time_ms leaf.cycles leaf.cells_used
verify_fibair 230 322,610 2,058,654 - - -
fibonacci 980 1,500,209 2,100,402 - - -
regex 2,326 4,137,502 17,695,216 - - -
ecrecover 707 122,859 2,262,718 - - -
pairing 1,436 1,745,742 25,468,210 - - -

Commit: 7d84792

Benchmark Workflow

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.

5 participants