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

Side by Side Diff: src/interpreter/interpreter-assembler.cc

Issue 2543873003: [stubs] Use CSA::IsHeapNumberMap() instead of manual map comparing. (Closed)
Patch Set: Created 4 years 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
« src/code-stub-assembler.cc ('K') | « src/interpreter/interpreter.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 the V8 project authors. All rights reserved. 1 // Copyright 2015 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/interpreter/interpreter-assembler.h" 5 #include "src/interpreter/interpreter-assembler.h"
6 6
7 #include <limits> 7 #include <limits>
8 #include <ostream> 8 #include <ostream>
9 9
10 #include "src/code-factory.h" 10 #include "src/code-factory.h"
(...skipping 1094 matching lines...) Expand 10 before | Expand all | Expand 10 after
1105 Int32Constant(BinaryOperationFeedback::kSignedSmall))); 1105 Int32Constant(BinaryOperationFeedback::kSignedSmall)));
1106 Goto(&done_loop); 1106 Goto(&done_loop);
1107 } 1107 }
1108 1108
1109 Bind(&if_valueisnotsmi); 1109 Bind(&if_valueisnotsmi);
1110 { 1110 {
1111 // Check if {value} is a HeapNumber. 1111 // Check if {value} is a HeapNumber.
1112 Label if_valueisheapnumber(this), 1112 Label if_valueisheapnumber(this),
1113 if_valueisnotheapnumber(this, Label::kDeferred); 1113 if_valueisnotheapnumber(this, Label::kDeferred);
1114 Node* value_map = LoadMap(value); 1114 Node* value_map = LoadMap(value);
1115 Branch(WordEqual(value_map, HeapNumberMapConstant()), 1115 Branch(IsHeapNumberMap(value_map), &if_valueisheapnumber,
1116 &if_valueisheapnumber, &if_valueisnotheapnumber); 1116 &if_valueisnotheapnumber);
1117 1117
1118 Bind(&if_valueisheapnumber); 1118 Bind(&if_valueisheapnumber);
1119 { 1119 {
1120 // Truncate the floating point value. 1120 // Truncate the floating point value.
1121 var_result.Bind(TruncateHeapNumberValueToWord32(value)); 1121 var_result.Bind(TruncateHeapNumberValueToWord32(value));
1122 var_type_feedback->Bind( 1122 var_type_feedback->Bind(
1123 Word32Or(var_type_feedback->value(), 1123 Word32Or(var_type_feedback->value(),
1124 Int32Constant(BinaryOperationFeedback::kNumber))); 1124 Int32Constant(BinaryOperationFeedback::kNumber)));
1125 Goto(&done_loop); 1125 Goto(&done_loop);
1126 } 1126 }
(...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after
1330 Goto(&loop); 1330 Goto(&loop);
1331 } 1331 }
1332 Bind(&done_loop); 1332 Bind(&done_loop);
1333 1333
1334 return array; 1334 return array;
1335 } 1335 }
1336 1336
1337 } // namespace interpreter 1337 } // namespace interpreter
1338 } // namespace internal 1338 } // namespace internal
1339 } // namespace v8 1339 } // namespace v8
OLDNEW
« src/code-stub-assembler.cc ('K') | « src/interpreter/interpreter.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698