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 | 8dc728e4408fdfb02505d6a6862daae801e486ce (patch) | |
tree | 693b12a3c3d3a1534a002f9da4de52b5617bd7cc /utils | |
parent | 6f3241dbbf6926a1ad1d0e2f1e50e6228a55b258 (diff) | |
download | llvm-8dc728e4408fdfb02505d6a6862daae801e486ce.tar.gz llvm-8dc728e4408fdfb02505d6a6862daae801e486ce.tar.bz2 llvm-8dc728e4408fdfb02505d6a6862daae801e486ce.tar.xz |
Use compiler.h instead of hand rolling our own macro
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@29913 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'utils')
-rw-r--r-- | utils/TableGen/DAGISelEmitter.cpp | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/utils/TableGen/DAGISelEmitter.cpp b/utils/TableGen/DAGISelEmitter.cpp index 72bc1e2a32..d45e6d24a8 100644 --- a/utils/TableGen/DAGISelEmitter.cpp +++ b/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"; |