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(1, 0, r1); | 2768 __ PrepareCallCFunction(2, 0, r1); |
| 2769 __ mov(r1, Operand(ExternalReference::isolate_address(masm->isolate()))); |
2769 __ CallCFunction(ExternalReference::perform_gc_function(isolate), | 2770 __ CallCFunction(ExternalReference::perform_gc_function(isolate), |
2770 1, 0); | 2771 2, 0); |
2771 } | 2772 } |
2772 | 2773 |
2773 ExternalReference scope_depth = | 2774 ExternalReference scope_depth = |
2774 ExternalReference::heap_always_allocate_scope_depth(isolate); | 2775 ExternalReference::heap_always_allocate_scope_depth(isolate); |
2775 if (always_allocate) { | 2776 if (always_allocate) { |
2776 __ mov(r0, Operand(scope_depth)); | 2777 __ mov(r0, Operand(scope_depth)); |
2777 __ ldr(r1, MemOperand(r0)); | 2778 __ ldr(r1, MemOperand(r0)); |
2778 __ add(r1, r1, Operand(1)); | 2779 __ add(r1, r1, Operand(1)); |
2779 __ str(r1, MemOperand(r0)); | 2780 __ str(r1, MemOperand(r0)); |
2780 } | 2781 } |
(...skipping 4373 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7154 __ bind(&fast_elements_case); | 7155 __ bind(&fast_elements_case); |
7155 GenerateCase(masm, FAST_ELEMENTS); | 7156 GenerateCase(masm, FAST_ELEMENTS); |
7156 } | 7157 } |
7157 | 7158 |
7158 | 7159 |
7159 #undef __ | 7160 #undef __ |
7160 | 7161 |
7161 } } // namespace v8::internal | 7162 } } // namespace v8::internal |
7162 | 7163 |
7163 #endif // V8_TARGET_ARCH_ARM | 7164 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |