nikic wrote:
> We don't have a `isGuaranteedNotToBeUndef` only function, so that's the only
> way. I would leave a fixme, since this call can be removed if we ever manage
> to kill undef.
I actually added this function earlier today.
> @nikic is something like this the right fix?
I'd move th
nunoplopes wrote:
We don't have a `isGuaranteedNotToBeUndef` only function, so that's the only
way. I would leave a fixme, since this call can be removed if we ever manage to
kill undef.
Thanks for your help! 🙂
https://github.com/llvm/llvm-project/pull/72912
___
nunoplopes wrote:
Here's a simple-ish example:
```llvm
; Transforms/InstCombine/add.ll
define i5 @zext_sext_not(i4 %x) {
%zx = zext i4 %x to i5
%notx = xor i4 %x, 15
%snotx = sext i4 %notx to i5
%r = add i5 %zx, %snotx
ret i5 %r
}
=>
define i5 @zext_sext_not(i4 %x) {
%zx = zext i4 %x
topperc wrote:
> FWIW, Alive2 is complaining about this commit. These patches are not safe
> w.r.t. undef.
Why not?
https://github.com/llvm/llvm-project/pull/72912
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin
topperc wrote:
Are the KnownBits in SimplifyDemandedBit usable? We have this code
```
if (SimplifyDemandedBits(I, 1, DemandedMask, RHSKnown, Depth + 1) ||
SimplifyDemandedBits(I, 0, DemandedMask & ~RHSKnown.One, LHSKnown,
Depth + 1)) {
llvmbot wrote:
@llvm/pr-subscribers-clang
Author: Craig Topper (topperc)
Changes
Stacked on https://github.com/llvm/llvm-project/pull/72702 and
https://github.com/llvm/llvm-project/pull/72583
---
Patch is 153.23 KiB, truncated to 20.00 KiB below, full version:
https://github.com/llvm/l
llvmbot wrote:
@llvm/pr-subscribers-llvm-transforms
Author: Craig Topper (topperc)
Changes
Stacked on https://github.com/llvm/llvm-project/pull/72702 and
https://github.com/llvm/llvm-project/pull/72583
---
Patch is 153.23 KiB, truncated to 20.00 KiB below, full version:
https://github.
topperc wrote:
> Also you'll want to do this inside SimplifyDemanded to reuse existing
> KnownBits information.
Do we do that for other flags already? I based this off Add/Sub.
https://github.com/llvm/llvm-project/pull/72912
___
cfe-commits mailing l
nikic wrote:
Needs a rebase. Also you'll want to do this inside SimplifyDemanded to reuse
existing KnownBits information.
https://github.com/llvm/llvm-project/pull/72912
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cg