| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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/v8.h" | 5 #include "src/v8.h" |
| 6 | 6 |
| 7 #include "src/bailout-reason.h" | 7 #include "src/bailout-reason.h" |
| 8 #include "src/code-stubs.h" | 8 #include "src/code-stubs.h" |
| 9 #include "src/field-index.h" | 9 #include "src/field-index.h" |
| 10 #include "src/hydrogen.h" | 10 #include "src/hydrogen.h" |
| (...skipping 1336 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1347 IfBuilder map_check(this); | 1347 IfBuilder map_check(this); |
| 1348 map_check.IfNot<HCompareObjectEqAndBranch>(expected_map, map); | 1348 map_check.IfNot<HCompareObjectEqAndBranch>(expected_map, map); |
| 1349 map_check.ThenDeopt(Deoptimizer::kUnknownMap); | 1349 map_check.ThenDeopt(Deoptimizer::kUnknownMap); |
| 1350 map_check.End(); | 1350 map_check.End(); |
| 1351 } | 1351 } |
| 1352 | 1352 |
| 1353 HValue* weak_cell = Add<HConstant>(isolate()->factory()->NewWeakCell( | 1353 HValue* weak_cell = Add<HConstant>(isolate()->factory()->NewWeakCell( |
| 1354 StoreGlobalStub::property_cell_placeholder(isolate()))); | 1354 StoreGlobalStub::property_cell_placeholder(isolate()))); |
| 1355 HValue* cell = Add<HLoadNamedField>(weak_cell, nullptr, | 1355 HValue* cell = Add<HLoadNamedField>(weak_cell, nullptr, |
| 1356 HObjectAccess::ForWeakCellValue()); | 1356 HObjectAccess::ForWeakCellValue()); |
| 1357 Add<HCheckHeapObject>(cell); |
| 1357 HObjectAccess access(HObjectAccess::ForCellPayload(isolate())); | 1358 HObjectAccess access(HObjectAccess::ForCellPayload(isolate())); |
| 1358 HValue* cell_contents = Add<HLoadNamedField>(cell, nullptr, access); | 1359 HValue* cell_contents = Add<HLoadNamedField>(cell, nullptr, access); |
| 1359 | 1360 |
| 1360 if (stub->is_constant()) { | 1361 if (stub->is_constant()) { |
| 1361 IfBuilder builder(this); | 1362 IfBuilder builder(this); |
| 1362 builder.If<HCompareObjectEqAndBranch>(cell_contents, value); | 1363 builder.If<HCompareObjectEqAndBranch>(cell_contents, value); |
| 1363 builder.Then(); | 1364 builder.Then(); |
| 1364 builder.ElseDeopt( | 1365 builder.ElseDeopt( |
| 1365 Deoptimizer::kUnexpectedCellContentsInConstantGlobalStore); | 1366 Deoptimizer::kUnexpectedCellContentsInConstantGlobalStore); |
| 1366 builder.End(); | 1367 builder.End(); |
| (...skipping 881 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2248 // megamorphic case is handled as part of the default stub. | 2249 // megamorphic case is handled as part of the default stub. |
| 2249 DCHECK(!FLAG_vector_ics); | 2250 DCHECK(!FLAG_vector_ics); |
| 2250 | 2251 |
| 2251 // Probe the stub cache. | 2252 // Probe the stub cache. |
| 2252 Add<HTailCallThroughMegamorphicCache>(receiver, name); | 2253 Add<HTailCallThroughMegamorphicCache>(receiver, name); |
| 2253 | 2254 |
| 2254 // We never continue. | 2255 // We never continue. |
| 2255 return graph()->GetConstant0(); | 2256 return graph()->GetConstant0(); |
| 2256 } | 2257 } |
| 2257 } } // namespace v8::internal | 2258 } } // namespace v8::internal |
| OLD | NEW |