NethermindEth / blockifier

Blockifier is a Rust implementation for the transaction-executing component in the StarkNet sequencer, in charge of creating state diffs and blocks.
Apache License 2.0
1 stars 4 forks source link

Investigate struct ordening `u256` in Cairo and Native/Blockifier #97

Closed xrvdg closed 2 months ago

xrvdg commented 3 months ago

Accessing the high part of a U256 from within Rust gives the same result as accessing the low part of u256 from within Cairo. This seems to point to the order of the struct getting mixed up. We currently workaround this in both keccak and secp in the native starknet sycall handler.

xrvdg commented 3 months ago

Opened a ticket for it on the cairo native repo: https://github.com/lambdaclass/cairo_native/issues/715

xrvdg commented 2 months ago

This has been fixed in https://github.com/lambdaclass/cairo_native/pull/720.

We need to update our keccak and secp when bumping our dependency on cairo native to a commit after https://github.com/lambdaclass/cairo_native/commit/9527cc9d17b4708b5fb969133f4af924636cee02.