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

Side by Side Diff: src/compiler/js-create-lowering.cc

Issue 2082523002: [turbofan] Introduce CheckTaggedSigned and CheckTaggedPointer operators. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix compile 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 2016 the V8 project authors. All rights reserved. 1 // Copyright 2016 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/js-create-lowering.h" 5 #include "src/compiler/js-create-lowering.h"
6 6
7 #include "src/allocation-site-scopes.h" 7 #include "src/allocation-site-scopes.h"
8 #include "src/code-factory.h" 8 #include "src/code-factory.h"
9 #include "src/compilation-dependencies.h" 9 #include "src/compilation-dependencies.h"
10 #include "src/compiler/access-builder.h" 10 #include "src/compiler/access-builder.h"
(...skipping 19 matching lines...) Expand all
30 class AllocationBuilder final { 30 class AllocationBuilder final {
31 public: 31 public:
32 AllocationBuilder(JSGraph* jsgraph, Node* effect, Node* control) 32 AllocationBuilder(JSGraph* jsgraph, Node* effect, Node* control)
33 : jsgraph_(jsgraph), 33 : jsgraph_(jsgraph),
34 allocation_(nullptr), 34 allocation_(nullptr),
35 effect_(effect), 35 effect_(effect),
36 control_(control) {} 36 control_(control) {}
37 37
38 // Primitive allocation of static size. 38 // Primitive allocation of static size.
39 void Allocate(int size, PretenureFlag pretenure = NOT_TENURED) { 39 void Allocate(int size, PretenureFlag pretenure = NOT_TENURED) {
40 effect_ = graph()->NewNode(common()->BeginRegion(), effect_); 40 effect_ = graph()->NewNode(
41 common()->BeginRegion(RegionObservability::kNotObservable), effect_);
41 allocation_ = 42 allocation_ =
42 graph()->NewNode(simplified()->Allocate(pretenure), 43 graph()->NewNode(simplified()->Allocate(pretenure),
43 jsgraph()->Constant(size), effect_, control_); 44 jsgraph()->Constant(size), effect_, control_);
44 effect_ = allocation_; 45 effect_ = allocation_;
45 } 46 }
46 47
47 // Primitive store into a field. 48 // Primitive store into a field.
48 void Store(const FieldAccess& access, Node* value) { 49 void Store(const FieldAccess& access, Node* value) {
49 effect_ = graph()->NewNode(simplified()->StoreField(access), allocation_, 50 effect_ = graph()->NewNode(simplified()->StoreField(access), allocation_,
50 value, effect_, control_); 51 value, effect_, control_);
(...skipping 890 matching lines...) Expand 10 before | Expand all | Expand 10 after
941 isolate()); 942 isolate());
942 if (boilerplate_value->IsJSObject()) { 943 if (boilerplate_value->IsJSObject()) {
943 Handle<JSObject> boilerplate_object = 944 Handle<JSObject> boilerplate_object =
944 Handle<JSObject>::cast(boilerplate_value); 945 Handle<JSObject>::cast(boilerplate_value);
945 Handle<AllocationSite> current_site = site_context->EnterNewScope(); 946 Handle<AllocationSite> current_site = site_context->EnterNewScope();
946 value = effect = AllocateFastLiteral(effect, control, 947 value = effect = AllocateFastLiteral(effect, control,
947 boilerplate_object, site_context); 948 boilerplate_object, site_context);
948 site_context->ExitScope(current_site, boilerplate_object); 949 site_context->ExitScope(current_site, boilerplate_object);
949 } else if (property_details.representation().IsDouble()) { 950 } else if (property_details.representation().IsDouble()) {
950 // Allocate a mutable HeapNumber box and store the value into it. 951 // Allocate a mutable HeapNumber box and store the value into it.
951 effect = graph()->NewNode(common()->BeginRegion(), effect); 952 effect = graph()->NewNode(
953 common()->BeginRegion(RegionObservability::kNotObservable), effect);
952 value = effect = graph()->NewNode( 954 value = effect = graph()->NewNode(
953 simplified()->Allocate(NOT_TENURED), 955 simplified()->Allocate(NOT_TENURED),
954 jsgraph()->Constant(HeapNumber::kSize), effect, control); 956 jsgraph()->Constant(HeapNumber::kSize), effect, control);
955 effect = graph()->NewNode( 957 effect = graph()->NewNode(
956 simplified()->StoreField(AccessBuilder::ForMap()), value, 958 simplified()->StoreField(AccessBuilder::ForMap()), value,
957 jsgraph()->HeapConstant(factory()->mutable_heap_number_map()), 959 jsgraph()->HeapConstant(factory()->mutable_heap_number_map()),
958 effect, control); 960 effect, control);
959 effect = graph()->NewNode( 961 effect = graph()->NewNode(
960 simplified()->StoreField(AccessBuilder::ForHeapNumberValue()), 962 simplified()->StoreField(AccessBuilder::ForHeapNumberValue()),
961 value, jsgraph()->Constant( 963 value, jsgraph()->Constant(
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after
1125 return jsgraph()->simplified(); 1127 return jsgraph()->simplified();
1126 } 1128 }
1127 1129
1128 MachineOperatorBuilder* JSCreateLowering::machine() const { 1130 MachineOperatorBuilder* JSCreateLowering::machine() const {
1129 return jsgraph()->machine(); 1131 return jsgraph()->machine();
1130 } 1132 }
1131 1133
1132 } // namespace compiler 1134 } // namespace compiler
1133 } // namespace internal 1135 } // namespace internal
1134 } // namespace v8 1136 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/effect-control-linearizer.cc ('k') | src/compiler/js-native-context-specialization.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698