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

Side by Side Diff: src/compiler/typer.cc

Issue 594493002: [turbofan] Add operators for float32 support. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Addressed comments Created 6 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 | Annotate | Revision Log
« no previous file with comments | « src/compiler/opcodes.h ('k') | src/conversions.h » ('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 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/graph-inl.h" 5 #include "src/compiler/graph-inl.h"
6 #include "src/compiler/js-operator.h" 6 #include "src/compiler/js-operator.h"
7 #include "src/compiler/node.h" 7 #include "src/compiler/node.h"
8 #include "src/compiler/node-properties-inl.h" 8 #include "src/compiler/node-properties-inl.h"
9 #include "src/compiler/node-properties.h" 9 #include "src/compiler/node-properties.h"
10 #include "src/compiler/simplified-operator.h" 10 #include "src/compiler/simplified-operator.h"
(...skipping 237 matching lines...) Expand 10 before | Expand all | Expand 10 after
248 } 248 }
249 249
250 250
251 Bounds Typer::Visitor::TypeInt64Constant(Node* node) { 251 Bounds Typer::Visitor::TypeInt64Constant(Node* node) {
252 // TODO(titzer): only call Type::Of() if the type is not already known. 252 // TODO(titzer): only call Type::Of() if the type is not already known.
253 return Bounds( 253 return Bounds(
254 Type::Of(static_cast<double>(OpParameter<int64_t>(node)), zone())); 254 Type::Of(static_cast<double>(OpParameter<int64_t>(node)), zone()));
255 } 255 }
256 256
257 257
258 Bounds Typer::Visitor::TypeFloat32Constant(Node* node) {
259 // TODO(titzer): only call Type::Of() if the type is not already known.
260 return Bounds(Type::Of(OpParameter<float>(node), zone()));
261 }
262
263
258 Bounds Typer::Visitor::TypeFloat64Constant(Node* node) { 264 Bounds Typer::Visitor::TypeFloat64Constant(Node* node) {
259 // TODO(titzer): only call Type::Of() if the type is not already known. 265 // TODO(titzer): only call Type::Of() if the type is not already known.
260 return Bounds(Type::Of(OpParameter<double>(node), zone())); 266 return Bounds(Type::Of(OpParameter<double>(node), zone()));
261 } 267 }
262 268
263 269
264 Bounds Typer::Visitor::TypeNumberConstant(Node* node) { 270 Bounds Typer::Visitor::TypeNumberConstant(Node* node) {
265 // TODO(titzer): only call Type::Of() if the type is not already known. 271 // TODO(titzer): only call Type::Of() if the type is not already known.
266 return Bounds(Type::Of(OpParameter<double>(node), zone())); 272 return Bounds(Type::Of(OpParameter<double>(node), zone()));
267 } 273 }
(...skipping 621 matching lines...) Expand 10 before | Expand all | Expand 10 after
889 } 895 }
890 896
891 897
892 void Typer::DecorateGraph(Graph* graph) { 898 void Typer::DecorateGraph(Graph* graph) {
893 graph->AddDecorator(new (zone()) TyperDecorator(this)); 899 graph->AddDecorator(new (zone()) TyperDecorator(this));
894 } 900 }
895 901
896 } 902 }
897 } 903 }
898 } // namespace v8::internal::compiler 904 } // namespace v8::internal::compiler
OLDNEW
« no previous file with comments | « src/compiler/opcodes.h ('k') | src/conversions.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698