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/compiler/code-generator-impl.h" | 6 #include "src/compiler/code-generator-impl.h" |
7 #include "src/compiler/gap-resolver.h" | 7 #include "src/compiler/gap-resolver.h" |
8 #include "src/compiler/node-matchers.h" | 8 #include "src/compiler/node-matchers.h" |
9 #include "src/compiler/osr.h" | 9 #include "src/compiler/osr.h" |
10 #include "src/mips/macro-assembler-mips.h" | 10 #include "src/mips/macro-assembler-mips.h" |
(...skipping 973 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
984 __ Cvt_s_ul(i.OutputDoubleRegister(), i.InputRegister(0)); | 984 __ Cvt_s_ul(i.OutputDoubleRegister(), i.InputRegister(0)); |
985 break; | 985 break; |
986 } | 986 } |
987 case kMips64TruncWD: { | 987 case kMips64TruncWD: { |
988 FPURegister scratch = kScratchDoubleReg; | 988 FPURegister scratch = kScratchDoubleReg; |
989 // Other arches use round to zero here, so we follow. | 989 // Other arches use round to zero here, so we follow. |
990 __ trunc_w_d(scratch, i.InputDoubleRegister(0)); | 990 __ trunc_w_d(scratch, i.InputDoubleRegister(0)); |
991 __ mfc1(i.OutputRegister(), scratch); | 991 __ mfc1(i.OutputRegister(), scratch); |
992 break; | 992 break; |
993 } | 993 } |
| 994 case kMips64TruncLS: { |
| 995 FPURegister scratch = kScratchDoubleReg; |
| 996 // Other arches use round to zero here, so we follow. |
| 997 __ trunc_l_s(scratch, i.InputDoubleRegister(0)); |
| 998 __ dmfc1(i.OutputRegister(), scratch); |
| 999 break; |
| 1000 } |
994 case kMips64TruncLD: { | 1001 case kMips64TruncLD: { |
995 FPURegister scratch = kScratchDoubleReg; | 1002 FPURegister scratch = kScratchDoubleReg; |
996 // Other arches use round to zero here, so we follow. | 1003 // Other arches use round to zero here, so we follow. |
997 __ trunc_l_d(scratch, i.InputDoubleRegister(0)); | 1004 __ trunc_l_d(scratch, i.InputDoubleRegister(0)); |
998 __ dmfc1(i.OutputRegister(), scratch); | 1005 __ dmfc1(i.OutputRegister(), scratch); |
999 break; | 1006 break; |
1000 } | 1007 } |
1001 case kMips64TruncUwD: { | 1008 case kMips64TruncUwD: { |
1002 FPURegister scratch = kScratchDoubleReg; | 1009 FPURegister scratch = kScratchDoubleReg; |
1003 // TODO(plind): Fix wrong param order of Trunc_uw_d() macro-asm function. | 1010 // TODO(plind): Fix wrong param order of Trunc_uw_d() macro-asm function. |
(...skipping 724 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1728 padding_size -= v8::internal::Assembler::kInstrSize; | 1735 padding_size -= v8::internal::Assembler::kInstrSize; |
1729 } | 1736 } |
1730 } | 1737 } |
1731 } | 1738 } |
1732 | 1739 |
1733 #undef __ | 1740 #undef __ |
1734 | 1741 |
1735 } // namespace compiler | 1742 } // namespace compiler |
1736 } // namespace internal | 1743 } // namespace internal |
1737 } // namespace v8 | 1744 } // namespace v8 |
OLD | NEW |