0xPolygonMiden / miden-vm

STARK-based virtual machine
MIT License
611 stars 148 forks source link

Support the immediate values for `u32` bitwise instructions #1362

Closed Overcastan closed 4 days ago

Overcastan commented 2 weeks ago

This PR adds support for the immediate values for u32 bitwise operations: u32and, u32or, u32xor and u32not.

TODO:

Overcastan commented 1 week ago

It turned out that with our lalrpop parser we can just emulate instructions with immediate values with [Push(imm), ActualInstruction] array, without the need to create new *Imm() versions of instructions (of course only in case we don't need to do some other preparations and calculations for immediate value). The same approach could be applied to the u32 and Felt comparison instructions, so probably I should create an issue to rework them.