Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(575)

Side by Side Diff: runtime/vm/intermediate_language_dbc.cc

Issue 2432903002: Revert "Add DoubleTestOp instruction" (Closed)
Patch Set: Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « runtime/vm/intermediate_language_arm64.cc ('k') | runtime/vm/intermediate_language_ia32.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_DBC. 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_DBC.
6 #if defined(TARGET_ARCH_DBC) 6 #if defined(TARGET_ARCH_DBC)
7 7
8 #include "vm/intermediate_language.h" 8 #include "vm/intermediate_language.h"
9 9
10 #include "vm/cpu.h" 10 #include "vm/cpu.h"
(...skipping 1631 matching lines...) Expand 10 before | Expand all | Expand 10 after
1642 switch (op_kind()) { 1642 switch (op_kind()) {
1643 case Token::kADD: __ DAdd(result, left, right); break; 1643 case Token::kADD: __ DAdd(result, left, right); break;
1644 case Token::kSUB: __ DSub(result, left, right); break; 1644 case Token::kSUB: __ DSub(result, left, right); break;
1645 case Token::kMUL: __ DMul(result, left, right); break; 1645 case Token::kMUL: __ DMul(result, left, right); break;
1646 case Token::kDIV: __ DDiv(result, left, right); break; 1646 case Token::kDIV: __ DDiv(result, left, right); break;
1647 default: UNREACHABLE(); 1647 default: UNREACHABLE();
1648 } 1648 }
1649 } 1649 }
1650 1650
1651 1651
1652 EMIT_NATIVE_CODE(DoubleTestOp, 1, Location::RequiresRegister()) {
1653 ASSERT(compiler->is_optimizing());
1654 const Register value = locs()->in(0).reg();
1655 const Register result = locs()->out(0).reg();
1656 switch (op_kind()) {
1657 case MethodRecognizer::kDouble_getIsNaN:
1658 __ DoubleIsNaN(result, value);
1659 break;
1660 case MethodRecognizer::kDouble_getIsInfinite:
1661 __ DoubleIsInfinite(result, value);
1662 break;
1663 default:
1664 UNREACHABLE();
1665 }
1666 }
1667
1668
1669 EMIT_NATIVE_CODE(UnaryDoubleOp, 1, Location::RequiresRegister()) { 1652 EMIT_NATIVE_CODE(UnaryDoubleOp, 1, Location::RequiresRegister()) {
1670 const Register value = locs()->in(0).reg(); 1653 const Register value = locs()->in(0).reg();
1671 const Register result = locs()->out(0).reg(); 1654 const Register result = locs()->out(0).reg();
1672 __ DNeg(result, value); 1655 __ DNeg(result, value);
1673 } 1656 }
1674 1657
1675 1658
1676 EMIT_NATIVE_CODE(MathUnary, 1, Location::RequiresRegister()) { 1659 EMIT_NATIVE_CODE(MathUnary, 1, Location::RequiresRegister()) {
1677 const Register value = locs()->in(0).reg(); 1660 const Register value = locs()->in(0).reg();
1678 const Register result = locs()->out(0).reg(); 1661 const Register result = locs()->out(0).reg();
(...skipping 250 matching lines...) Expand 10 before | Expand all | Expand 10 after
1929 __ IfULe(length, index); 1912 __ IfULe(length, index);
1930 compiler->EmitDeopt(deopt_id(), 1913 compiler->EmitDeopt(deopt_id(),
1931 ICData::kDeoptCheckArrayBound, 1914 ICData::kDeoptCheckArrayBound,
1932 (generalized_ ? ICData::kGeneralized : 0) | 1915 (generalized_ ? ICData::kGeneralized : 0) |
1933 (licm_hoisted_ ? ICData::kHoisted : 0)); 1916 (licm_hoisted_ ? ICData::kHoisted : 0));
1934 } 1917 }
1935 1918
1936 } // namespace dart 1919 } // namespace dart
1937 1920
1938 #endif // defined TARGET_ARCH_DBC 1921 #endif // defined TARGET_ARCH_DBC
OLDNEW
« no previous file with comments | « runtime/vm/intermediate_language_arm64.cc ('k') | runtime/vm/intermediate_language_ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698