| 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 #if V8_TARGET_ARCH_IA32 | 5 #if V8_TARGET_ARCH_IA32 |
| 6 | 6 |
| 7 #include "src/ast/compile-time-value.h" | 7 #include "src/ast/compile-time-value.h" |
| 8 #include "src/ast/scopes.h" | 8 #include "src/ast/scopes.h" |
| 9 #include "src/builtins/builtins-constructor.h" | 9 #include "src/builtins/builtins-constructor.h" |
| 10 #include "src/code-factory.h" | 10 #include "src/code-factory.h" |
| (...skipping 732 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 743 void FullCodeGenerator::VisitFunctionDeclaration( | 743 void FullCodeGenerator::VisitFunctionDeclaration( |
| 744 FunctionDeclaration* declaration) { | 744 FunctionDeclaration* declaration) { |
| 745 VariableProxy* proxy = declaration->proxy(); | 745 VariableProxy* proxy = declaration->proxy(); |
| 746 Variable* variable = proxy->var(); | 746 Variable* variable = proxy->var(); |
| 747 switch (variable->location()) { | 747 switch (variable->location()) { |
| 748 case VariableLocation::UNALLOCATED: { | 748 case VariableLocation::UNALLOCATED: { |
| 749 globals_->Add(variable->name(), zone()); | 749 globals_->Add(variable->name(), zone()); |
| 750 FeedbackVectorSlot slot = proxy->VariableFeedbackSlot(); | 750 FeedbackVectorSlot slot = proxy->VariableFeedbackSlot(); |
| 751 DCHECK(!slot.IsInvalid()); | 751 DCHECK(!slot.IsInvalid()); |
| 752 globals_->Add(handle(Smi::FromInt(slot.ToInt()), isolate()), zone()); | 752 globals_->Add(handle(Smi::FromInt(slot.ToInt()), isolate()), zone()); |
| 753 Handle<SharedFunctionInfo> function = Compiler::GetSharedFunctionInfo( | 753 Handle<SharedFunctionInfo> function = |
| 754 declaration->fun(), script(), info_, compilation_mode_); | 754 Compiler::GetSharedFunctionInfo(declaration->fun(), script(), info_); |
| 755 // Check for stack-overflow exception. | 755 // Check for stack-overflow exception. |
| 756 if (function.is_null()) return SetStackOverflow(); | 756 if (function.is_null()) return SetStackOverflow(); |
| 757 globals_->Add(function, zone()); | 757 globals_->Add(function, zone()); |
| 758 break; | 758 break; |
| 759 } | 759 } |
| 760 | 760 |
| 761 case VariableLocation::PARAMETER: | 761 case VariableLocation::PARAMETER: |
| 762 case VariableLocation::LOCAL: { | 762 case VariableLocation::LOCAL: { |
| 763 Comment cmnt(masm_, "[ FunctionDeclaration"); | 763 Comment cmnt(masm_, "[ FunctionDeclaration"); |
| 764 VisitForAccumulatorValue(declaration->fun()); | 764 VisitForAccumulatorValue(declaration->fun()); |
| (...skipping 2029 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2794 isolate->builtins()->OnStackReplacement()->entry(), | 2794 isolate->builtins()->OnStackReplacement()->entry(), |
| 2795 Assembler::target_address_at(call_target_address, unoptimized_code)); | 2795 Assembler::target_address_at(call_target_address, unoptimized_code)); |
| 2796 return ON_STACK_REPLACEMENT; | 2796 return ON_STACK_REPLACEMENT; |
| 2797 } | 2797 } |
| 2798 | 2798 |
| 2799 | 2799 |
| 2800 } // namespace internal | 2800 } // namespace internal |
| 2801 } // namespace v8 | 2801 } // namespace v8 |
| 2802 | 2802 |
| 2803 #endif // V8_TARGET_ARCH_IA32 | 2803 #endif // V8_TARGET_ARCH_IA32 |
| OLD | NEW |