Changes in directory llvm/include/llvm/CodeGen:
SelectionDAG.h updated: 1.146 -> 1.147 SelectionDAGNodes.h updated: 1.184 -> 1.185 --- Log message: Implement "general dynamic", "initial exec" and "local exec" TLS models for X86 32 bits. --- Diffs of the changes: (+16 -4) SelectionDAG.h | 3 +++ SelectionDAGNodes.h | 17 +++++++++++++---- 2 files changed, 16 insertions(+), 4 deletions(-) Index: llvm/include/llvm/CodeGen/SelectionDAG.h diff -u llvm/include/llvm/CodeGen/SelectionDAG.h:1.146 llvm/include/llvm/CodeGen/SelectionDAG.h:1.147 --- llvm/include/llvm/CodeGen/SelectionDAG.h:1.146 Fri Jan 26 15:22:28 2007 +++ llvm/include/llvm/CodeGen/SelectionDAG.h Fri Apr 20 16:38:10 2007 @@ -398,6 +398,9 @@ SDNode *getTargetNode(unsigned Opcode, MVT::ValueType VT1, MVT::ValueType VT2, MVT::ValueType VT3, SDOperand Op1, SDOperand Op2); + SDNode *getTargetNode(unsigned Opcode, MVT::ValueType VT1, + MVT::ValueType VT2, MVT::ValueType VT3, + SDOperand Op1, SDOperand Op2, SDOperand Op3); SDNode *getTargetNode(unsigned Opcode, MVT::ValueType VT1, MVT::ValueType VT2, MVT::ValueType VT3, const SDOperand *Ops, unsigned NumOps); Index: llvm/include/llvm/CodeGen/SelectionDAGNodes.h diff -u llvm/include/llvm/CodeGen/SelectionDAGNodes.h:1.184 llvm/include/llvm/CodeGen/SelectionDAGNodes.h:1.185 --- llvm/include/llvm/CodeGen/SelectionDAGNodes.h:1.184 Tue Apr 17 04:20:00 2007 +++ llvm/include/llvm/CodeGen/SelectionDAGNodes.h Fri Apr 20 16:38:10 2007 @@ -19,6 +19,7 @@ #ifndef LLVM_CODEGEN_SELECTIONDAGNODES_H #define LLVM_CODEGEN_SELECTIONDAGNODES_H +#include "llvm/GlobalVariable.h" #include "llvm/Value.h" #include "llvm/ADT/FoldingSet.h" #include "llvm/ADT/GraphTraits.h" @@ -95,7 +96,8 @@ // Various leaf nodes. STRING, BasicBlock, VALUETYPE, CONDCODE, Register, Constant, ConstantFP, - GlobalAddress, FrameIndex, JumpTable, ConstantPool, ExternalSymbol, + GlobalAddress, GlobalTLSAddress, FrameIndex, + JumpTable, ConstantPool, ExternalSymbol, // The address of the GOT GLOBAL_OFFSET_TABLE, @@ -124,6 +126,7 @@ // anything else with this node, and this is valid in the target-specific // dag, turning into a GlobalAddress operand. TargetGlobalAddress, + TargetGlobalTLSAddress, TargetFrameIndex, TargetJumpTable, TargetConstantPool, @@ -1164,7 +1167,12 @@ friend class SelectionDAG; GlobalAddressSDNode(bool isTarget, const GlobalValue *GA, MVT::ValueType VT, int o = 0) - : SDNode(isTarget ? ISD::TargetGlobalAddress : ISD::GlobalAddress, + : SDNode(dyn_cast<GlobalVariable>(GA) && + dyn_cast<GlobalVariable>(GA)->isThreadLocal() ? + // Thread Local + (isTarget ? ISD::TargetGlobalTLSAddress : ISD::GlobalTLSAddress) : + // Non Thread Local + (isTarget ? ISD::TargetGlobalAddress : ISD::GlobalAddress), getSDVTList(VT)), Offset(o) { TheGlobal = const_cast<GlobalValue*>(GA); } @@ -1176,11 +1184,12 @@ static bool classof(const GlobalAddressSDNode *) { return true; } static bool classof(const SDNode *N) { return N->getOpcode() == ISD::GlobalAddress || - N->getOpcode() == ISD::TargetGlobalAddress; + N->getOpcode() == ISD::TargetGlobalAddress || + N->getOpcode() == ISD::GlobalTLSAddress || + N->getOpcode() == ISD::TargetGlobalTLSAddress; } }; - class FrameIndexSDNode : public SDNode { int FI; virtual void ANCHOR(); // Out-of-line virtual method to give class a home. _______________________________________________ llvm-commits mailing list llvm-commits@cs.uiuc.edu http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits