The conditions that are used to determine if entry values should be
emitted for a parameter are quite many, and will grow slightly
in a follow-up commit, so move those to a helper function, as was
suggested in the code review for D69889.
Details
Diff Detail
Event Timeline
Please remember to provide full-context diffs.
llvm/lib/CodeGen/LiveDebugValues.cpp | ||
---|---|---|
1304 | Not clear why a lambda is better than a static function. The [&] captures way more than you need, for one thing. The only values it uses are MI (already passed as a parameter) and DebugEntryVals. |
Thanks! This looks good to me, with minor nits inlined.
llvm/lib/CodeGen/LiveDebugValues.cpp | ||
---|---|---|
1304 | Yes, If we are using lambdas, it is better to use an explicit capture instead of the default capture. |
Move the helper to a separate function rather than a lambda. Include full diff context.
Taken from D68209.