From 000509e7b07c19bd96ecff26e261c79f14d375f1 Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Thu, 13 Jan 2005 17:58:35 +0000 Subject: [PATCH] Add a new node type, add comments. llvm-svn: 19525 --- include/llvm/CodeGen/SelectionDAGISel.h | 5 +++-- include/llvm/CodeGen/SelectionDAGNodes.h | 12 ++++++++++-- 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/include/llvm/CodeGen/SelectionDAGISel.h b/include/llvm/CodeGen/SelectionDAGISel.h index 5fc6f31cd63..77fd05ac650 100644 --- a/include/llvm/CodeGen/SelectionDAGISel.h +++ b/include/llvm/CodeGen/SelectionDAGISel.h @@ -21,6 +21,7 @@ namespace llvm { class SelectionDAG; class SelectionDAGLowering; + class SDOperand; class SSARegMap; class MachineBasicBlock; class MachineFunction; @@ -49,8 +50,8 @@ public: virtual void InstructionSelectBasicBlock(SelectionDAG &SD) = 0; - void CopyValueToVirtualRegister(SelectionDAGLowering &SDL, - Value *V, unsigned Reg); + SDOperand CopyValueToVirtualRegister(SelectionDAGLowering &SDL, + Value *V, unsigned Reg); void SelectBasicBlock(BasicBlock *BB, MachineFunction &MF, FunctionLoweringInfo &FuncInfo); diff --git a/include/llvm/CodeGen/SelectionDAGNodes.h b/include/llvm/CodeGen/SelectionDAGNodes.h index 2ca6e1509c5..2957a51401c 100644 --- a/include/llvm/CodeGen/SelectionDAGNodes.h +++ b/include/llvm/CodeGen/SelectionDAGNodes.h @@ -44,8 +44,16 @@ namespace ISD { /// SelectionDAG. /// enum NodeType { - // Leaf nodes - EntryToken, Constant, ConstantFP, GlobalAddress, FrameIndex, ConstantPool, + // EntryToken - This is the marker used to indicate the start of the region. + EntryToken, + + // Token factor - This node is takes multiple tokens as input and produces a + // single token result. This is used to represent the fact that the operand + // operators are independent of each other. + TokenFactor, + + // Various leaf nodes. + Constant, ConstantFP, GlobalAddress, FrameIndex, ConstantPool, BasicBlock, ExternalSymbol, // CopyToReg - This node has chain and child nodes, and an associated