OSDN Git Service

add LSBaseSDNode::getOffset at Dan's request.
authorChris Lattner <sabre@nondot.org>
Mon, 25 Feb 2008 19:31:21 +0000 (19:31 +0000)
committerChris Lattner <sabre@nondot.org>
Mon, 25 Feb 2008 19:31:21 +0000 (19:31 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47558 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/CodeGen/SelectionDAGNodes.h

index 6996c69..64c9fe3 100644 (file)
@@ -1638,6 +1638,9 @@ public:
   const SDOperand &getBasePtr() const {
     return getOperand(getOpcode() == ISD::LOAD ? 1 : 2);
   }
+  const SDOperand &getOffset() const {
+    return getOperand(getOpcode() == ISD::LOAD ? 2 : 3);
+  }
 
   const Value *getSrcValue() const { return SrcValue; }
   int getSrcValueOffset() const { return SVOffset; }