OLD | NEW |
1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 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-native-context-specialization.h" | 5 #include "src/compiler/js-native-context-specialization.h" |
6 | 6 |
7 #include "src/accessors.h" | 7 #include "src/accessors.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 1119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1130 if (access_info.field_map().ToHandle(&field_map)) { | 1130 if (access_info.field_map().ToHandle(&field_map)) { |
1131 if (field_map->is_stable()) { | 1131 if (field_map->is_stable()) { |
1132 dependencies()->AssumeMapStable(field_map); | 1132 dependencies()->AssumeMapStable(field_map); |
1133 field_access.map = field_map; | 1133 field_access.map = field_map; |
1134 } | 1134 } |
1135 } | 1135 } |
1136 } | 1136 } |
1137 value = effect = graph()->NewNode(simplified()->LoadField(field_access), | 1137 value = effect = graph()->NewNode(simplified()->LoadField(field_access), |
1138 storage, effect, control); | 1138 storage, effect, control); |
1139 } else { | 1139 } else { |
1140 DCHECK_EQ(AccessMode::kStore, access_mode); | 1140 DCHECK(access_mode == AccessMode::kStore || |
| 1141 access_mode == AccessMode::kStoreInLiteral); |
1141 switch (field_representation) { | 1142 switch (field_representation) { |
1142 case MachineRepresentation::kFloat64: { | 1143 case MachineRepresentation::kFloat64: { |
1143 value = effect = graph()->NewNode(simplified()->CheckNumber(), value, | 1144 value = effect = graph()->NewNode(simplified()->CheckNumber(), value, |
1144 effect, control); | 1145 effect, control); |
1145 if (!field_index.is_inobject() || field_index.is_hidden_field() || | 1146 if (!field_index.is_inobject() || field_index.is_hidden_field() || |
1146 !FLAG_unbox_double_fields) { | 1147 !FLAG_unbox_double_fields) { |
1147 if (access_info.HasTransitionMap()) { | 1148 if (access_info.HasTransitionMap()) { |
1148 // Allocate a MutableHeapNumber for the new property. | 1149 // Allocate a MutableHeapNumber for the new property. |
1149 effect = graph()->NewNode( | 1150 effect = graph()->NewNode( |
1150 common()->BeginRegion(RegionObservability::kNotObservable), | 1151 common()->BeginRegion(RegionObservability::kNotObservable), |
(...skipping 768 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1919 return jsgraph()->javascript(); | 1920 return jsgraph()->javascript(); |
1920 } | 1921 } |
1921 | 1922 |
1922 SimplifiedOperatorBuilder* JSNativeContextSpecialization::simplified() const { | 1923 SimplifiedOperatorBuilder* JSNativeContextSpecialization::simplified() const { |
1923 return jsgraph()->simplified(); | 1924 return jsgraph()->simplified(); |
1924 } | 1925 } |
1925 | 1926 |
1926 } // namespace compiler | 1927 } // namespace compiler |
1927 } // namespace internal | 1928 } // namespace internal |
1928 } // namespace v8 | 1929 } // namespace v8 |
OLD | NEW |