mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Make hardcoded parts of the optimizer sequence configurable
This commit is contained in:
@@ -0,0 +1 @@
|
||||
--ir-optimized --optimize --yul-optimizations :iDu
|
||||
@@ -0,0 +1,12 @@
|
||||
// SPDX-License-Identifier: GPL-3.0
|
||||
pragma solidity >=0.0;
|
||||
pragma abicoder v2;
|
||||
|
||||
contract C {
|
||||
constructor() payable {
|
||||
assembly ("memory-safe") {
|
||||
let a := 0
|
||||
revert(0, a)
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,24 @@
|
||||
Optimized IR:
|
||||
/// @use-src 0:"yul_optimizer_steps_with_empty_optimization_sequence/input.sol"
|
||||
object "C_8" {
|
||||
code {
|
||||
{
|
||||
/// @src 0:80:221 "contract C {..."
|
||||
mstore(64, memoryguard(0x80))
|
||||
/// @src 0:129:213 "assembly (\"memory-safe\") {..."
|
||||
let usr$a := 0
|
||||
revert(0, usr$a)
|
||||
}
|
||||
}
|
||||
/// @use-src 0:"yul_optimizer_steps_with_empty_optimization_sequence/input.sol"
|
||||
object "C_8_deployed" {
|
||||
code {
|
||||
{
|
||||
/// @src 0:80:221 "contract C {..."
|
||||
mstore(64, memoryguard(0x80))
|
||||
revert(0, 0)
|
||||
}
|
||||
}
|
||||
data ".metadata" hex"<BYTECODE REMOVED>"
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user