Some related changes as well.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
llvm/include/llvm/CodeGen/MachineRegisterInfo.h | ||
---|---|---|
635 | What is the difference of the RegUnit vs Register? Should we rename the names to be just Reg as well? |
llvm/include/llvm/CodeGen/MachineRegisterInfo.h | ||
---|---|---|
635 | Not sure, but I'd decouple that from the strong-typing exercise though. |
My understanding is that MCRegister values take a subset [0,2**30). In some cases MCRegister is more suitable than Register. Have you checked whether some places should use MCRegister instead?
Yes - that's part of the focus of these refactorings - i.e. using Register / MCRegister appropriately (instead of unsigned). My approach has been to look at how the value was used. In these cases, it appears the value may be virtual - because there were checks to that extent. Having said that, it is possible there are cases where those checks were themselves redundant (i.e. should / could have been asserts before). Maybe I missed something, I'll take another look.
What is the difference of the RegUnit vs Register? Should we rename the names to be just Reg as well?