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

Side by Side Diff: src/crankshaft/ia32/lithium-codegen-ia32.cc

Issue 1480003002: [runtime] Replace global object link with native context link in all contexts. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Add patch from Orion for interpreter cementation test. Disable obsolete/invalid tests. Created 5 years 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 unified diff | Download patch
« no previous file with comments | « src/crankshaft/hydrogen.cc ('k') | src/crankshaft/mips/lithium-codegen-mips.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #if V8_TARGET_ARCH_IA32 5 #if V8_TARGET_ARCH_IA32
6 6
7 #include "src/crankshaft/ia32/lithium-codegen-ia32.h" 7 #include "src/crankshaft/ia32/lithium-codegen-ia32.h"
8 8
9 #include "src/base/bits.h" 9 #include "src/base/bits.h"
10 #include "src/code-factory.h" 10 #include "src/code-factory.h"
(...skipping 3170 matching lines...) Expand 10 before | Expand all | Expand 10 after
3181 3181
3182 // The receiver should be a JS object. 3182 // The receiver should be a JS object.
3183 __ test(receiver, Immediate(kSmiTagMask)); 3183 __ test(receiver, Immediate(kSmiTagMask));
3184 DeoptimizeIf(equal, instr, Deoptimizer::kSmi); 3184 DeoptimizeIf(equal, instr, Deoptimizer::kSmi);
3185 __ CmpObjectType(receiver, FIRST_SPEC_OBJECT_TYPE, scratch); 3185 __ CmpObjectType(receiver, FIRST_SPEC_OBJECT_TYPE, scratch);
3186 DeoptimizeIf(below, instr, Deoptimizer::kNotAJavaScriptObject); 3186 DeoptimizeIf(below, instr, Deoptimizer::kNotAJavaScriptObject);
3187 3187
3188 __ jmp(&receiver_ok, Label::kNear); 3188 __ jmp(&receiver_ok, Label::kNear);
3189 __ bind(&global_object); 3189 __ bind(&global_object);
3190 __ mov(receiver, FieldOperand(function, JSFunction::kContextOffset)); 3190 __ mov(receiver, FieldOperand(function, JSFunction::kContextOffset));
3191 const int global_offset = Context::SlotOffset(Context::GLOBAL_OBJECT_INDEX); 3191 __ mov(receiver, ContextOperand(receiver, Context::NATIVE_CONTEXT_INDEX));
3192 __ mov(receiver, Operand(receiver, global_offset)); 3192 __ mov(receiver, ContextOperand(receiver, Context::GLOBAL_PROXY_INDEX));
3193 const int proxy_offset = JSGlobalObject::kGlobalProxyOffset;
3194 __ mov(receiver, FieldOperand(receiver, proxy_offset));
3195 __ bind(&receiver_ok); 3193 __ bind(&receiver_ok);
3196 } 3194 }
3197 3195
3198 3196
3199 void LCodeGen::DoApplyArguments(LApplyArguments* instr) { 3197 void LCodeGen::DoApplyArguments(LApplyArguments* instr) {
3200 Register receiver = ToRegister(instr->receiver()); 3198 Register receiver = ToRegister(instr->receiver());
3201 Register function = ToRegister(instr->function()); 3199 Register function = ToRegister(instr->function());
3202 Register length = ToRegister(instr->length()); 3200 Register length = ToRegister(instr->length());
3203 Register elements = ToRegister(instr->elements()); 3201 Register elements = ToRegister(instr->elements());
3204 DCHECK(receiver.is(eax)); // Used for parameter count. 3202 DCHECK(receiver.is(eax)); // Used for parameter count.
(...skipping 2385 matching lines...) Expand 10 before | Expand all | Expand 10 after
5590 RecordSafepoint(Safepoint::kNoLazyDeopt); 5588 RecordSafepoint(Safepoint::kNoLazyDeopt);
5591 } 5589 }
5592 5590
5593 5591
5594 #undef __ 5592 #undef __
5595 5593
5596 } // namespace internal 5594 } // namespace internal
5597 } // namespace v8 5595 } // namespace v8
5598 5596
5599 #endif // V8_TARGET_ARCH_IA32 5597 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/crankshaft/hydrogen.cc ('k') | src/crankshaft/mips/lithium-codegen-mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698