summaryrefslogtreecommitdiff
path: root/include/llvm/CodeGen
diff options
context:
space:
mode:
authorMicah Villmow <villmow@gmail.com>2012-10-09 22:27:29 +0000
committerMicah Villmow <villmow@gmail.com>2012-10-09 22:27:29 +0000
commit63b8ab29c420703dc5ef32e6d76d9e4d8f60f19e (patch)
tree0bbbe067f88714506cb55da3f3f052c4686d577a /include/llvm/CodeGen
parent2fa8af224ea026f9432e833fd6f42a216423a010 (diff)
downloadllvm-63b8ab29c420703dc5ef32e6d76d9e4d8f60f19e.tar.gz
llvm-63b8ab29c420703dc5ef32e6d76d9e4d8f60f19e.tar.bz2
llvm-63b8ab29c420703dc5ef32e6d76d9e4d8f60f19e.tar.xz
Add in some interfaces that will allow easier access to the pointer address space.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165554 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/CodeGen')
-rw-r--r--include/llvm/CodeGen/SelectionDAGNodes.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/include/llvm/CodeGen/SelectionDAGNodes.h b/include/llvm/CodeGen/SelectionDAGNodes.h
index fd89973263..63d4759265 100644
--- a/include/llvm/CodeGen/SelectionDAGNodes.h
+++ b/include/llvm/CodeGen/SelectionDAGNodes.h
@@ -956,7 +956,12 @@ public:
const MachinePointerInfo &getPointerInfo() const {
return MMO->getPointerInfo();
}
-
+
+ /// getAddressSpace - Return the address space for the associated pointer
+ unsigned getAddressSpace() const {
+ return getPointerInfo().getAddrSpace();
+ }
+
/// refineAlignment - Update this MemSDNode's MachineMemOperand information
/// to reflect the alignment of NewMMO, if it has a greater alignment.
/// This must only be used when the new alignment applies to all users of