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/simplified-lowering.h" | 5 #include "src/compiler/simplified-lowering.h" |
6 | 6 |
7 #include <limits> | 7 #include <limits> |
8 | 8 |
9 #include "src/base/bits.h" | 9 #include "src/base/bits.h" |
10 #include "src/code-factory.h" | 10 #include "src/code-factory.h" |
(...skipping 1181 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1192 } else { | 1192 } else { |
1193 // If undefined is truncated to a number, but the use can | 1193 // If undefined is truncated to a number, but the use can |
1194 // observe NaN, we need to output at least the float32 | 1194 // observe NaN, we need to output at least the float32 |
1195 // representation. | 1195 // representation. |
1196 if (access.machine_type().representation() == | 1196 if (access.machine_type().representation() == |
1197 MachineRepresentation::kFloat32) { | 1197 MachineRepresentation::kFloat32) { |
1198 output_info = | 1198 output_info = |
1199 NodeOutputInfo(access.machine_type().representation(), | 1199 NodeOutputInfo(access.machine_type().representation(), |
1200 NodeProperties::GetType(node)); | 1200 NodeProperties::GetType(node)); |
1201 } else { | 1201 } else { |
| 1202 if (access.machine_type().representation() != |
| 1203 MachineRepresentation::kFloat64) { |
| 1204 // TODO(bmeurer): See comment on abort_compilation_. |
| 1205 if (lower()) lowering->abort_compilation_ = true; |
| 1206 } |
1202 output_info = NodeOutputInfo::Float64(); | 1207 output_info = NodeOutputInfo::Float64(); |
1203 } | 1208 } |
1204 } | 1209 } |
1205 } else { | 1210 } else { |
| 1211 // TODO(bmeurer): See comment on abort_compilation_. |
| 1212 if (lower()) lowering->abort_compilation_ = true; |
| 1213 |
1206 // If undefined is not truncated away, we need to have the tagged | 1214 // If undefined is not truncated away, we need to have the tagged |
1207 // representation. | 1215 // representation. |
1208 output_info = NodeOutputInfo::AnyTagged(); | 1216 output_info = NodeOutputInfo::AnyTagged(); |
1209 } | 1217 } |
1210 SetOutput(node, output_info); | 1218 SetOutput(node, output_info); |
1211 if (lower()) | 1219 if (lower()) |
1212 lowering->DoLoadBuffer(node, output_info.representation(), changer_); | 1220 lowering->DoLoadBuffer(node, output_info.representation(), changer_); |
1213 break; | 1221 break; |
1214 } | 1222 } |
1215 case IrOpcode::kStoreBuffer: { | 1223 case IrOpcode::kStoreBuffer: { |
(...skipping 698 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1914 ReplaceEffectUses(node, comparison); | 1922 ReplaceEffectUses(node, comparison); |
1915 node->ReplaceInput(0, comparison); | 1923 node->ReplaceInput(0, comparison); |
1916 node->ReplaceInput(1, jsgraph()->SmiConstant(EQUAL)); | 1924 node->ReplaceInput(1, jsgraph()->SmiConstant(EQUAL)); |
1917 node->TrimInputCount(2); | 1925 node->TrimInputCount(2); |
1918 NodeProperties::ChangeOp(node, machine()->IntLessThanOrEqual()); | 1926 NodeProperties::ChangeOp(node, machine()->IntLessThanOrEqual()); |
1919 } | 1927 } |
1920 | 1928 |
1921 } // namespace compiler | 1929 } // namespace compiler |
1922 } // namespace internal | 1930 } // namespace internal |
1923 } // namespace v8 | 1931 } // namespace v8 |
OLD | NEW |