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

Unified Diff: src/ic/x87/handler-compiler-x87.cc

Issue 877343003: Fix register aliasing after r26306, r26275. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Remove comment Created 5 years, 11 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 | « src/ic/x64/handler-compiler-x64.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ic/x87/handler-compiler-x87.cc
diff --git a/src/ic/x87/handler-compiler-x87.cc b/src/ic/x87/handler-compiler-x87.cc
index 6b97ccb0fb3de0beaa4dced361c1f7909a788273..091e009a6320920cbf9815d0e5264efd94736cd0 100644
--- a/src/ic/x87/handler-compiler-x87.cc
+++ b/src/ic/x87/handler-compiler-x87.cc
@@ -18,16 +18,20 @@ namespace internal {
void NamedLoadHandlerCompiler::GenerateLoadViaGetter(
MacroAssembler* masm, Handle<HeapType> type, Register receiver,
- Register holder, int accessor_index, int expected_arguments) {
+ Register holder, int accessor_index, int expected_arguments,
+ Register scratch) {
{
FrameScope scope(masm, StackFrame::INTERNAL);
if (accessor_index >= 0) {
+ DCHECK(!holder.is(scratch));
+ DCHECK(!receiver.is(scratch));
// Call the JavaScript getter with the receiver on the stack.
if (IC::TypeToMap(*type, masm->isolate())->IsJSGlobalObjectMap()) {
// Swap in the global receiver.
- __ mov(receiver,
+ __ mov(scratch,
FieldOperand(receiver, JSGlobalObject::kGlobalProxyOffset));
+ receiver = scratch;
}
__ push(receiver);
ParameterCount actual(0);
@@ -231,7 +235,8 @@ void PropertyHandlerCompiler::GenerateCheckPropertyCell(
void NamedStoreHandlerCompiler::GenerateStoreViaSetter(
MacroAssembler* masm, Handle<HeapType> type, Register receiver,
- Register holder, int accessor_index, int expected_arguments) {
+ Register holder, int accessor_index, int expected_arguments,
+ Register scratch) {
// ----------- S t a t e -------------
// -- esp[0] : return address
// -----------------------------------
@@ -242,11 +247,15 @@ void NamedStoreHandlerCompiler::GenerateStoreViaSetter(
__ push(value());
if (accessor_index >= 0) {
+ DCHECK(!holder.is(scratch));
+ DCHECK(!receiver.is(scratch));
+ DCHECK(!value().is(scratch));
// Call the JavaScript setter with receiver and value on the stack.
if (IC::TypeToMap(*type, masm->isolate())->IsJSGlobalObjectMap()) {
// Swap in the global receiver.
- __ mov(receiver,
+ __ mov(scratch,
FieldOperand(receiver, JSGlobalObject::kGlobalProxyOffset));
+ receiver = scratch;
}
__ push(receiver);
__ push(value());
« no previous file with comments | « src/ic/x64/handler-compiler-x64.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698