mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-14 11:32:34 +00:00
Removing unnecessary 'else' statement from the predicates defined in HexagonOperards.td.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@169148 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
acb8d9fbe3
commit
4fa65820ba
@ -497,10 +497,7 @@ def s16ExtPred : PatLeaf<(i32 imm), [{
|
|||||||
|
|
||||||
// Return true if extending this immediate is profitable and the value
|
// Return true if extending this immediate is profitable and the value
|
||||||
// can fit in a 32-bit signed field.
|
// can fit in a 32-bit signed field.
|
||||||
if (isConstExtProfitable(Node) && isInt<32>(v))
|
return isConstExtProfitable(Node) && isInt<32>(v);
|
||||||
return true;
|
|
||||||
else
|
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
}]>;
|
}]>;
|
||||||
|
|
||||||
@ -515,10 +512,7 @@ def s10ExtPred : PatLeaf<(i32 imm), [{
|
|||||||
|
|
||||||
// Return true if extending this immediate is profitable and the value
|
// Return true if extending this immediate is profitable and the value
|
||||||
// can fit in a 32-bit signed field.
|
// can fit in a 32-bit signed field.
|
||||||
if (isConstExtProfitable(Node) && isInt<32>(v))
|
return isConstExtProfitable(Node) && isInt<32>(v);
|
||||||
return true;
|
|
||||||
else
|
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
}]>;
|
}]>;
|
||||||
|
|
||||||
@ -533,10 +527,7 @@ def s9ExtPred : PatLeaf<(i32 imm), [{
|
|||||||
|
|
||||||
// Return true if extending this immediate is profitable and the value
|
// Return true if extending this immediate is profitable and the value
|
||||||
// can fit in a 32-bit unsigned field.
|
// can fit in a 32-bit unsigned field.
|
||||||
if (isConstExtProfitable(Node) && isInt<32>(v))
|
return isConstExtProfitable(Node) && isInt<32>(v);
|
||||||
return true;
|
|
||||||
else
|
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
}]>;
|
}]>;
|
||||||
|
|
||||||
@ -551,10 +542,7 @@ def s8ExtPred : PatLeaf<(i32 imm), [{
|
|||||||
|
|
||||||
// Return true if extending this immediate is profitable and the value
|
// Return true if extending this immediate is profitable and the value
|
||||||
// can fit in a 32-bit signed field.
|
// can fit in a 32-bit signed field.
|
||||||
if (isConstExtProfitable(Node) && isInt<32>(v))
|
return isConstExtProfitable(Node) && isInt<32>(v);
|
||||||
return true;
|
|
||||||
else
|
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
}]>;
|
}]>;
|
||||||
|
|
||||||
@ -570,10 +558,7 @@ def s8_16ExtPred : PatLeaf<(i32 imm), [{
|
|||||||
// Return true if extending this immediate is profitable and the value
|
// Return true if extending this immediate is profitable and the value
|
||||||
// can't fit in a 16-bit signed field. This is required to avoid
|
// can't fit in a 16-bit signed field. This is required to avoid
|
||||||
// unnecessary constant extenders.
|
// unnecessary constant extenders.
|
||||||
if (isConstExtProfitable(Node) && !isInt<16>(v))
|
return isConstExtProfitable(Node) && !isInt<16>(v);
|
||||||
return true;
|
|
||||||
else
|
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
}]>;
|
}]>;
|
||||||
|
|
||||||
@ -588,10 +573,7 @@ def s6ExtPred : PatLeaf<(i32 imm), [{
|
|||||||
|
|
||||||
// Return true if extending this immediate is profitable and the value
|
// Return true if extending this immediate is profitable and the value
|
||||||
// can fit in a 32-bit unsigned field.
|
// can fit in a 32-bit unsigned field.
|
||||||
if (isConstExtProfitable(Node) && isInt<32>(v))
|
return isConstExtProfitable(Node) && isInt<32>(v);
|
||||||
return true;
|
|
||||||
else
|
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
}]>;
|
}]>;
|
||||||
|
|
||||||
@ -607,10 +589,7 @@ def s6_16ExtPred : PatLeaf<(i32 imm), [{
|
|||||||
// Return true if extending this immediate is profitable and the value
|
// Return true if extending this immediate is profitable and the value
|
||||||
// can't fit in a 16-bit signed field. This is required to avoid
|
// can't fit in a 16-bit signed field. This is required to avoid
|
||||||
// unnecessary constant extenders.
|
// unnecessary constant extenders.
|
||||||
if (isConstExtProfitable(Node) && !isInt<16>(v))
|
return isConstExtProfitable(Node) && !isInt<16>(v);
|
||||||
return true;
|
|
||||||
else
|
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
}]>;
|
}]>;
|
||||||
|
|
||||||
@ -626,10 +605,7 @@ def s6_10ExtPred : PatLeaf<(i32 imm), [{
|
|||||||
// Return true if extending this immediate is profitable and the value
|
// Return true if extending this immediate is profitable and the value
|
||||||
// can't fit in a 10-bit signed field. This is required to avoid
|
// can't fit in a 10-bit signed field. This is required to avoid
|
||||||
// unnecessary constant extenders.
|
// unnecessary constant extenders.
|
||||||
if (isConstExtProfitable(Node) && !isInt<10>(v))
|
return isConstExtProfitable(Node) && !isInt<10>(v);
|
||||||
return true;
|
|
||||||
else
|
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
}]>;
|
}]>;
|
||||||
|
|
||||||
@ -644,10 +620,7 @@ def s11_0ExtPred : PatLeaf<(i32 imm), [{
|
|||||||
|
|
||||||
// Return true if extending this immediate is profitable and the value
|
// Return true if extending this immediate is profitable and the value
|
||||||
// can fit in a 32-bit signed field.
|
// can fit in a 32-bit signed field.
|
||||||
if (isConstExtProfitable(Node) && isInt<32>(v))
|
return isConstExtProfitable(Node) && isInt<32>(v);
|
||||||
return true;
|
|
||||||
else
|
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
}]>;
|
}]>;
|
||||||
|
|
||||||
@ -663,10 +636,7 @@ def s11_1ExtPred : PatLeaf<(i32 imm), [{
|
|||||||
|
|
||||||
// Return true if extending this immediate is profitable and the low 1 bit
|
// Return true if extending this immediate is profitable and the low 1 bit
|
||||||
// is zero (2-byte aligned).
|
// is zero (2-byte aligned).
|
||||||
if (isConstExtProfitable(Node) && isInt<32>(v) && ((v % 2) == 0))
|
return isConstExtProfitable(Node) && isInt<32>(v) && ((v % 2) == 0);
|
||||||
return true;
|
|
||||||
else
|
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
}]>;
|
}]>;
|
||||||
|
|
||||||
@ -682,10 +652,7 @@ def s11_2ExtPred : PatLeaf<(i32 imm), [{
|
|||||||
|
|
||||||
// Return true if extending this immediate is profitable and the low 2-bits
|
// Return true if extending this immediate is profitable and the low 2-bits
|
||||||
// are zero (4-byte aligned).
|
// are zero (4-byte aligned).
|
||||||
if (isConstExtProfitable(Node) && isInt<32>(v) && ((v % 4) == 0))
|
return isConstExtProfitable(Node) && isInt<32>(v) && ((v % 4) == 0);
|
||||||
return true;
|
|
||||||
else
|
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
}]>;
|
}]>;
|
||||||
|
|
||||||
@ -701,9 +668,6 @@ def s11_3ExtPred : PatLeaf<(i32 imm), [{
|
|||||||
|
|
||||||
// Return true if extending this immediate is profitable and the low 3-bits
|
// Return true if extending this immediate is profitable and the low 3-bits
|
||||||
// are zero (8-byte aligned).
|
// are zero (8-byte aligned).
|
||||||
if (isConstExtProfitable(Node) && isInt<32>(v) && ((v % 8) == 0))
|
return isConstExtProfitable(Node) && isInt<32>(v) && ((v % 8) == 0);
|
||||||
return true;
|
|
||||||
else
|
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
}]>;
|
}]>;
|
||||||
|
Loading…
Reference in New Issue
Block a user