This is a simple patch to update SimplifyCFG's passingValueIsAlwaysUndefined to inspect more attributes.
A new function CallBase::isPassingUndefUB checks attributes that imply noundef.
Differential D97244
[SimplifyCFG] Update passingValueIsAlwaysUndefined to check more attributes aqjune on Feb 22 2021, 6:48 PM. Authored by
Details This is a simple patch to update SimplifyCFG's passingValueIsAlwaysUndefined to inspect more attributes. A new function CallBase::isPassingUndefUB checks attributes that imply noundef.
Diff Detail
Event TimelineComment Actions @spatel Now I fully got what https://reviews.llvm.org/D96663#2578814 meant. This change is introducing assume because it introduces unreachable which finally turns into assume. But, an ongoing clang frontend patch will introduce many more noundefs, and this will anyway create assumes; If we decide to be lightweight (and not to insert assume), I'll move towards SimplifyCFG to simply swap the phi's operand with undef if nonnull without noundef is met.
|
clang-format not found in user's PATH; not linting file.