| 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 #include "src/compiler/code-generator.h" | 5 #include "src/compiler/code-generator.h" |
| 6 | 6 |
| 7 #include "src/compiler/code-generator-impl.h" | 7 #include "src/compiler/code-generator-impl.h" |
| 8 #include "src/compiler/gap-resolver.h" | 8 #include "src/compiler/gap-resolver.h" |
| 9 #include "src/compiler/node-matchers.h" | 9 #include "src/compiler/node-matchers.h" |
| 10 #include "src/compiler/node-properties-inl.h" | 10 #include "src/compiler/node-properties-inl.h" |
| (...skipping 267 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 278 __ fnstsw_ax(); | 278 __ fnstsw_ax(); |
| 279 __ sahf(); | 279 __ sahf(); |
| 280 __ j(parity_even, &mod_loop); | 280 __ j(parity_even, &mod_loop); |
| 281 // Move output to stack and clean up. | 281 // Move output to stack and clean up. |
| 282 __ fstp(1); | 282 __ fstp(1); |
| 283 __ fstp_d(Operand(esp, 0)); | 283 __ fstp_d(Operand(esp, 0)); |
| 284 __ movsd(i.OutputDoubleRegister(), Operand(esp, 0)); | 284 __ movsd(i.OutputDoubleRegister(), Operand(esp, 0)); |
| 285 __ add(esp, Immediate(kDoubleSize)); | 285 __ add(esp, Immediate(kDoubleSize)); |
| 286 break; | 286 break; |
| 287 } | 287 } |
| 288 case kSSEFloat64Sqrt: |
| 289 __ sqrtsd(i.OutputDoubleRegister(), i.InputOperand(0)); |
| 290 break; |
| 288 case kSSEFloat64ToInt32: | 291 case kSSEFloat64ToInt32: |
| 289 __ cvttsd2si(i.OutputRegister(), i.InputOperand(0)); | 292 __ cvttsd2si(i.OutputRegister(), i.InputOperand(0)); |
| 290 break; | 293 break; |
| 291 case kSSEFloat64ToUint32: { | 294 case kSSEFloat64ToUint32: { |
| 292 XMMRegister scratch = xmm0; | 295 XMMRegister scratch = xmm0; |
| 293 __ Move(scratch, -2147483648.0); | 296 __ Move(scratch, -2147483648.0); |
| 294 __ addsd(scratch, i.InputOperand(0)); | 297 __ addsd(scratch, i.InputOperand(0)); |
| 295 __ cvttsd2si(i.OutputRegister(), scratch); | 298 __ cvttsd2si(i.OutputRegister(), scratch); |
| 296 __ add(i.OutputRegister(), Immediate(0x80000000)); | 299 __ add(i.OutputRegister(), Immediate(0x80000000)); |
| 297 break; | 300 break; |
| (...skipping 649 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 947 } | 950 } |
| 948 } | 951 } |
| 949 MarkLazyDeoptSite(); | 952 MarkLazyDeoptSite(); |
| 950 } | 953 } |
| 951 | 954 |
| 952 #undef __ | 955 #undef __ |
| 953 | 956 |
| 954 } // namespace compiler | 957 } // namespace compiler |
| 955 } // namespace internal | 958 } // namespace internal |
| 956 } // namespace v8 | 959 } // namespace v8 |
| OLD | NEW |