Displaying 2 results from an estimated 2 matches for "oriop".
Did you mean:
orion
2018 Mar 09
0
[SelectionDAG] [TargetOp] How to get sub-half of immediate?
...6 bits.
def LUiORiPred : PatLeaf<(imm), [{
int64_t SVal = N->getSExtValue();
return isInt<32>(SVal) && (SVal & 0xffff);
}]>;
For completeness sake I've included this, but it's return true there are bits in both
16 bit fragments.
Then we use (here VT = i32, ORiOp is our logical or which takes an immediate,
LUiOp loads the upper bits of a register with an immediate, zeroing the lower 16 bits):
// Arbitrary immediates
def : MipsPat<(VT LUiORiPred:$imm), (ORiOp (LUiOp (HI16 imm:$imm)), (LO16 imm:$imm))>;
This anonymous pattern matches any sign-extended...
2018 Mar 09
2
[SelectionDAG] [TargetOp] How to get sub-half of immediate?
Hi all,
This seems like a dumb question but while setting up a pattern in TD
file, I got stuck on trying to get each half of an immediate as the
half-sized type (ie. i64 imm -> pair of i32 imm's). Is there an existing
way to do it? I've tried the 'EXTRACT_SUBREG' but that seems to error at
the end of scheduling. Looking at Target.td, I'm not sure which opcode
is meant