-
-
Notifications
You must be signed in to change notification settings - Fork 121
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Break getPhysRegOrStackSlot() uses into getStackSlot() or getPhysRegi…
…ster() Summary: There's a number of uses of getPhysRegOrStackSlot() where the caller already expects the operand to either be a stack slot or a register, or they're going to check which one it is right afterwards. For the former case it's better to use the more specific getter. For the latter case, we're leaking the ">=0 means register, <0 means stack slot" abstraction all throughout the codebase. It's better to use the isStack() and isReg() methods in tandem with the getters. This doesn't get rid of all uses of getPhysRegOrStackSlot(). There are still some legitimate uses in the register allocator in particular. But in the future we should be able to replace them by making LIR operands comparable. Reviewed By: swtaarrs Differential Revision: D56523076 fbshipit-source-id: 2a96624bd1413c7b3023d40327e99fed223c2b2b
- Loading branch information
1 parent
d14ebc9
commit 940fac7
Showing
2 changed files
with
34 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters