add stacksave/stackrestore nodes
authorChris Lattner <sabre@nondot.org>
Fri, 13 Jan 2006 02:39:42 +0000 (02:39 +0000)
committerChris Lattner <sabre@nondot.org>
Fri, 13 Jan 2006 02:39:42 +0000 (02:39 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25270 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/CodeGen/SelectionDAGNodes.h
lib/CodeGen/SelectionDAG/SelectionDAG.cpp

index 032f319a96039cbcfff0464ff2579c2fd5ef2334..0ee64f6452fea7aaf00bc8942ff36b93e5b5162e 100644 (file)
@@ -312,6 +312,15 @@ namespace ISD {
     CALL,
     TAILCALL,
 
+    // STACKSAVE - STACKSAVE has one operand, an input chain.  It produces a
+    // value, the same type as the pointer type for the system, and an output
+    // chain.
+    STACKSAVE,
+    
+    // STACKRESTORE has two operands, an input chain and a pointer to restore to
+    // it returns an output chain.
+    STACKRESTORE,
+    
     // MEMSET/MEMCPY/MEMMOVE - The first operand is the chain, and the rest
     // correspond to the operands of the LLVM intrinsic functions.  The only
     // result is a token chain.  The alignment argument is guaranteed to be a
index a89660bb4b4ccbfa10598cdaed70895236701ca7..0936ccee3284b501d04c91cb3b1595b7134d47cf 100644 (file)
@@ -1982,8 +1982,12 @@ const char *SDNode::getOperationName(const SelectionDAG *G) const {
   case ISD::TRUNCSTORE: return "truncstore";
 
   case ISD::DYNAMIC_STACKALLOC: return "dynamic_stackalloc";
-  case ISD::EXTRACT_ELEMENT: return "extract_element";
-  case ISD::BUILD_PAIR: return "build_pair";
+  case ISD::EXTRACT_ELEMENT:    return "extract_element";
+  case ISD::BUILD_PAIR:         return "build_pair";
+  case ISD::STACKSAVE:          return "stacksave";
+  case ISD::STACKRESTORE:       return "stackrestore";
+    
+  // Block memory operations.
   case ISD::MEMSET:  return "memset";
   case ISD::MEMCPY:  return "memcpy";
   case ISD::MEMMOVE: return "memmove";