commit | e8a3cc68782cc5d43d7b8e24c4afa94448905349 | [log] [tgz] |
---|---|---|
author | Jakob Stoklund Olesen <stoklund@2pi.dk> | Wed Mar 13 18:11:17 2013 +0000 |
committer | Jakob Stoklund Olesen <stoklund@2pi.dk> | Wed Mar 13 18:11:17 2013 +0000 |
tree | 910ba533f6933aedfeb5d2f0f4c669470720ab0b | |
parent | d8bfde0c6a4fad3b8846af4e4d19d9a3cbbce0b2 [diff] |
Check register classes also when changing them. We have the same assertion in createVirtualRegister. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@176959 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/CodeGen/MachineRegisterInfo.cpp b/lib/CodeGen/MachineRegisterInfo.cpp index a777f52..1af00e8 100644 --- a/lib/CodeGen/MachineRegisterInfo.cpp +++ b/lib/CodeGen/MachineRegisterInfo.cpp
@@ -37,6 +37,7 @@ /// void MachineRegisterInfo::setRegClass(unsigned Reg, const TargetRegisterClass *RC) { + assert(RC && RC->isAllocatable() && "Invalid RC for virtual register"); VRegInfo[Reg].first = RC; }