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

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

Issue 1420283009: [turbofan] Add support for storing to double fields. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 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
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 539 matching lines...) Expand 10 before | Expand all | Expand 10 after
550 return nullptr; 550 return nullptr;
551 } 551 }
552 552
553 553
554 Type* Typer::Visitor::TypeEffectSet(Node* node) { 554 Type* Typer::Visitor::TypeEffectSet(Node* node) {
555 UNREACHABLE(); 555 UNREACHABLE();
556 return nullptr; 556 return nullptr;
557 } 557 }
558 558
559 559
560 Type* Typer::Visitor::TypeGuard(Node* node) {
561 Type* input_type = Operand(node, 0);
562 Type* guard_type = OpParameter<Type*>(node);
563 return Type::Intersect(input_type, guard_type, zone());
564 }
565
566
560 Type* Typer::Visitor::TypeBeginRegion(Node* node) { 567 Type* Typer::Visitor::TypeBeginRegion(Node* node) {
561 UNREACHABLE(); 568 UNREACHABLE();
562 return nullptr; 569 return nullptr;
563 } 570 }
564 571
565 572
566 Type* Typer::Visitor::TypeFinishRegion(Node* node) { return Operand(node, 0); } 573 Type* Typer::Visitor::TypeFinishRegion(Node* node) { return Operand(node, 0); }
567 574
568 575
569 Type* Typer::Visitor::TypeFrameState(Node* node) { 576 Type* Typer::Visitor::TypeFrameState(Node* node) {
(...skipping 1209 matching lines...) Expand 10 before | Expand all | Expand 10 after
1779 return nullptr; 1786 return nullptr;
1780 } 1787 }
1781 1788
1782 1789
1783 Type* Typer::Visitor::TypeStoreElement(Node* node) { 1790 Type* Typer::Visitor::TypeStoreElement(Node* node) {
1784 UNREACHABLE(); 1791 UNREACHABLE();
1785 return nullptr; 1792 return nullptr;
1786 } 1793 }
1787 1794
1788 1795
1796 Type* Typer::Visitor::TypeObjectIsNumber(Node* node) {
1797 Type* arg = Operand(node, 0);
1798 if (arg->Is(Type::None())) return Type::None();
1799 if (arg->Is(Type::Number())) return typer_->singleton_true_;
1800 if (!arg->Maybe(Type::Number())) return typer_->singleton_false_;
1801 return Type::Boolean();
1802 }
1803
1804
1789 Type* Typer::Visitor::TypeObjectIsSmi(Node* node) { 1805 Type* Typer::Visitor::TypeObjectIsSmi(Node* node) {
1790 Type* arg = Operand(node, 0); 1806 Type* arg = Operand(node, 0);
1791 if (arg->Is(Type::None())) return Type::None(); 1807 if (arg->Is(Type::None())) return Type::None();
1792 if (arg->Is(Type::TaggedSigned())) return typer_->singleton_true_; 1808 if (arg->Is(Type::TaggedSigned())) return typer_->singleton_true_;
1793 if (arg->Is(Type::TaggedPointer())) return typer_->singleton_false_; 1809 if (arg->Is(Type::TaggedPointer())) return typer_->singleton_false_;
1794 return Type::Boolean(); 1810 return Type::Boolean();
1795 } 1811 }
1796 1812
1797 1813
1798 // Machine operators. 1814 // Machine operators.
(...skipping 384 matching lines...) Expand 10 before | Expand all | Expand 10 after
2183 } 2199 }
2184 if (Type::IsInteger(*value)) { 2200 if (Type::IsInteger(*value)) {
2185 return Type::Range(value->Number(), value->Number(), zone()); 2201 return Type::Range(value->Number(), value->Number(), zone());
2186 } 2202 }
2187 return Type::Constant(value, zone()); 2203 return Type::Constant(value, zone());
2188 } 2204 }
2189 2205
2190 } // namespace compiler 2206 } // namespace compiler
2191 } // namespace internal 2207 } // namespace internal
2192 } // namespace v8 2208 } // namespace v8
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698