Skip to content

starknet_os: os resources test - add keccak#14139

Open
dorimedini-starkware wants to merge 1 commit into
05-23-starknet_os_os_resources_test_-_add_3_more_syscallsfrom
05-23-starknet_os_os_resources_test_-_add_keccak
Open

starknet_os: os resources test - add keccak#14139
dorimedini-starkware wants to merge 1 commit into
05-23-starknet_os_os_resources_test_-_add_3_more_syscallsfrom
05-23-starknet_os_os_resources_test_-_add_keccak

Conversation

@dorimedini-starkware
Copy link
Copy Markdown
Collaborator

No description provided.

Copy link
Copy Markdown
Collaborator Author

dorimedini-starkware commented May 24, 2026

@reviewable-StarkWare
Copy link
Copy Markdown

This change is Reviewable

@dorimedini-starkware dorimedini-starkware self-assigned this May 24, 2026
@dorimedini-starkware dorimedini-starkware marked this pull request as ready for review May 24, 2026 07:03
@cursor
Copy link
Copy Markdown

cursor Bot commented May 24, 2026

PR Summary

Medium Risk
Changes syscall resource accounting and OS program hashes used for client-side proving and fee estimation; incorrect values would break consensus alignment on costs or allowed OS builds.

Overview
Extends the OS resources regression path so Keccak is measured like other syscalls: the Cairo1 OsResourcesTestContract invokes keccak_syscall twice (empty input for base cost, 17× u64 for one round), and test_os_resources_regression treats Keccak as a linear-factor syscall whose per-round cost is recorded under KeccakRound (base aligned to syscall base gas).

Versioned constants / OS artifacts are refreshed to match: KeccakRound n_steps 281 → 315, Cairo KECCAK_ROUND_COST_GAS_COST 171707 → 175107, new os / virtual_os hashes in program_hash.json, and the second allowed virtual OS program hash updated in OS Cairo constants and blockifier_versioned_constants_0_14_3.json (plus the 0.14.2→0.14.3 diff regression snippet).

Reviewed by Cursor Bugbot for commit 1739107. Bugbot is set up for automated code reviews on this repo. Configure here.

@dorimedini-starkware dorimedini-starkware force-pushed the 05-23-starknet_os_os_resources_test_-_add_keccak branch from 228195b to d6c4ad3 Compare May 24, 2026 20:08
@dorimedini-starkware dorimedini-starkware force-pushed the 05-23-starknet_os_os_resources_test_-_add_keccak branch from d6c4ad3 to 1739107 Compare May 25, 2026 09:48
@dorimedini-starkware dorimedini-starkware force-pushed the 05-23-starknet_os_os_resources_test_-_add_3_more_syscalls branch from 01423bf to 5d943b5 Compare May 25, 2026 09:48
Copy link
Copy Markdown
Collaborator

@Yoni-Starkware Yoni-Starkware left a comment

Choose a reason for hiding this comment

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

:lgtm:

@Yoni-Starkware reviewed 6 files and all commit messages, and made 1 comment.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on dorimedini-starkware).

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