solidity/test/cmdlineTests/constant_optimizer_yul/output
hrkrshnn 6d9e9e1b1e Fix small bug in GasMeter calculation in creation context
Old calculation did not ignore `optimize-runs` parameter, when creation code gas computations were
done. This would lead to expanding values such as `shl(180, 1)` inside constructor code, even for
the default value for `--optimize-runs`, i.e., 200.
2021-03-17 12:33:10 +01:00

31 lines
918 B
Plaintext

Optimized IR:
/*******************************************************
* WARNING *
* Solidity to Yul compilation is still EXPERIMENTAL *
* It can result in LOSS OF FUNDS or worse *
* !USE AT YOUR OWN RISK! *
*******************************************************/
object "C_12" {
code {
{
mstore(64, 128)
if callvalue() { revert(0, 0) }
sstore(0, shl(180, 1))
let _1 := datasize("C_12_deployed")
codecopy(0, dataoffset("C_12_deployed"), _1)
return(0, _1)
}
}
object "C_12_deployed" {
code {
{
mstore(64, 128)
if callvalue() { revert(0, 0) }
sstore(0, 0x1000000000000000000000000000000000000000000000)
stop()
}
}
}
}