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 #include <limits.h> // For LONG_MIN, LONG_MAX. | 5 #include <limits.h> // For LONG_MIN, LONG_MAX. |
6 | 6 |
7 #if V8_TARGET_ARCH_ARM | 7 #if V8_TARGET_ARCH_ARM |
8 | 8 |
9 #include "src/base/bits.h" | 9 #include "src/base/bits.h" |
10 #include "src/base/division-by-constant.h" | 10 #include "src/base/division-by-constant.h" |
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
113 // movw ip, #... @ call address low 16 | 113 // movw ip, #... @ call address low 16 |
114 // movt ip, #... @ call address high 16 | 114 // movt ip, #... @ call address high 16 |
115 // blx ip | 115 // blx ip |
116 // @ return address | 116 // @ return address |
117 // Or for pre-V7 or values that may be back-patched | 117 // Or for pre-V7 or values that may be back-patched |
118 // to avoid ICache flushes: | 118 // to avoid ICache flushes: |
119 // ldr ip, [pc, #...] @ call address | 119 // ldr ip, [pc, #...] @ call address |
120 // blx ip | 120 // blx ip |
121 // @ return address | 121 // @ return address |
122 | 122 |
123 // Statement positions are expected to be recorded when the target | |
124 // address is loaded. The mov method will automatically record | |
125 // positions when pc is the target, since this is not the case here | |
126 // we have to do it explicitly. | |
127 positions_recorder()->WriteRecordedPositions(); | |
128 | |
129 mov(ip, Operand(reinterpret_cast<int32_t>(target), rmode)); | 123 mov(ip, Operand(reinterpret_cast<int32_t>(target), rmode)); |
130 blx(ip, cond); | 124 blx(ip, cond); |
131 | 125 |
132 DCHECK_EQ(expected_size, SizeOfCodeGeneratedSince(&start)); | 126 DCHECK_EQ(expected_size, SizeOfCodeGeneratedSince(&start)); |
133 if (mode == NEVER_INLINE_TARGET_ADDRESS) { | 127 if (mode == NEVER_INLINE_TARGET_ADDRESS) { |
134 set_predictable_code_size(old_predictable_code_size); | 128 set_predictable_code_size(old_predictable_code_size); |
135 } | 129 } |
136 } | 130 } |
137 | 131 |
138 | 132 |
(...skipping 3903 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4042 } | 4036 } |
4043 } | 4037 } |
4044 if (mag.shift > 0) mov(result, Operand(result, ASR, mag.shift)); | 4038 if (mag.shift > 0) mov(result, Operand(result, ASR, mag.shift)); |
4045 add(result, result, Operand(dividend, LSR, 31)); | 4039 add(result, result, Operand(dividend, LSR, 31)); |
4046 } | 4040 } |
4047 | 4041 |
4048 } // namespace internal | 4042 } // namespace internal |
4049 } // namespace v8 | 4043 } // namespace v8 |
4050 | 4044 |
4051 #endif // V8_TARGET_ARCH_ARM | 4045 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |