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

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

Issue 2060743002: [builtins] Introduce proper Float64Log1p operator. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@Math_Log
Patch Set: REBASE Created 4 years, 6 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
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/typer.h" 5 #include "src/compiler/typer.h"
6 6
7 #include "src/base/flags.h" 7 #include "src/base/flags.h"
8 #include "src/bootstrapper.h" 8 #include "src/bootstrapper.h"
9 #include "src/compilation-dependencies.h" 9 #include "src/compilation-dependencies.h"
10 #include "src/compiler/common-operator.h" 10 #include "src/compiler/common-operator.h"
(...skipping 1769 matching lines...) Expand 10 before | Expand all | Expand 10 after
1780 Type* Typer::Visitor::TypeNumberCeil(Node* node) { 1780 Type* Typer::Visitor::TypeNumberCeil(Node* node) {
1781 return TypeUnaryOp(node, NumberCeil); 1781 return TypeUnaryOp(node, NumberCeil);
1782 } 1782 }
1783 1783
1784 Type* Typer::Visitor::TypeNumberFloor(Node* node) { 1784 Type* Typer::Visitor::TypeNumberFloor(Node* node) {
1785 return TypeUnaryOp(node, NumberFloor); 1785 return TypeUnaryOp(node, NumberFloor);
1786 } 1786 }
1787 1787
1788 Type* Typer::Visitor::TypeNumberLog(Node* node) { return Type::Number(); } 1788 Type* Typer::Visitor::TypeNumberLog(Node* node) { return Type::Number(); }
1789 1789
1790 Type* Typer::Visitor::TypeNumberLog1p(Node* node) { return Type::Number(); }
1791
1790 Type* Typer::Visitor::TypeNumberRound(Node* node) { 1792 Type* Typer::Visitor::TypeNumberRound(Node* node) {
1791 return TypeUnaryOp(node, NumberRound); 1793 return TypeUnaryOp(node, NumberRound);
1792 } 1794 }
1793 1795
1794 Type* Typer::Visitor::TypeNumberTrunc(Node* node) { 1796 Type* Typer::Visitor::TypeNumberTrunc(Node* node) {
1795 return TypeUnaryOp(node, NumberTrunc); 1797 return TypeUnaryOp(node, NumberTrunc);
1796 } 1798 }
1797 1799
1798 Type* Typer::Visitor::TypeNumberToInt32(Node* node) { 1800 Type* Typer::Visitor::TypeNumberToInt32(Node* node) {
1799 return TypeUnaryOp(node, NumberToInt32); 1801 return TypeUnaryOp(node, NumberToInt32);
(...skipping 697 matching lines...) Expand 10 before | Expand all | Expand 10 after
2497 Type* Typer::Visitor::TypeFloat64Min(Node* node) { return Type::Number(); } 2499 Type* Typer::Visitor::TypeFloat64Min(Node* node) { return Type::Number(); }
2498 2500
2499 2501
2500 Type* Typer::Visitor::TypeFloat64Abs(Node* node) { 2502 Type* Typer::Visitor::TypeFloat64Abs(Node* node) {
2501 // TODO(turbofan): We should be able to infer a better type here. 2503 // TODO(turbofan): We should be able to infer a better type here.
2502 return Type::Number(); 2504 return Type::Number();
2503 } 2505 }
2504 2506
2505 Type* Typer::Visitor::TypeFloat64Log(Node* node) { return Type::Number(); } 2507 Type* Typer::Visitor::TypeFloat64Log(Node* node) { return Type::Number(); }
2506 2508
2509 Type* Typer::Visitor::TypeFloat64Log1p(Node* node) { return Type::Number(); }
2510
2507 Type* Typer::Visitor::TypeFloat64Sqrt(Node* node) { return Type::Number(); } 2511 Type* Typer::Visitor::TypeFloat64Sqrt(Node* node) { return Type::Number(); }
2508 2512
2509 2513
2510 Type* Typer::Visitor::TypeFloat64Equal(Node* node) { return Type::Boolean(); } 2514 Type* Typer::Visitor::TypeFloat64Equal(Node* node) { return Type::Boolean(); }
2511 2515
2512 2516
2513 Type* Typer::Visitor::TypeFloat64LessThan(Node* node) { 2517 Type* Typer::Visitor::TypeFloat64LessThan(Node* node) {
2514 return Type::Boolean(); 2518 return Type::Boolean();
2515 } 2519 }
2516 2520
(...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after
2665 } 2669 }
2666 if (Type::IsInteger(*value)) { 2670 if (Type::IsInteger(*value)) {
2667 return Type::Range(value->Number(), value->Number(), zone()); 2671 return Type::Range(value->Number(), value->Number(), zone());
2668 } 2672 }
2669 return Type::Constant(value, zone()); 2673 return Type::Constant(value, zone());
2670 } 2674 }
2671 2675
2672 } // namespace compiler 2676 } // namespace compiler
2673 } // namespace internal 2677 } // namespace internal
2674 } // namespace v8 2678 } // namespace v8
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698