
## miden::core::math::u256
| Procedure | Description |
| ----------- | ------------- |
| overflowing_add | Performs addition of two unsigned 256 bit integers preserving the overflow.<br />Stack transition looks as follows:<br />[b0, b1, b2, b3, b4, b5, b6, b7, a0, a1, a2, a3, a4, a5, a6, a7, ...]<br />-> [overflow, c0, c1, c2, c3, c4, c5, c6, c7, ...], where c = (a + b) % 2^256.<br /> |
| widening_add | Performs addition of two unsigned 256 bit integers preserving the overflow with sum on top.<br />Stack transition looks as follows:<br />[b0, b1, b2, b3, b4, b5, b6, b7, a0, a1, a2, a3, a4, a5, a6, a7, ...]<br />-> [c0, c1, c2, c3, c4, c5, c6, c7, overflow, ...], where c = (a + b) % 2^256.<br /> |
| wrapping_add | Performs addition of two unsigned 256 bit integers discarding the overflow.<br />Stack transition looks as follows:<br />[b0, b1, b2, b3, b4, b5, b6, b7, a0, a1, a2, a3, a4, a5, a6, a7, ...]<br />-> [c0, c1, c2, c3, c4, c5, c6, c7, ...], where c = (a + b) % 2^256.<br /> |
| overflowing_sub | Performs subtraction of two unsigned 256 bit integers preserving the underflow.<br />Stack transition looks as follows:<br />[b0, b1, b2, b3, b4, b5, b6, b7, a0, a1, a2, a3, a4, a5, a6, a7, ...]<br />-> [underflow, c0, c1, c2, c3, c4, c5, c6, c7, ...], where c = (a - b) % 2^256.<br /> |
| wrapping_sub | Performs subtraction of two unsigned 256 bit integers discarding the underflow.<br />Stack transition looks as follows:<br />[b0, b1, b2, b3, b4, b5, b6, b7, a0, a1, a2, a3, a4, a5, a6, a7, ...]<br />-> [c0, c1, c2, c3, c4, c5, c6, c7, ...], where c = (a - b) % 2^256.<br /> |
| and | Computes bitwise AND of two unsigned 256 bit integers.<br />Stack transition looks as follows:<br />[b0, b1, b2, b3, b4, b5, b6, b7, a0, a1, a2, a3, a4, a5, a6, a7, ...]<br />-> [c0, c1, c2, c3, c4, c5, c6, c7, ...], where c = a & b.<br /> |
| or | Computes bitwise OR of two unsigned 256 bit integers.<br />Stack transition looks as follows:<br />[b0, b1, b2, b3, b4, b5, b6, b7, a0, a1, a2, a3, a4, a5, a6, a7, ...]<br />-> [c0, c1, c2, c3, c4, c5, c6, c7, ...], where c = a \| b.<br /> |
| xor | Computes bitwise XOR of two unsigned 256 bit integers.<br />Stack transition looks as follows:<br />[b0, b1, b2, b3, b4, b5, b6, b7, a0, a1, a2, a3, a4, a5, a6, a7, ...]<br />-> [c0, c1, c2, c3, c4, c5, c6, c7, ...], where c = a ^ b.<br /> |
| eqz | Returns 1 if the top u256 value is zero; lower stack values are preserved.<br />Stack transition looks as follows:<br />[a0, a1, a2, a3, a4, a5, a6, a7, ...] -> [is_zero, ...].<br /> |
| eq | Returns 1 if two unsigned 256 bit integers are equal.<br />Stack transition looks as follows:<br />[b0, b1, b2, b3, b4, b5, b6, b7, a0, a1, a2, a3, a4, a5, a6, a7, ...] -> [is_equal, ...].<br /> |
| wrapping_mul | Performs multiplication of two unsigned 256 bit integers discarding the overflow.<br />The input values are assumed to be represented using 32 bit limbs, but this is not checked.<br />Stack transition looks as follows:<br />[b0, b1, b2, b3, b4, b5, b6, b7, a0, a1, a2, a3, a4, a5, a6, a7, ...]<br />-> [c0, c1, c2, c3, c4, c5, c6, c7, ...], where c = (a * b) % 2^256.<br /> |
