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

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

Issue 1693563004: Convert between tagged and untagged kSimd128 values. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebase Created 4 years, 9 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
« no previous file with comments | « src/compiler/simplified-operator.cc ('k') | src/compiler/verifier.cc » ('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/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 1798 matching lines...) Expand 10 before | Expand all | Expand 10 after
1809 return ChangeRepresentation(arg, Type::Tagged(), zone()); 1809 return ChangeRepresentation(arg, Type::Tagged(), zone());
1810 } 1810 }
1811 1811
1812 1812
1813 Type* Typer::Visitor::TypeChangeFloat64ToTagged(Node* node) { 1813 Type* Typer::Visitor::TypeChangeFloat64ToTagged(Node* node) {
1814 Type* arg = Operand(node, 0); 1814 Type* arg = Operand(node, 0);
1815 // TODO(neis): CHECK(arg.upper->Is(Type::Number())); 1815 // TODO(neis): CHECK(arg.upper->Is(Type::Number()));
1816 return ChangeRepresentation(arg, Type::Tagged(), zone()); 1816 return ChangeRepresentation(arg, Type::Tagged(), zone());
1817 } 1817 }
1818 1818
1819 #define SIMD128_CHANGE(TYPE, SType, type, lane_count, lane_type) \
1820 Type* Typer::Visitor::TypeChangeTaggedTo##SType(Node* node) { \
1821 Type* arg = Operand(node, 0); \
1822 return ChangeRepresentation(arg, Type::UntaggedSimd128(), zone()); \
1823 } \
1824 \
1825 Type* Typer::Visitor::TypeChange##SType##ToTagged(Node* node) { \
1826 Type* arg = Operand(node, 0); \
1827 return ChangeRepresentation(arg, Type::Tagged(), zone()); \
1828 }
1829 SIMD128_TYPES(SIMD128_CHANGE)
1830 #undef SIMD128_CHANGE
1819 1831
1820 Type* Typer::Visitor::TypeChangeBoolToBit(Node* node) { 1832 Type* Typer::Visitor::TypeChangeBoolToBit(Node* node) {
1821 Type* arg = Operand(node, 0); 1833 Type* arg = Operand(node, 0);
1822 // TODO(neis): DCHECK(arg.upper->Is(Type::Boolean())); 1834 // TODO(neis): DCHECK(arg.upper->Is(Type::Boolean()));
1823 return ChangeRepresentation(arg, Type::UntaggedBit(), zone()); 1835 return ChangeRepresentation(arg, Type::UntaggedBit(), zone());
1824 } 1836 }
1825 1837
1826 1838
1827 Type* Typer::Visitor::TypeChangeBitToBool(Node* node) { 1839 Type* Typer::Visitor::TypeChangeBitToBool(Node* node) {
1828 Type* arg = Operand(node, 0); 1840 Type* arg = Operand(node, 0);
(...skipping 640 matching lines...) Expand 10 before | Expand all | Expand 10 after
2469 } 2481 }
2470 if (Type::IsInteger(*value)) { 2482 if (Type::IsInteger(*value)) {
2471 return Type::Range(value->Number(), value->Number(), zone()); 2483 return Type::Range(value->Number(), value->Number(), zone());
2472 } 2484 }
2473 return Type::Constant(value, zone()); 2485 return Type::Constant(value, zone());
2474 } 2486 }
2475 2487
2476 } // namespace compiler 2488 } // namespace compiler
2477 } // namespace internal 2489 } // namespace internal
2478 } // namespace v8 2490 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/simplified-operator.cc ('k') | src/compiler/verifier.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698