Displaying 7 results from an estimated 7 matches for "extending_loads".
2018 Nov 27
2
[RFC] Tablegen-erated GlobalISel Combine Rules
...(G_MUL $D, $t1, $C)),
(apply (create_imm [{ 2 * ${B}->getZExtValue() }], apint_value:$B):$NB,
(G_ADD $t1, $A, $A),
(G_ADD $D, $t1, $NB))>;
// $D is needed because we wanted operand instead of reg. We could rewrite the predicate to take a reg though.
def extending_loads : GICombineRule<
(defs operand:$D, reg:$A, extending_load_matchdata:$matchinfo),
(match (G_LOAD $D, $A),
(extending_load_predicate operand:$A,
extending_load_matchdata:$matchinfo)),
(apply (exec [{ Helper.applyCombineExtending...
2018 Nov 27
3
[RFC] Tablegen-erated GlobalISel Combine Rules
...Patterns.
def extending_load_matchdata : GIDefMatchData<"PreferredTuple">;
def extending_load_predicate : GIMatchPredicate<
bool, (ins reg:$A), (outs extending_load_matchdata:$B), [{
return Helper.matchCombineExtendingLoads(${A}, ${B});
}]>;
def extending_loads : GICombineRule<
(defs operand:$D, reg:$A, extending_load_matchdata:$matchinfo),
(match (G_LOAD $D, $A),
(extending_load_predicate operand:$A,
extending_load_matchdata:$matchinfo)),
(apply (exec [{ Helper.applyCombineExtending...
2018 Nov 30
2
[RFC] Tablegen-erated GlobalISel Combine Rules
...GIDefMatchData<"PreferredTuple">;
>> def extending_load_predicate : GIMatchPredicate<
>> bool, (ins reg:$A), (outs extending_load_matchdata:$B), [{
>> return Helper.matchCombineExtendingLoads(${A}, ${B});
>> }]>;
>> def extending_loads : GICombineRule<
>> (defs operand:$D, reg:$A, extending_load_matchdata:$matchinfo),
>> (match (G_LOAD $D, $A),
>> (extending_load_predicate operand:$A,
>> extending_load_matchdata:$matchinfo)),
>>...
2018 Nov 30
2
[RFC] Tablegen-erated GlobalISel Combine Rules
..., $t1, $C)),
>> (apply (create_imm [{ 2 * ${B}->getZExtValue() }], apint_value:$B):$NB,
>> (G_ADD $t1, $A, $A),
>> (G_ADD $D, $t1, $NB))>;
>> // $D is needed because we wanted operand instead of reg. We could rewrite the predicate to take a reg though.
>> def extending_loads : GICombineRule<
>> (defs operand:$D, reg:$A, extending_load_matchdata:$matchinfo),
>> (match (G_LOAD $D, $A),
>> (extending_load_predicate operand:$A,
>> extending_load_matchdata:$matchinfo)),
>> (apply (exec [{ Helper.applyCombineExtendingLoads(${D}, ${matchinfo.B...
2018 Nov 09
5
[RFC] Tablegen-erated GlobalISel Combine Rules
...;d write:
def extending_load_matchdata : GIDefMatchData<"PreferredTuple">;
def extending_load_predicate : GIMatchPredicate<
(ins reg:$A, extending_load_matchdata:$B), bool, [{
return Helper.matchCombineExtendingLoads(${A}, ${matchinfo});
}]>;
def extending_loads : GICombineRule<
(defs root:$root, reg:$A, extending_load_matchdata:$matchinfo),
(match [{MIR %root = G_LOAD %A }],
(extending_load_predicate root:$A,
extending_load_matchdata:$matchinfo)),
(apply (exec [{ Helper.applyCombineE...
2018 Nov 10
3
[RFC] Tablegen-erated GlobalISel Combine Rules
...ol and requires fewer argument registers, the second version has to store the MachineOperand* on the stack to pass it by reference. The difference is fairly small when considered on an individual rule but should accumulate on large rulesets or large functions.
>> }]>;
>> def extending_loads : GICombineRule<
>> (defs root:$root, reg:$A, extending_load_matchdata:$matchinfo),
>> (match [{MIR %root = G_LOAD %A }],
>> (extending_load_predicate root:$A,
>> extending_load_matchdata:$matchinfo)),
>&...
2018 Nov 12
3
[RFC] Tablegen-erated GlobalISel Combine Rules
...g the operand being matched instead of the operand returned by the predicate will be a common mistake otherwise:
let ApplyCannotUseMatchedOperand = 1;
I'd also be inclined to make it a warning for this to be unset if the result has a name.
>>>> }]>;
>>>> def extending_loads : GICombineRule<
>>>> (defs root:$root, reg:$A, extending_load_matchdata:$matchinfo),
>>>> (match [{MIR %root = G_LOAD %A }],
>>>> (extending_load_predicate root:$A,
>>>> extending_lo...