OLD | NEW |
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 2747 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2758 bool do_gc, | 2758 bool do_gc, |
2759 bool always_allocate) { | 2759 bool always_allocate) { |
2760 // r0: result parameter for PerformGC, if any | 2760 // r0: result parameter for PerformGC, if any |
2761 // r4: number of arguments including receiver (C callee-saved) | 2761 // r4: number of arguments including receiver (C callee-saved) |
2762 // r5: pointer to builtin function (C callee-saved) | 2762 // r5: pointer to builtin function (C callee-saved) |
2763 // r6: pointer to the first argument (C callee-saved) | 2763 // r6: pointer to the first argument (C callee-saved) |
2764 Isolate* isolate = masm->isolate(); | 2764 Isolate* isolate = masm->isolate(); |
2765 | 2765 |
2766 if (do_gc) { | 2766 if (do_gc) { |
2767 // Passing r0. | 2767 // Passing r0. |
2768 __ PrepareCallCFunction(2, 0, r1); | 2768 __ PrepareCallCFunction(1, 0, r1); |
2769 __ mov(r1, Operand(ExternalReference::isolate_address(masm->isolate()))); | |
2770 __ CallCFunction(ExternalReference::perform_gc_function(isolate), | 2769 __ CallCFunction(ExternalReference::perform_gc_function(isolate), |
2771 2, 0); | 2770 1, 0); |
2772 } | 2771 } |
2773 | 2772 |
2774 ExternalReference scope_depth = | 2773 ExternalReference scope_depth = |
2775 ExternalReference::heap_always_allocate_scope_depth(isolate); | 2774 ExternalReference::heap_always_allocate_scope_depth(isolate); |
2776 if (always_allocate) { | 2775 if (always_allocate) { |
2777 __ mov(r0, Operand(scope_depth)); | 2776 __ mov(r0, Operand(scope_depth)); |
2778 __ ldr(r1, MemOperand(r0)); | 2777 __ ldr(r1, MemOperand(r0)); |
2779 __ add(r1, r1, Operand(1)); | 2778 __ add(r1, r1, Operand(1)); |
2780 __ str(r1, MemOperand(r0)); | 2779 __ str(r1, MemOperand(r0)); |
2781 } | 2780 } |
(...skipping 587 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3369 ASSERT(kind() == Code::LOAD_IC); | 3368 ASSERT(kind() == Code::LOAD_IC); |
3370 // ----------- S t a t e ------------- | 3369 // ----------- S t a t e ------------- |
3371 // -- r2 : name | 3370 // -- r2 : name |
3372 // -- lr : return address | 3371 // -- lr : return address |
3373 // -- r0 : receiver | 3372 // -- r0 : receiver |
3374 // -- sp[0] : receiver | 3373 // -- sp[0] : receiver |
3375 // ----------------------------------- | 3374 // ----------------------------------- |
3376 receiver = r0; | 3375 receiver = r0; |
3377 } | 3376 } |
3378 | 3377 |
3379 StubCompiler::GenerateLoadStringLength(masm, receiver, r3, r4, &miss); | 3378 StubCompiler::GenerateLoadStringLength(masm, receiver, r3, r4, &miss, |
| 3379 support_wrapper_); |
3380 | 3380 |
3381 __ bind(&miss); | 3381 __ bind(&miss); |
3382 StubCompiler::TailCallBuiltin( | 3382 StubCompiler::TailCallBuiltin( |
3383 masm, BaseLoadStoreStubCompiler::MissBuiltin(kind())); | 3383 masm, BaseLoadStoreStubCompiler::MissBuiltin(kind())); |
3384 } | 3384 } |
3385 | 3385 |
3386 | 3386 |
3387 void StoreArrayLengthStub::Generate(MacroAssembler* masm) { | 3387 void StoreArrayLengthStub::Generate(MacroAssembler* masm) { |
3388 // This accepts as a receiver anything JSArray::SetElementsLength accepts | 3388 // This accepts as a receiver anything JSArray::SetElementsLength accepts |
3389 // (currently anything except for external arrays which means anything with | 3389 // (currently anything except for external arrays which means anything with |
(...skipping 3764 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7154 __ bind(&fast_elements_case); | 7154 __ bind(&fast_elements_case); |
7155 GenerateCase(masm, FAST_ELEMENTS); | 7155 GenerateCase(masm, FAST_ELEMENTS); |
7156 } | 7156 } |
7157 | 7157 |
7158 | 7158 |
7159 #undef __ | 7159 #undef __ |
7160 | 7160 |
7161 } } // namespace v8::internal | 7161 } } // namespace v8::internal |
7162 | 7162 |
7163 #endif // V8_TARGET_ARCH_ARM | 7163 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |