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_X64 | 7 #if V8_TARGET_ARCH_X64 |
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 883 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
894 | 894 |
895 | 895 |
896 void FullCodeGenerator::VisitFunctionDeclaration( | 896 void FullCodeGenerator::VisitFunctionDeclaration( |
897 FunctionDeclaration* declaration) { | 897 FunctionDeclaration* declaration) { |
898 VariableProxy* proxy = declaration->proxy(); | 898 VariableProxy* proxy = declaration->proxy(); |
899 Variable* variable = proxy->var(); | 899 Variable* variable = proxy->var(); |
900 switch (variable->location()) { | 900 switch (variable->location()) { |
901 case Variable::UNALLOCATED: { | 901 case Variable::UNALLOCATED: { |
902 globals_->Add(variable->name(), zone()); | 902 globals_->Add(variable->name(), zone()); |
903 Handle<SharedFunctionInfo> function = | 903 Handle<SharedFunctionInfo> function = |
904 Compiler::GetSharedFunctionInfo(declaration->fun(), script(), info_); | 904 Compiler::BuildFunctionInfo(declaration->fun(), script(), info_); |
905 // Check for stack-overflow exception. | 905 // Check for stack-overflow exception. |
906 if (function.is_null()) return SetStackOverflow(); | 906 if (function.is_null()) return SetStackOverflow(); |
907 globals_->Add(function, zone()); | 907 globals_->Add(function, zone()); |
908 break; | 908 break; |
909 } | 909 } |
910 | 910 |
911 case Variable::PARAMETER: | 911 case Variable::PARAMETER: |
912 case Variable::LOCAL: { | 912 case Variable::LOCAL: { |
913 Comment cmnt(masm_, "[ FunctionDeclaration"); | 913 Comment cmnt(masm_, "[ FunctionDeclaration"); |
914 VisitForAccumulatorValue(declaration->fun()); | 914 VisitForAccumulatorValue(declaration->fun()); |
(...skipping 4588 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5503 Assembler::target_address_at(call_target_address, | 5503 Assembler::target_address_at(call_target_address, |
5504 unoptimized_code)); | 5504 unoptimized_code)); |
5505 return OSR_AFTER_STACK_CHECK; | 5505 return OSR_AFTER_STACK_CHECK; |
5506 } | 5506 } |
5507 | 5507 |
5508 | 5508 |
5509 } // namespace internal | 5509 } // namespace internal |
5510 } // namespace v8 | 5510 } // namespace v8 |
5511 | 5511 |
5512 #endif // V8_TARGET_ARCH_X64 | 5512 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |