| 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 #if V8_TARGET_ARCH_IA32 | 7 #if V8_TARGET_ARCH_IA32 |
| 8 | 8 |
| 9 #include "src/code-factory.h" | 9 #include "src/code-factory.h" |
| 10 #include "src/code-stubs.h" | 10 #include "src/code-stubs.h" |
| (...skipping 1444 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1455 // | 1455 // |
| 1456 // The condition on the declaration scopes is a conservative check for | 1456 // The condition on the declaration scopes is a conservative check for |
| 1457 // nested functions that access a binding and are called before the | 1457 // nested functions that access a binding and are called before the |
| 1458 // binding is initialized: | 1458 // binding is initialized: |
| 1459 // function() { f(); let x = 1; function f() { x = 2; } } | 1459 // function() { f(); let x = 1; function f() { x = 2; } } |
| 1460 // | 1460 // |
| 1461 bool skip_init_check; | 1461 bool skip_init_check; |
| 1462 if (var->scope()->DeclarationScope() != scope()->DeclarationScope()) { | 1462 if (var->scope()->DeclarationScope() != scope()->DeclarationScope()) { |
| 1463 skip_init_check = false; | 1463 skip_init_check = false; |
| 1464 } else if (var->is_this()) { | 1464 } else if (var->is_this()) { |
| 1465 CHECK((info_->shared_info()->kind() & kSubclassConstructor) != 0); | 1465 CHECK(info_->function() != nullptr && |
| 1466 (info_->function()->kind() & kSubclassConstructor) != 0); |
| 1466 // TODO(dslomov): implement 'this' hole check elimination. | 1467 // TODO(dslomov): implement 'this' hole check elimination. |
| 1467 skip_init_check = false; | 1468 skip_init_check = false; |
| 1468 } else { | 1469 } else { |
| 1469 // Check that we always have valid source position. | 1470 // Check that we always have valid source position. |
| 1470 DCHECK(var->initializer_position() != RelocInfo::kNoPosition); | 1471 DCHECK(var->initializer_position() != RelocInfo::kNoPosition); |
| 1471 DCHECK(proxy->position() != RelocInfo::kNoPosition); | 1472 DCHECK(proxy->position() != RelocInfo::kNoPosition); |
| 1472 skip_init_check = var->mode() != CONST_LEGACY && | 1473 skip_init_check = var->mode() != CONST_LEGACY && |
| 1473 var->initializer_position() < proxy->position(); | 1474 var->initializer_position() < proxy->position(); |
| 1474 } | 1475 } |
| 1475 | 1476 |
| (...skipping 3814 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5290 DCHECK_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(), | 5291 DCHECK_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(), |
| 5291 Assembler::target_address_at(call_target_address, | 5292 Assembler::target_address_at(call_target_address, |
| 5292 unoptimized_code)); | 5293 unoptimized_code)); |
| 5293 return OSR_AFTER_STACK_CHECK; | 5294 return OSR_AFTER_STACK_CHECK; |
| 5294 } | 5295 } |
| 5295 | 5296 |
| 5296 | 5297 |
| 5297 } } // namespace v8::internal | 5298 } } // namespace v8::internal |
| 5298 | 5299 |
| 5299 #endif // V8_TARGET_ARCH_IA32 | 5300 #endif // V8_TARGET_ARCH_IA32 |
| OLD | NEW |