aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2003-01-13 00:19:44 +0000
committerChris Lattner <sabre@nondot.org>2003-01-13 00:19:44 +0000
commit09d4fd57de5ffa254808cc8ae71cd72ab2433911 (patch)
treedd63ec0854bada136ac3a608d58941f52fb090ab
parente836bae30c73e4d63e1126c3308dccba350a4154 (diff)
Add new getName method
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5212 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--include/llvm/Target/MRegisterInfo.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/llvm/Target/MRegisterInfo.h b/include/llvm/Target/MRegisterInfo.h
index 8221e606d8..41b01546ed 100644
--- a/include/llvm/Target/MRegisterInfo.h
+++ b/include/llvm/Target/MRegisterInfo.h
@@ -33,6 +33,7 @@ struct MRegisterDesc {
///
namespace MRF { // MRF = Machine Register Flags
enum {
+ Other = 0 << 0, // This is a non-standard register
INT8 = 1 << 0, // This is an 8 bit integer register
INT16 = 1 << 1, // This is a 16 bit integer register
INT32 = 1 << 2, // This is a 32 bit integer register
@@ -173,6 +174,12 @@ public:
return get(RegNo).AliasSet;
}
+ /// getName - Return the symbolic target specific name for the specified
+ /// physical register.
+ const char *getName(unsigned RegNo) const {
+ return get(RegNo).Name;
+ }
+
virtual const unsigned* getCalleeSaveRegs() const = 0;