OLD | NEW |
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_X87 | 5 #if V8_TARGET_ARCH_X87 |
6 | 6 |
7 #include "src/code-stubs.h" | 7 #include "src/code-stubs.h" |
8 #include "src/api-arguments.h" | 8 #include "src/api-arguments.h" |
9 #include "src/base/bits.h" | 9 #include "src/base/bits.h" |
10 #include "src/bootstrapper.h" | 10 #include "src/bootstrapper.h" |
(...skipping 2417 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2428 void BinaryOpICWithAllocationSiteStub::Generate(MacroAssembler* masm) { | 2428 void BinaryOpICWithAllocationSiteStub::Generate(MacroAssembler* masm) { |
2429 // ----------- S t a t e ------------- | 2429 // ----------- S t a t e ------------- |
2430 // -- edx : left | 2430 // -- edx : left |
2431 // -- eax : right | 2431 // -- eax : right |
2432 // -- esp[0] : return address | 2432 // -- esp[0] : return address |
2433 // ----------------------------------- | 2433 // ----------------------------------- |
2434 | 2434 |
2435 // Load ecx with the allocation site. We stick an undefined dummy value here | 2435 // Load ecx with the allocation site. We stick an undefined dummy value here |
2436 // and replace it with the real allocation site later when we instantiate this | 2436 // and replace it with the real allocation site later when we instantiate this |
2437 // stub in BinaryOpICWithAllocationSiteStub::GetCodeCopyFromTemplate(). | 2437 // stub in BinaryOpICWithAllocationSiteStub::GetCodeCopyFromTemplate(). |
2438 __ mov(ecx, handle(isolate()->heap()->undefined_value())); | 2438 __ mov(ecx, isolate()->factory()->undefined_value()); |
2439 | 2439 |
2440 // Make sure that we actually patched the allocation site. | 2440 // Make sure that we actually patched the allocation site. |
2441 if (FLAG_debug_code) { | 2441 if (FLAG_debug_code) { |
2442 __ test(ecx, Immediate(kSmiTagMask)); | 2442 __ test(ecx, Immediate(kSmiTagMask)); |
2443 __ Assert(not_equal, kExpectedAllocationSite); | 2443 __ Assert(not_equal, kExpectedAllocationSite); |
2444 __ cmp(FieldOperand(ecx, HeapObject::kMapOffset), | 2444 __ cmp(FieldOperand(ecx, HeapObject::kMapOffset), |
2445 isolate()->factory()->allocation_site_map()); | 2445 isolate()->factory()->allocation_site_map()); |
2446 __ Assert(equal, kExpectedAllocationSite); | 2446 __ Assert(equal, kExpectedAllocationSite); |
2447 } | 2447 } |
2448 | 2448 |
(...skipping 2936 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5385 kStackUnwindSpace, nullptr, return_value_operand, | 5385 kStackUnwindSpace, nullptr, return_value_operand, |
5386 NULL); | 5386 NULL); |
5387 } | 5387 } |
5388 | 5388 |
5389 #undef __ | 5389 #undef __ |
5390 | 5390 |
5391 } // namespace internal | 5391 } // namespace internal |
5392 } // namespace v8 | 5392 } // namespace v8 |
5393 | 5393 |
5394 #endif // V8_TARGET_ARCH_X87 | 5394 #endif // V8_TARGET_ARCH_X87 |
OLD | NEW |