[llvm] [HashRecognize] Rewrite arePHIsIntertwined (PR #144878)

Ramkumar Ramachandra via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 1 10:26:15 PDT 2025


artagnon wrote:

> > > My concern is that we could miscompile this specially crafted code:
> > 
> > 
> > Thank you for finding yet another bug! Fixed now by matching the first XOR (I think I had equivalent logic before the rewrite using count_if == 1, but missed it in the rewrite).
> > Note that if the corrupt xor is anything else, the KnownBits propagation will fail.
> 
> Wait a second, it could be 'or'. Need to think some more about this.

I believe that I have the right fix now, with a known-bits computation.

https://github.com/llvm/llvm-project/pull/144878


More information about the llvm-commits mailing list