diff options
-rw-r--r-- | llvm/utils/TableGen/CodeGenRegisters.h | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/llvm/utils/TableGen/CodeGenRegisters.h b/llvm/utils/TableGen/CodeGenRegisters.h index 6d933baec2a..a8e9e0fbccb 100644 --- a/llvm/utils/TableGen/CodeGenRegisters.h +++ b/llvm/utils/TableGen/CodeGenRegisters.h @@ -635,9 +635,11 @@ namespace llvm { CodeGenSubRegIndex * getConcatSubRegIndex(const SmallVector<CodeGenSubRegIndex *, 8>&); - const std::deque<CodeGenRegister> &getRegisters() { return Registers; } + const std::deque<CodeGenRegister> &getRegisters() const { + return Registers; + } - const StringMap<CodeGenRegister*> &getRegistersByName() { + const StringMap<CodeGenRegister *> &getRegistersByName() const { return RegistersByName; } @@ -686,7 +688,7 @@ namespace llvm { // Native units are the singular unit of a leaf register. Register aliasing // is completely characterized by native units. Adopted units exist to give // register additional weight but don't affect aliasing. - bool isNativeUnit(unsigned RUID) { + bool isNativeUnit(unsigned RUID) const { return RUID < NumNativeRegUnits; } |