Thanks to visit codestin.com
Credit goes to github.com

Skip to content

DecoratorId out of bounds bug #2456

Description

@Fumuran

Attempt to run the miden-base using the latest VM version (v0.20.0) in some cases resulted in errors during the scripts execution.

It seems like an execution of a program which uses call inside results in DecoratorId out of bounds error. The simplest example could be created from the execute_tx_view_script() test in the miden-base. There we attempt to execute this program:

    begin
        push.1.2
        call.module_1::foo
        exec.sys::truncate_stack
    end

If the call.module_1::foo is removed, this error will disappear.

It is doubly strange that if the transaction script is slightly modified, this error disappears as well. It's enough to add two drops after push like so:

    begin
        push.1.2 drop drop
        call.module_1::foo
        exec.sys::truncate_stack
    end

So it feels like adding this extra instructions modifies the way decorators are created during the compilation of this script.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No fields configured for Bug.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions