Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1706)

Unified Diff: src/IceInstX8664.cpp

Issue 2100333002: Reorder X8664 Register Defs so that scratch registers are allocated first (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Address Comments Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/IceInstX8664.def » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/IceInstX8664.cpp
diff --git a/src/IceInstX8664.cpp b/src/IceInstX8664.cpp
index afb458047a89784e30d763b9400ada315248b924..d83c47e21c66f506e1c467ba10f9f3a62f4a653e 100644
--- a/src/IceInstX8664.cpp
+++ b/src/IceInstX8664.cpp
@@ -161,10 +161,10 @@ void TargetX8664Traits::X86OperandMem::emit(const Cfg *Func) const {
const Type MemType = getType();
if (Base->getType() != IceType_i32 && MemType != IceType_void) {
// X86-64 is ILP32, but %rsp and %rbp are accessed as 64-bit registers.
- // For filetype=asm, they need to be emitted as their 32-bit sibilings.
+ // For filetype=asm, they need to be emitted as their 32-bit siblings.
assert(Base->getType() == IceType_i64);
- assert(Base->getRegNum() == RegX8664::Encoded_Reg_rsp ||
- Base->getRegNum() == RegX8664::Encoded_Reg_rbp ||
+ assert(getEncodedGPR(Base->getRegNum()) == RegX8664::Encoded_Reg_rsp ||
+ getEncodedGPR(Base->getRegNum()) == RegX8664::Encoded_Reg_rbp ||
getType() == IceType_void);
B = B->asType(Func, IceType_i32, X8664::Traits::getGprForType(
IceType_i32, Base->getRegNum()));
« no previous file with comments | « no previous file | src/IceInstX8664.def » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698