OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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_ARM64 | 5 #if V8_TARGET_ARCH_ARM64 |
6 | 6 |
7 #include "src/base/bits.h" | 7 #include "src/base/bits.h" |
8 #include "src/base/division-by-constant.h" | 8 #include "src/base/division-by-constant.h" |
9 #include "src/bootstrapper.h" | 9 #include "src/bootstrapper.h" |
10 #include "src/codegen.h" | 10 #include "src/codegen.h" |
(...skipping 4014 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4025 | 4025 |
4026 // Load store buffer top. | 4026 // Load store buffer top. |
4027 Mov(scratch2, ExternalReference::store_buffer_top(isolate())); | 4027 Mov(scratch2, ExternalReference::store_buffer_top(isolate())); |
4028 Ldr(scratch1, MemOperand(scratch2)); | 4028 Ldr(scratch1, MemOperand(scratch2)); |
4029 // Store pointer to buffer and increment buffer top. | 4029 // Store pointer to buffer and increment buffer top. |
4030 Str(address, MemOperand(scratch1, kPointerSize, PostIndex)); | 4030 Str(address, MemOperand(scratch1, kPointerSize, PostIndex)); |
4031 // Write back new top of buffer. | 4031 // Write back new top of buffer. |
4032 Str(scratch1, MemOperand(scratch2)); | 4032 Str(scratch1, MemOperand(scratch2)); |
4033 // Call stub on end of buffer. | 4033 // Call stub on end of buffer. |
4034 // Check for end of buffer. | 4034 // Check for end of buffer. |
4035 DCHECK(StoreBuffer::kStoreBufferOverflowBit == | 4035 Tst(scratch1, StoreBuffer::kStoreBufferMask); |
4036 (1 << (14 + kPointerSizeLog2))); | |
4037 if (and_then == kFallThroughAtEnd) { | 4036 if (and_then == kFallThroughAtEnd) { |
4038 Tbz(scratch1, (14 + kPointerSizeLog2), &done); | 4037 B(ne, &done); |
4039 } else { | 4038 } else { |
4040 DCHECK(and_then == kReturnAtEnd); | 4039 DCHECK(and_then == kReturnAtEnd); |
4041 Tbnz(scratch1, (14 + kPointerSizeLog2), &store_buffer_overflow); | 4040 B(eq, &store_buffer_overflow); |
4042 Ret(); | 4041 Ret(); |
4043 } | 4042 } |
4044 | 4043 |
4045 Bind(&store_buffer_overflow); | 4044 Bind(&store_buffer_overflow); |
4046 Push(lr); | 4045 Push(lr); |
4047 StoreBufferOverflowStub store_buffer_overflow_stub(isolate(), fp_mode); | 4046 StoreBufferOverflowStub store_buffer_overflow_stub(isolate(), fp_mode); |
4048 CallStub(&store_buffer_overflow_stub); | 4047 CallStub(&store_buffer_overflow_stub); |
4049 Pop(lr); | 4048 Pop(lr); |
4050 | 4049 |
4051 Bind(&done); | 4050 Bind(&done); |
(...skipping 1041 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5093 } | 5092 } |
5094 | 5093 |
5095 | 5094 |
5096 #undef __ | 5095 #undef __ |
5097 | 5096 |
5098 | 5097 |
5099 } // namespace internal | 5098 } // namespace internal |
5100 } // namespace v8 | 5099 } // namespace v8 |
5101 | 5100 |
5102 #endif // V8_TARGET_ARCH_ARM64 | 5101 #endif // V8_TARGET_ARCH_ARM64 |
OLD | NEW |