OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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 #include "src/compilation-info.h" | 6 #include "src/compilation-info.h" |
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/osr.h" | 10 #include "src/compiler/osr.h" |
(...skipping 1435 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1446 break; | 1446 break; |
1447 } | 1447 } |
1448 case kMips64Float32RoundTiesEven: { | 1448 case kMips64Float32RoundTiesEven: { |
1449 ASSEMBLE_ROUND_FLOAT_TO_FLOAT(round); | 1449 ASSEMBLE_ROUND_FLOAT_TO_FLOAT(round); |
1450 break; | 1450 break; |
1451 } | 1451 } |
1452 case kMips64Float32Max: { | 1452 case kMips64Float32Max: { |
1453 FPURegister dst = i.OutputSingleRegister(); | 1453 FPURegister dst = i.OutputSingleRegister(); |
1454 FPURegister src1 = i.InputSingleRegister(0); | 1454 FPURegister src1 = i.InputSingleRegister(0); |
1455 FPURegister src2 = i.InputSingleRegister(1); | 1455 FPURegister src2 = i.InputSingleRegister(1); |
1456 if (src1.is(src2)) { | 1456 auto ool = new (zone()) OutOfLineFloat32Max(this, dst, src1, src2); |
1457 __ Move_s(dst, src1); | 1457 __ Float32Max(dst, src1, src2, ool->entry()); |
1458 } else { | 1458 __ bind(ool->exit()); |
1459 auto ool = new (zone()) OutOfLineFloat32Max(this, dst, src1, src2); | |
1460 __ Float32Max(dst, src1, src2, ool->entry()); | |
1461 __ bind(ool->exit()); | |
1462 } | |
1463 break; | 1459 break; |
1464 } | 1460 } |
1465 case kMips64Float64Max: { | 1461 case kMips64Float64Max: { |
1466 FPURegister dst = i.OutputDoubleRegister(); | 1462 FPURegister dst = i.OutputDoubleRegister(); |
1467 FPURegister src1 = i.InputDoubleRegister(0); | 1463 FPURegister src1 = i.InputDoubleRegister(0); |
1468 FPURegister src2 = i.InputDoubleRegister(1); | 1464 FPURegister src2 = i.InputDoubleRegister(1); |
1469 if (src1.is(src2)) { | 1465 auto ool = new (zone()) OutOfLineFloat64Max(this, dst, src1, src2); |
1470 __ Move_d(dst, src1); | 1466 __ Float64Max(dst, src1, src2, ool->entry()); |
1471 } else { | 1467 __ bind(ool->exit()); |
1472 auto ool = new (zone()) OutOfLineFloat64Max(this, dst, src1, src2); | |
1473 __ Float64Max(dst, src1, src2, ool->entry()); | |
1474 __ bind(ool->exit()); | |
1475 } | |
1476 break; | 1468 break; |
1477 } | 1469 } |
1478 case kMips64Float32Min: { | 1470 case kMips64Float32Min: { |
1479 FPURegister dst = i.OutputSingleRegister(); | 1471 FPURegister dst = i.OutputSingleRegister(); |
1480 FPURegister src1 = i.InputSingleRegister(0); | 1472 FPURegister src1 = i.InputSingleRegister(0); |
1481 FPURegister src2 = i.InputSingleRegister(1); | 1473 FPURegister src2 = i.InputSingleRegister(1); |
1482 if (src1.is(src2)) { | 1474 auto ool = new (zone()) OutOfLineFloat32Min(this, dst, src1, src2); |
1483 __ Move_s(dst, src1); | 1475 __ Float32Min(dst, src1, src2, ool->entry()); |
1484 } else { | 1476 __ bind(ool->exit()); |
1485 auto ool = new (zone()) OutOfLineFloat32Min(this, dst, src1, src2); | |
1486 __ Float32Min(dst, src1, src2, ool->entry()); | |
1487 __ bind(ool->exit()); | |
1488 } | |
1489 break; | 1477 break; |
1490 } | 1478 } |
1491 case kMips64Float64Min: { | 1479 case kMips64Float64Min: { |
1492 FPURegister dst = i.OutputDoubleRegister(); | 1480 FPURegister dst = i.OutputDoubleRegister(); |
1493 FPURegister src1 = i.InputDoubleRegister(0); | 1481 FPURegister src1 = i.InputDoubleRegister(0); |
1494 FPURegister src2 = i.InputDoubleRegister(1); | 1482 FPURegister src2 = i.InputDoubleRegister(1); |
1495 if (src1.is(src2)) { | 1483 auto ool = new (zone()) OutOfLineFloat64Min(this, dst, src1, src2); |
1496 __ Move_d(dst, src1); | 1484 __ Float64Min(dst, src1, src2, ool->entry()); |
1497 } else { | 1485 __ bind(ool->exit()); |
1498 auto ool = new (zone()) OutOfLineFloat64Min(this, dst, src1, src2); | |
1499 __ Float64Min(dst, src1, src2, ool->entry()); | |
1500 __ bind(ool->exit()); | |
1501 } | |
1502 break; | 1486 break; |
1503 } | 1487 } |
1504 case kMips64Float64SilenceNaN: | 1488 case kMips64Float64SilenceNaN: |
1505 __ FPUCanonicalizeNaN(i.OutputDoubleRegister(), i.InputDoubleRegister(0)); | 1489 __ FPUCanonicalizeNaN(i.OutputDoubleRegister(), i.InputDoubleRegister(0)); |
1506 break; | 1490 break; |
1507 case kMips64CvtSD: | 1491 case kMips64CvtSD: |
1508 __ cvt_s_d(i.OutputSingleRegister(), i.InputDoubleRegister(0)); | 1492 __ cvt_s_d(i.OutputSingleRegister(), i.InputDoubleRegister(0)); |
1509 break; | 1493 break; |
1510 case kMips64CvtDS: | 1494 case kMips64CvtDS: |
1511 __ cvt_d_s(i.OutputDoubleRegister(), i.InputSingleRegister(0)); | 1495 __ cvt_d_s(i.OutputDoubleRegister(), i.InputSingleRegister(0)); |
(...skipping 1098 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2610 padding_size -= v8::internal::Assembler::kInstrSize; | 2594 padding_size -= v8::internal::Assembler::kInstrSize; |
2611 } | 2595 } |
2612 } | 2596 } |
2613 } | 2597 } |
2614 | 2598 |
2615 #undef __ | 2599 #undef __ |
2616 | 2600 |
2617 } // namespace compiler | 2601 } // namespace compiler |
2618 } // namespace internal | 2602 } // namespace internal |
2619 } // namespace v8 | 2603 } // namespace v8 |
OLD | NEW |