aboutsummaryrefslogtreecommitdiff
path: root/llvm/utils/TableGen/CodeGenTarget.h
diff options
context:
space:
mode:
authorJakob Stoklund Olesen <stoklund@2pi.dk>2011-05-07 21:22:39 +0000
committerJakob Stoklund Olesen <stoklund@2pi.dk>2011-05-07 21:22:39 +0000
commitc8c4ded3c65ea0f1527c572b00cf1192516d726d (patch)
tree03e8db64871d5412f9c474c220a0bd39b3a4cce6 /llvm/utils/TableGen/CodeGenTarget.h
parent9ca5465500f6351909a32039007373a367d7bca3 (diff)
downloadllvm-c8c4ded3c65ea0f1527c572b00cf1192516d726d.zip
llvm-c8c4ded3c65ea0f1527c572b00cf1192516d726d.tar.gz
llvm-c8c4ded3c65ea0f1527c572b00cf1192516d726d.tar.bz2
Teach TableGen to automatically generate missing SubRegIndex instances.
The RegisterInfo.td file should only specify the indexes that sources need to refer to. The rest is inferred. llvm-svn: 131058
Diffstat (limited to 'llvm/utils/TableGen/CodeGenTarget.h')
-rw-r--r--llvm/utils/TableGen/CodeGenTarget.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/llvm/utils/TableGen/CodeGenTarget.h b/llvm/utils/TableGen/CodeGenTarget.h
index 4e04154..891b2d5 100644
--- a/llvm/utils/TableGen/CodeGenTarget.h
+++ b/llvm/utils/TableGen/CodeGenTarget.h
@@ -121,6 +121,9 @@ public:
return (i - SubRegIndices.begin()) + 1;
}
+ // Create a new SubRegIndex with the given name.
+ Record *createSubRegIndex(const std::string &Name);
+
const std::vector<CodeGenRegisterClass> &getRegisterClasses() const {
if (RegisterClasses.empty()) ReadRegisterClasses();
return RegisterClasses;