Skip to content

Difference between yul : true and viaIR : true #4099

Discussion options

You must be logged in to vote

Sure, not problem.

viaIR enables the new code generation pipeline. So this makes the compiler first generate Yul and only then EVM bytecode (rather than going straight from Solidity to EVM assembly).

optimizer.details.yul enables Yul optimizer, which affects Yul generated by the new pipeline but also Yul generated in any other circumstances. For example you can request irOptimized output even when using the legacy code generation pipeline - that output will be passed through the Yul optimizer when it is enabled. Also, some language features, even in the legacy pipeline, are generated from Yul code - e.g. anything that uses abicoder v2.

So, basically, if you want fully optimized Yul output…

Replies: 2 comments 3 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
3 replies
@clauBv23
Comment options

@cameel
Comment options

@clauBv23
Comment options

Answer selected by clauBv23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
3 participants