[llvm-commits] CVS: llvm/include/llvm/Target/MRegisterInfo.h
Chris Lattner
lattner at cs.uiuc.edu
Sun Dec 15 12:41:01 PST 2002
Changes in directory llvm/include/llvm/Target:
MRegisterInfo.h updated: 1.8 -> 1.9
---
Log message:
* Rename const_regclass_begin/end to just regclass_begin/end
* Regclass iterators need an extra level of pointerness to work right
* Pull inverse mapping code out of target description files
---
Diffs of the changes:
Index: llvm/include/llvm/Target/MRegisterInfo.h
diff -u llvm/include/llvm/Target/MRegisterInfo.h:1.8 llvm/include/llvm/Target/MRegisterInfo.h:1.9
--- llvm/include/llvm/Target/MRegisterInfo.h:1.8 Fri Dec 13 03:54:10 2002
+++ llvm/include/llvm/Target/MRegisterInfo.h Sun Dec 15 12:40:01 2002
@@ -10,7 +10,6 @@
#define LLVM_TARGET_MREGISTERINFO_H
#include "llvm/CodeGen/MachineBasicBlock.h"
-#include <map>
#include <assert.h>
class Type;
@@ -61,15 +60,6 @@
virtual unsigned getDataSize() const { return 0; }
- void
- buildReg2RegClassMap(std::map<unsigned,const TargetRegisterClass*>&
- Reg2RegClassMap) const
- {
- for (unsigned i=0; i < getNumRegs(); ++i) {
- Reg2RegClassMap[getRegister(i)] = this;
- }
- }
-
//const std::vector<unsigned> &getRegsInClass(void) { return Regs; }
//void getAliases(void);
};
@@ -156,23 +146,13 @@
virtual unsigned getStackPointer() const = 0;
/// Register class iterators
- typedef const TargetRegisterClass* const_iterator;
+ typedef const TargetRegisterClass** const_iterator;
- virtual const_iterator const_regclass_begin() const = 0;
- virtual const_iterator const_regclass_end() const = 0;
+ virtual const_iterator regclass_begin() const = 0;
+ virtual const_iterator regclass_end() const = 0;
virtual unsigned getNumRegClasses() const = 0;
virtual const TargetRegisterClass* getRegClassForType(const Type* Ty) const=0;
-
- virtual void
- buildReg2RegClassMap(std::map<unsigned,const TargetRegisterClass*>&
- Reg2RegClassMap) const {
- for (MRegisterInfo::const_iterator I = const_regclass_begin(),
- E = const_regclass_end(); I != E; ++I) {
- I->buildReg2RegClassMap(Reg2RegClassMap);
- }
- }
-
};
#endif
More information about the llvm-commits
mailing list