| 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 "src/v8.h" | 5 #include "src/v8.h" |
| 6 | 6 |
| 7 #if V8_TARGET_ARCH_X87 | 7 #if V8_TARGET_ARCH_X87 |
| 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 260 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 271 | 271 |
| 272 void MacroAssembler::TruncateHeapNumberToI(Register result_reg, | 272 void MacroAssembler::TruncateHeapNumberToI(Register result_reg, |
| 273 Register input_reg) { | 273 Register input_reg) { |
| 274 Label done, slow_case; | 274 Label done, slow_case; |
| 275 | 275 |
| 276 SlowTruncateToI(result_reg, input_reg); | 276 SlowTruncateToI(result_reg, input_reg); |
| 277 bind(&done); | 277 bind(&done); |
| 278 } | 278 } |
| 279 | 279 |
| 280 | 280 |
| 281 void MacroAssembler::LoadUint32NoSSE2(Register src) { | 281 void MacroAssembler::LoadUint32NoSSE2(const Operand& src) { |
| 282 Label done; | 282 Label done; |
| 283 push(src); | 283 push(src); |
| 284 fild_s(Operand(esp, 0)); | 284 fild_s(Operand(esp, 0)); |
| 285 cmp(src, Immediate(0)); | 285 cmp(src, Immediate(0)); |
| 286 j(not_sign, &done, Label::kNear); | 286 j(not_sign, &done, Label::kNear); |
| 287 ExternalReference uint32_bias = | 287 ExternalReference uint32_bias = |
| 288 ExternalReference::address_of_uint32_bias(); | 288 ExternalReference::address_of_uint32_bias(); |
| 289 fld_d(Operand::StaticVariable(uint32_bias)); | 289 fld_d(Operand::StaticVariable(uint32_bias)); |
| 290 faddp(1); | 290 faddp(1); |
| 291 bind(&done); | 291 bind(&done); |
| (...skipping 3054 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3346 if (mag.shift > 0) sar(edx, mag.shift); | 3346 if (mag.shift > 0) sar(edx, mag.shift); |
| 3347 mov(eax, dividend); | 3347 mov(eax, dividend); |
| 3348 shr(eax, 31); | 3348 shr(eax, 31); |
| 3349 add(edx, eax); | 3349 add(edx, eax); |
| 3350 } | 3350 } |
| 3351 | 3351 |
| 3352 | 3352 |
| 3353 } } // namespace v8::internal | 3353 } } // namespace v8::internal |
| 3354 | 3354 |
| 3355 #endif // V8_TARGET_ARCH_X87 | 3355 #endif // V8_TARGET_ARCH_X87 |
| OLD | NEW |