-
Notifications
You must be signed in to change notification settings - Fork 6.3k
Enable ethdebug debug info and output selection. #15289
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
ccbe426 to
71bf655
Compare
ec729b3 to
ee2bc12
Compare
ee2bc12 to
9772d20
Compare
09fd459 to
53e12ef
Compare
4b5c548 to
a262eef
Compare
a262eef to
c4cb445
Compare
b8851f6 to
1edf1f4
Compare
1edf1f4 to
bf1527c
Compare
clonker
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nothing deal-breaking I think. A couple of suggestions and questions. I would be wary when/how much debug data is collected, in particular that we don't collect it by default and just don't output it in the end - that could pose a big performance drain.
liblangutil/DebugInfoSelection.h
Outdated
| static DebugInfoSelection const Only(bool DebugInfoSelection::* _member) noexcept; | ||
| static DebugInfoSelection const Default() noexcept { return All(); } | ||
| static DebugInfoSelection const Default() noexcept { return ExceptExperimental(); } | ||
| static DebugInfoSelection const Except(std::vector<bool DebugInfoSelection::*> const& _members) noexcept; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it is fine but I was a bit confused about the naming Except and ExceptExperimental. I would have imagined to call something like All{}.exceptExperimental(). Or, to make it more clear for ... people like me, you could name it AllExceptExperimental. Or something. Minor point in any case, feel free to ignore
| [](const Json& result) | ||
| { | ||
| return result["contracts"]["fileA"]["contractA"]["evm"]["deployedBytecode"].contains("ethdebug") && | ||
| result["contracts"]["fileB"]["contractB"]["evm"]["bytecode"].contains("ethdebug") ; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ping
bf1527c to
df4a941
Compare
clonker
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
just a few whitespaces :D
lgtm otherwise
e4ab7ac to
7e14812
Compare
82df2ba to
0b702ac
Compare
0b702ac to
23d9607
Compare
23d9607 to
7ea985d
Compare
debug-infowas set toethdebugir,irOptimizedand/orethdebugwas selected as output.standard_debug_info_in_yul_ethdebug_output_ir_optimized,standard_debug_info_in_yul_ethdebug_output_no_irstrict-assemblye.g.solc --strict-assembly <yul> --debug-info ethdebugdebug-infoethdebugis excluded from the help on clidebug-infoethdebugis excluded fromallon cli and wildcard selection*in standard-jsonethdebugwas selected as outputdebug-infowas selected, it implicitly setdebug-infotoethdebug.solc <contract> --ethdebugvia-irwas not specified, it will error with a message stating thatethdebugcan only be selected as output, ifvia-irwas defined.solc <contract> --ethdebugonly works with--via-irdebug-infowas selected and did not containethdebug, an error will be generated stating thatethdebugneed to be set indebug-infosolc <contract> --ethdebug --debug-info locationstrict-assemblywill always work e.g.solc --strict-assembly <yul> --ethdebugethdebugis not shown in cli helpethdebugoutput selection is excluded from wildcard selection*in standard-jsonUPDATE
After some discussion with @gnidan and @ekpyron it turned out that we need something slightly different:
ethdebugoutput will now be enabled withevm.bytecode.ethdebug(deploytime part) andevm.deployedBytecode.ethdebug(runtime part)evm.bytecodeandevm.deployedBytecodebehave like a wildcard, so the ethdebug stuff is excluded here.--binand--bin-runtimeethdebug selection will now work similar with--ethdebugand--ethdebug-runtimeUPDATE 01/2025