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

Side by Side Diff: src/arm/ic-arm.cc

Issue 104013008: Reland v8:18458 "Load the global proxy from the context of the target function." (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/arm/full-codegen-arm.cc ('k') | src/arm/lithium-codegen-arm.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 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 473 matching lines...) Expand 10 before | Expand all | Expand 10 after
484 Label invoke, global; 484 Label invoke, global;
485 __ ldr(r2, MemOperand(sp, argc * kPointerSize)); // receiver 485 __ ldr(r2, MemOperand(sp, argc * kPointerSize)); // receiver
486 __ JumpIfSmi(r2, &invoke); 486 __ JumpIfSmi(r2, &invoke);
487 __ CompareObjectType(r2, r3, r3, JS_GLOBAL_OBJECT_TYPE); 487 __ CompareObjectType(r2, r3, r3, JS_GLOBAL_OBJECT_TYPE);
488 __ b(eq, &global); 488 __ b(eq, &global);
489 __ cmp(r3, Operand(JS_BUILTINS_OBJECT_TYPE)); 489 __ cmp(r3, Operand(JS_BUILTINS_OBJECT_TYPE));
490 __ b(ne, &invoke); 490 __ b(ne, &invoke);
491 491
492 // Patch the receiver on the stack. 492 // Patch the receiver on the stack.
493 __ bind(&global); 493 __ bind(&global);
494 __ ldr(r2, FieldMemOperand(r2, GlobalObject::kGlobalReceiverOffset)); 494 CallStubCompiler::FetchGlobalProxy(masm, r2, r1);
495 __ str(r2, MemOperand(sp, argc * kPointerSize)); 495 __ str(r2, MemOperand(sp, argc * kPointerSize));
496 __ bind(&invoke); 496 __ bind(&invoke);
497 } 497 }
498 498
499 // Invoke the function. 499 // Invoke the function.
500 CallKind call_kind = CallICBase::Contextual::decode(extra_state) 500 CallKind call_kind = CallICBase::Contextual::decode(extra_state)
501 ? CALL_AS_FUNCTION 501 ? CALL_AS_FUNCTION
502 : CALL_AS_METHOD; 502 : CALL_AS_METHOD;
503 ParameterCount actual(argc); 503 ParameterCount actual(argc);
504 __ InvokeFunction(r1, 504 __ InvokeFunction(r1,
(...skipping 1172 matching lines...) Expand 10 before | Expand all | Expand 10 after
1677 } else { 1677 } else {
1678 ASSERT(Assembler::GetCondition(branch_instr) == ne); 1678 ASSERT(Assembler::GetCondition(branch_instr) == ne);
1679 patcher.EmitCondition(eq); 1679 patcher.EmitCondition(eq);
1680 } 1680 }
1681 } 1681 }
1682 1682
1683 1683
1684 } } // namespace v8::internal 1684 } } // namespace v8::internal
1685 1685
1686 #endif // V8_TARGET_ARCH_ARM 1686 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « src/arm/full-codegen-arm.cc ('k') | src/arm/lithium-codegen-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698