solidity/test/libyul/ewasmTranslationTests/arithmetic_mul.yul

37 lines
2.5 KiB
Plaintext
Raw Normal View History

{
sstore(0, mul(0, 1))
sstore(1, mul(1, not(0)))
sstore(2, mul(0, 0))
sstore(3, mul(1, 2))
sstore(4, mul(0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe, 1))
sstore(5, mul(
0x8000000000000000000000000000000000000000000000000000000000000000, 1
))
sstore(6, mul(not(0), 1))
sstore(7, mul(0xffffffffffffffffffffffffffffffff, 1))
sstore(8, mul(0xffffffffffffffff, 1))
sstore(9, mul(0xffffffffffffffffffffffffffffffff0000000000000000, 1))
sstore(10, mul(0xffffffffffffffffffffffffffffffffffffffffffffffff, 3))
sstore(11, mul(0xffffffffffffffffffffffffffffffff, 3))
sstore(12, mul(0xffffffffffffffff, 3))
sstore(13, mul(0xffffffffffffffffffffffffffffffff0000000000000000, 3))
}
// ----
// Trace:
// Memory dump:
// 0: 000000000000000000000000000000000000000000000000000000000000000d
// 20: 0000000000000002fffffffffffffffffffffffffffffffd0000000000000000
// Storage dump:
// 0000000000000000000000000000000000000000000000000000000000000001: ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
// 0000000000000000000000000000000000000000000000000000000000000003: 0000000000000000000000000000000000000000000000000000000000000002
// 0000000000000000000000000000000000000000000000000000000000000004: fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe
// 0000000000000000000000000000000000000000000000000000000000000005: 8000000000000000000000000000000000000000000000000000000000000000
// 0000000000000000000000000000000000000000000000000000000000000006: ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
// 0000000000000000000000000000000000000000000000000000000000000007: 00000000000000000000000000000000ffffffffffffffffffffffffffffffff
// 0000000000000000000000000000000000000000000000000000000000000008: 000000000000000000000000000000000000000000000000ffffffffffffffff
// 0000000000000000000000000000000000000000000000000000000000000009: 0000000000000000ffffffffffffffffffffffffffffffff0000000000000000
// 000000000000000000000000000000000000000000000000000000000000000a: 0000000000000002fffffffffffffffffffffffffffffffffffffffffffffffd
// 000000000000000000000000000000000000000000000000000000000000000b: 00000000000000000000000000000002fffffffffffffffffffffffffffffffd
// 000000000000000000000000000000000000000000000000000000000000000c: 000000000000000000000000000000000000000000000002fffffffffffffffd
// 000000000000000000000000000000000000000000000000000000000000000d: 0000000000000002fffffffffffffffffffffffffffffffd0000000000000000