Displaying 4 results from an estimated 4 matches for "demandedmask".
2009 Jul 30
2
[LLVMdev] Vector logic regression in r73431
...on
75246, while that patch only seems to apply to some later revision.
Anyway, I actually located the real bug. Right at the end of
InstCombiner::SimplifyDemandedUseBits, there's this piece of code:
// If the client is only demanding bits that we know, return the known
// constant.
if ((DemandedMask & (RHSKnownZero|RHSKnownOne)) == DemandedMask) {
Constant *C = Context->getConstantInt(RHSKnownOne);
if (isa<PointerType>(V->getType()))
C = Context->getConstantExprIntToPtr(C, V->getType());
return C;
}
return false;
}
Note that C is a scalar integer, a...
2009 Jul 29
0
[LLVMdev] Vector logic regression in r73431
...t one.
Does the attached help?
-Eli
-------------- next part --------------
Index: InstructionCombining.cpp
===================================================================
--- InstructionCombining.cpp (revision 77486)
+++ InstructionCombining.cpp (working copy)
@@ -1014,7 +1014,7 @@
if ((DemandedMask & (RHSKnownZero|RHSKnownOne)) == DemandedMask) {
// all known
if ((RHSKnownOne & LHSKnownOne) == RHSKnownOne) {
- Constant *AndC = ConstantInt::get(*Context,
+ Constant *AndC = ConstantInt::get(VTy,
~RHSKnownOne &...
2009 Jul 29
3
[LLVMdev] Vector logic regression in r73431
Hi All,
I found a regression which triggers the asserts: "Binary operator types must
match!" and "Op types should be identical!". It's happening with a piece of
vector code, and the asserts happen because a logic operation is attempted
between a vector and a scalar (which is not present in the original code,
but created by InstCombine).
It's caused by revision
2009 Jul 30
0
[LLVMdev] Vector logic regression in r73431
...'t easily help you with an
old revision.
> Anyway, I actually located the real bug. Right at the end of
> InstCombiner::SimplifyDemandedUseBits, there's this piece of code:
>
> // If the client is only demanding bits that we know, return the known
> // constant.
> if ((DemandedMask & (RHSKnownZero|RHSKnownOne)) == DemandedMask) {
> Constant *C = Context->getConstantInt(RHSKnownOne);
> if (isa<PointerType>(V->getType()))
> C = Context->getConstantExprIntToPtr(C, V->getType());
> return C;
> }
> return false;
> }
>
&...