| 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 #include "src/v8.h" | 7 #include "src/v8.h" |
| 8 | 8 |
| 9 #if V8_TARGET_ARCH_ARM | 9 #if V8_TARGET_ARCH_ARM |
| 10 | 10 |
| (...skipping 2251 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2262 JumpIfSmi(obj, &fail); | 2262 JumpIfSmi(obj, &fail); |
| 2263 } | 2263 } |
| 2264 ldr(scratch, FieldMemOperand(obj, HeapObject::kMapOffset)); | 2264 ldr(scratch, FieldMemOperand(obj, HeapObject::kMapOffset)); |
| 2265 mov(ip, Operand(map)); | 2265 mov(ip, Operand(map)); |
| 2266 cmp(scratch, ip); | 2266 cmp(scratch, ip); |
| 2267 Jump(success, RelocInfo::CODE_TARGET, eq); | 2267 Jump(success, RelocInfo::CODE_TARGET, eq); |
| 2268 bind(&fail); | 2268 bind(&fail); |
| 2269 } | 2269 } |
| 2270 | 2270 |
| 2271 | 2271 |
| 2272 void MacroAssembler::CmpWeakValue(Register value, Handle<WeakCell> cell, | |
| 2273 Register scratch) { | |
| 2274 mov(scratch, Operand(cell)); | |
| 2275 ldr(scratch, FieldMemOperand(scratch, WeakCell::kValueOffset)); | |
| 2276 cmp(value, scratch); | |
| 2277 } | |
| 2278 | |
| 2279 | |
| 2280 void MacroAssembler::LoadWeakValue(Register value, Handle<WeakCell> cell, | |
| 2281 Label* miss) { | |
| 2282 mov(value, Operand(cell)); | |
| 2283 ldr(value, FieldMemOperand(value, WeakCell::kValueOffset)); | |
| 2284 JumpIfSmi(value, miss); | |
| 2285 } | |
| 2286 | |
| 2287 | |
| 2288 void MacroAssembler::TryGetFunctionPrototype(Register function, | 2272 void MacroAssembler::TryGetFunctionPrototype(Register function, |
| 2289 Register result, | 2273 Register result, |
| 2290 Register scratch, | 2274 Register scratch, |
| 2291 Label* miss, | 2275 Label* miss, |
| 2292 bool miss_on_bound_function) { | 2276 bool miss_on_bound_function) { |
| 2293 Label non_instance; | 2277 Label non_instance; |
| 2294 if (miss_on_bound_function) { | 2278 if (miss_on_bound_function) { |
| 2295 // Check that the receiver isn't a smi. | 2279 // Check that the receiver isn't a smi. |
| 2296 JumpIfSmi(function, miss); | 2280 JumpIfSmi(function, miss); |
| 2297 | 2281 |
| (...skipping 1802 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4100 } | 4084 } |
| 4101 } | 4085 } |
| 4102 if (mag.shift > 0) mov(result, Operand(result, ASR, mag.shift)); | 4086 if (mag.shift > 0) mov(result, Operand(result, ASR, mag.shift)); |
| 4103 add(result, result, Operand(dividend, LSR, 31)); | 4087 add(result, result, Operand(dividend, LSR, 31)); |
| 4104 } | 4088 } |
| 4105 | 4089 |
| 4106 } // namespace internal | 4090 } // namespace internal |
| 4107 } // namespace v8 | 4091 } // namespace v8 |
| 4108 | 4092 |
| 4109 #endif // V8_TARGET_ARCH_ARM | 4093 #endif // V8_TARGET_ARCH_ARM |
| OLD | NEW |