Displaying 1 result from an estimated 1 matches for "mxmtargetlowering".
Did you mean:
armtargetlowering
2013 Mar 25
1
[LLVMdev] Backend port: Adding negative immediates
...M IR.
They cannot be matched to the 8bit unsigned immediate add during
Instruction Selection and will eventually be moved in a register.
It would be better to transform these adds with small negative
immediates into subs during Target Lowering.
So I tried to custom lower ISD::ADD in IselLowering:
MxmTargetLowering::MxmTargetLowering(TargetMachine &TM)
: TargetLowering(TM, new TargetLoweringObjectFileELF()) {
[...]
setOperationAction(ISD::ADD, MVT::i32, Custom);
[...]
}
//check for immediate adds with constant values -256 < x < 0 and
transform them
//to sub
SDValue MxmTargetLowering::LowerADD(SDV...