[PATCH] D97495: [SimplifyCFG] avoid illegal phi with both poison and undef

Sanjay Patel via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Feb 26 05:11:29 PST 2021


spatel added a comment.

In D97495#2589631 <https://reviews.llvm.org/D97495#2589631>, @aqjune wrote:

> What about updating redirectValuesFromPredecessorsToPhi to lower conflicting poison to undef?
> We can maintain two sets of incoming BBs, say BBundef and BBpoison that have poison incoming values and undef incoming values.
> At the end of redirectValuesFromPredecessorsToPhi, if BBundef and BBpoison overlaps, there are operands that need to be updated.
> It will keep the transformation enabled.

Yes, we can do better on this, but I suspect it's rare to encounter both poison and undef (and gets more rare as we eliminate more and more undef from IR?).


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D97495/new/

https://reviews.llvm.org/D97495



More information about the llvm-commits mailing list