Skip to content

expected_cycles validation happens before rounding, should be after #2741

@milord12345

Description

@milord12345

In processor/src/execution_options.rs, expected_cycles is validated against max_cycles before being rounded up via next_power_of_two().max(MIN_TRACE_LEN). This means the check can pass even when the rounded value exceeds max_cycles.

Example: expected_cycles = 65, max_cycles = 100 — check passes, but after rounding expected_cycles becomes 128 > 100 and no error is returned.

The fix is straightforward: move the validation to after the rounding step.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions