search for: tgtdagtodagisel

Displaying 2 results from an estimated 2 matches for "tgtdagtodagisel".

2017 Dec 24
4
Canonical way to handle zero registers?
Thanks, that sounds like it would work. Was this based on what any other target did? Or do any other targets take this approach? I just want to make sure that we don't already have a hook suitable for this. Overriding runOnFunction to run what could be described as just a "late SelectionDAG pass" sounds pretty intrusive. Do you remember other approaches that didn't work? --
2017 Dec 26
2
Canonical way to handle zero registers?
...you remember other > approaches that didn't work? An obvious approach that doesn't work: just writing a pattern. This causes assertions, seemingly as some code paths don't like the introduction of a physical register. At least AArch64, Lanai, and RISC-V handle the zero register in TgtDAGToDAGISel::Select. Lanai also has a "-1" register and handles that case in the same place. Copying from LanaiDAGToDAGISel::Select: EVT VT = Node->getValueType(0); switch (Opcode) { case ISD::Constant: if (VT == MVT::i32) { ConstantSDNode *ConstNode = cast<ConstantSDNode>(...