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

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

Issue 2662263002: [turbo] Rename CallConstruct* operators to Construct*. (Closed)
Patch Set: Created 3 years, 10 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/operator-properties.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 <iomanip> 7 #include <iomanip>
8 8
9 #include "src/base/flags.h" 9 #include "src/base/flags.h"
10 #include "src/bootstrapper.h" 10 #include "src/bootstrapper.h"
(...skipping 1304 matching lines...) Expand 10 before | Expand all | Expand 10 after
1315 Type* Typer::Visitor::TypeJSCreateBlockContext(Node* node) { 1315 Type* Typer::Visitor::TypeJSCreateBlockContext(Node* node) {
1316 return Type::OtherInternal(); 1316 return Type::OtherInternal();
1317 } 1317 }
1318 1318
1319 Type* Typer::Visitor::TypeJSCreateScriptContext(Node* node) { 1319 Type* Typer::Visitor::TypeJSCreateScriptContext(Node* node) {
1320 return Type::OtherInternal(); 1320 return Type::OtherInternal();
1321 } 1321 }
1322 1322
1323 // JS other operators. 1323 // JS other operators.
1324 1324
1325 Type* Typer::Visitor::TypeJSConstruct(Node* node) { return Type::Receiver(); }
1325 1326
1326 Type* Typer::Visitor::TypeJSCallConstruct(Node* node) { 1327 Type* Typer::Visitor::TypeJSConstructWithSpread(Node* node) {
1327 return Type::Receiver(); 1328 return Type::Receiver();
1328 } 1329 }
1329 1330
1330 Type* Typer::Visitor::TypeJSCallConstructWithSpread(Node* node) {
1331 return Type::Receiver();
1332 }
1333
1334 Type* Typer::Visitor::JSCallFunctionTyper(Type* fun, Typer* t) { 1331 Type* Typer::Visitor::JSCallFunctionTyper(Type* fun, Typer* t) {
1335 if (fun->IsHeapConstant() && fun->AsHeapConstant()->Value()->IsJSFunction()) { 1332 if (fun->IsHeapConstant() && fun->AsHeapConstant()->Value()->IsJSFunction()) {
1336 Handle<JSFunction> function = 1333 Handle<JSFunction> function =
1337 Handle<JSFunction>::cast(fun->AsHeapConstant()->Value()); 1334 Handle<JSFunction>::cast(fun->AsHeapConstant()->Value());
1338 if (function->shared()->HasBuiltinFunctionId()) { 1335 if (function->shared()->HasBuiltinFunctionId()) {
1339 switch (function->shared()->builtin_function_id()) { 1336 switch (function->shared()->builtin_function_id()) {
1340 case kMathRandom: 1337 case kMathRandom:
1341 return Type::PlainNumber(); 1338 return Type::PlainNumber();
1342 case kMathFloor: 1339 case kMathFloor:
1343 case kMathCeil: 1340 case kMathCeil:
(...skipping 602 matching lines...) Expand 10 before | Expand all | Expand 10 after
1946 Type* Typer::Visitor::TypeConstant(Handle<Object> value) { 1943 Type* Typer::Visitor::TypeConstant(Handle<Object> value) {
1947 if (Type::IsInteger(*value)) { 1944 if (Type::IsInteger(*value)) {
1948 return Type::Range(value->Number(), value->Number(), zone()); 1945 return Type::Range(value->Number(), value->Number(), zone());
1949 } 1946 }
1950 return Type::NewConstant(value, zone()); 1947 return Type::NewConstant(value, zone());
1951 } 1948 }
1952 1949
1953 } // namespace compiler 1950 } // namespace compiler
1954 } // namespace internal 1951 } // namespace internal
1955 } // namespace v8 1952 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/operator-properties.cc ('k') | src/compiler/verifier.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698