diff options
author | Chris Lattner <sabre@nondot.org> | 2006-08-27 13:16:24 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2006-08-27 13:16:24 +0000 |
commit | 251468e9d0a9a1a384bca7f4c0b4d212f85670a5 (patch) | |
tree | 903dc11b4b6f981f56dc77663b4547f3afd4f28d | |
parent | 3385b922de4660cd511dcbfb560ea84a8edcd48d (diff) | |
download | bcm5719-llvm-251468e9d0a9a1a384bca7f4c0b4d212f85670a5.tar.gz bcm5719-llvm-251468e9d0a9a1a384bca7f4c0b4d212f85670a5.zip |
Use compiler.h instead of hand rolling our own macro
llvm-svn: 29913
-rw-r--r-- | llvm/utils/TableGen/DAGISelEmitter.cpp | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/llvm/utils/TableGen/DAGISelEmitter.cpp b/llvm/utils/TableGen/DAGISelEmitter.cpp index 72bc1e2a327..d45e6d24a83 100644 --- a/llvm/utils/TableGen/DAGISelEmitter.cpp +++ b/llvm/utils/TableGen/DAGISelEmitter.cpp @@ -3355,7 +3355,7 @@ void DAGISelEmitter::EmitInstructionSelector(std::ostream &OS) { CalleeCode += ") "; // Prevent emission routines from being inlined to reduce selection // routines stack frame sizes. - CalleeCode += "NOINLINE "; + CalleeCode += "DISABLE_INLINE "; CalleeCode += "{\n"; for (std::vector<std::string>::const_reverse_iterator @@ -3565,12 +3565,7 @@ void DAGISelEmitter::run(std::ostream &OS) { << "// *** instruction selector class. These functions are really " << "methods.\n\n"; - OS << "#if defined(__GNUC__) && \\\n"; - OS << " ((__GNUC__ > 3) || ((__GNUC__ == 3) && (__GNUC_MINOR__ >= 4)))\n"; - OS << "#define NOINLINE __attribute__((noinline))\n"; - OS << "#else\n"; - OS << "#define NOINLINE\n"; - OS << "#endif\n\n"; + OS << "#include \"llvm/Support/Compiler.h\"\n"; OS << "// Instruction selector priority queue:\n" << "std::vector<SDNode*> ISelQueue;\n"; @@ -3603,7 +3598,7 @@ void DAGISelEmitter::run(std::ostream &OS) { OS << " return ISelSelected[Id / 8] & (1 << (Id % 8));\n"; OS << "}\n\n"; - OS << "void AddToISelQueue(SDOperand N) NOINLINE {\n"; + OS << "void AddToISelQueue(SDOperand N) DISABLE_INLINE {\n"; OS << " int Id = N.Val->getNodeId();\n"; OS << " if (Id != -1 && !isQueued(Id)) {\n"; OS << " ISelQueue.push_back(N.Val);\n"; @@ -3624,7 +3619,7 @@ OS << " unsigned NumKilled = ISelKilled.size();\n"; OS << " }\n"; OS << "}\n\n"; - OS << "void ReplaceUses(SDOperand F, SDOperand T) NOINLINE {\n"; + OS << "void ReplaceUses(SDOperand F, SDOperand T) DISABLE_INLINE {\n"; OS << " CurDAG->ReplaceAllUsesOfValueWith(F, T, ISelKilled);\n"; OS << " setSelected(F.Val->getNodeId());\n"; OS << " RemoveKilled();\n"; |