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

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

Issue 697093002: Revert "[turbofan] Fix bug in Rangify." (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 1 month 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 | « no previous file | 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 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/bootstrapper.h" 5 #include "src/bootstrapper.h"
6 #include "src/compiler/graph-inl.h" 6 #include "src/compiler/graph-inl.h"
7 #include "src/compiler/js-operator.h" 7 #include "src/compiler/js-operator.h"
8 #include "src/compiler/node.h" 8 #include "src/compiler/node.h"
9 #include "src/compiler/node-properties-inl.h" 9 #include "src/compiler/node-properties-inl.h"
10 #include "src/compiler/node-properties.h" 10 #include "src/compiler/node-properties.h"
(...skipping 390 matching lines...) Expand 10 before | Expand all | Expand 10 after
401 401
402 402
403 Type* Typer::Visitor::FalsifyUndefined(Type* type, Typer* t) { 403 Type* Typer::Visitor::FalsifyUndefined(Type* type, Typer* t) {
404 if (type->Is(Type::Undefined())) return t->singleton_false; 404 if (type->Is(Type::Undefined())) return t->singleton_false;
405 return type; 405 return type;
406 } 406 }
407 407
408 408
409 Type* Typer::Visitor::Rangify(Type* type, Typer* t) { 409 Type* Typer::Visitor::Rangify(Type* type, Typer* t) {
410 if (type->IsRange()) return type; // Shortcut. 410 if (type->IsRange()) return type; // Shortcut.
411 if (!type->Is(t->integer) && !type->Is(Type::Integral32())) { 411 if (!type->Is(t->integer)) return type; // Give up.
412 return type; // Give up.
413 }
414 Factory* f = t->isolate()->factory(); 412 Factory* f = t->isolate()->factory();
415 return Type::Range(f->NewNumber(type->Min()), f->NewNumber(type->Max()), 413 return Type::Range(f->NewNumber(type->Min()), f->NewNumber(type->Max()),
416 t->zone()); 414 t->zone());
417 } 415 }
418 416
419 417
420 // Type conversion. 418 // Type conversion.
421 419
422 420
423 Type* Typer::Visitor::ToPrimitive(Type* type, Typer* t) { 421 Type* Typer::Visitor::ToPrimitive(Type* type, Typer* t) {
(...skipping 1460 matching lines...) Expand 10 before | Expand all | Expand 10 after
1884 return typer_->float64_array_fun_; 1882 return typer_->float64_array_fun_;
1885 } 1883 }
1886 } 1884 }
1887 } 1885 }
1888 return Type::Constant(value, zone()); 1886 return Type::Constant(value, zone());
1889 } 1887 }
1890 1888
1891 } 1889 }
1892 } 1890 }
1893 } // namespace v8::internal::compiler 1891 } // namespace v8::internal::compiler
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698