[PATCH] D71799: [Attributor] AAUndefinedBehavior: Check for branches on undef value.

Hideto Ueno via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Dec 22 07:21:54 PST 2019


uenoku added a comment.

In the current patch, I think an instruction might be inserted to both `UBInsts` and `NoUBInsts`  in some cases when `AAValueSimplify` changes its assumption.

In my understanding, the idea of this deduction is 
" We assume `br` instruction causes UB. If you can prove that the instruction *doesn't* cause UB, we remove that assumption".

So I think we don't need to have both `UBInsts` and `NoUBInsts` because if an instruction is not in `NoUBInsts` then it is assumed to cause UB. 
( You can find that `AAISDeadFunction` is similar. If `BB` is not in `AssumedLiveBlocks`, then it is assumed to be Dead`).


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

https://reviews.llvm.org/D71799





More information about the llvm-commits mailing list