uabelho added a comment.

In D92270#2422625 <https://reviews.llvm.org/D92270#2422625>, @aqjune wrote:

> Hi,
>
> It seems it is related to two optimizations:
> (1) `select i1 x, true, y` -> `or i1 x, y`
> (2) `or i1 x, poison` -> `poison`
>
> Semantically, the first one is broken. It needs to freeze y. But, it will 
> introduce a lot of freeze instructions. The clang patches that introduce 
> noundef to function arguments is still ongoing.
> Another workaround is to weaken (2) to `or i1 x, poison` -> `x`. This fixes 
> the miscompilation; I'll push a commit that does this.

Should langref also be updated to describe this? Or does it already?
I just found this "An instruction that depends on a poison value, produces a 
poison value itself.".


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D92270

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to