| 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/ast.h" | 7 #include "src/ast.h" |
| 8 #include "src/ast-numbering.h" | 8 #include "src/ast-numbering.h" |
| 9 #include "src/code-factory.h" | 9 #include "src/code-factory.h" |
| 10 #include "src/codegen.h" | 10 #include "src/codegen.h" |
| (...skipping 288 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 299 void BreakableStatementChecker::VisitSuperReference(SuperReference* expr) {} | 299 void BreakableStatementChecker::VisitSuperReference(SuperReference* expr) {} |
| 300 | 300 |
| 301 | 301 |
| 302 #define __ ACCESS_MASM(masm()) | 302 #define __ ACCESS_MASM(masm()) |
| 303 | 303 |
| 304 bool FullCodeGenerator::MakeCode(CompilationInfo* info) { | 304 bool FullCodeGenerator::MakeCode(CompilationInfo* info) { |
| 305 Isolate* isolate = info->isolate(); | 305 Isolate* isolate = info->isolate(); |
| 306 | 306 |
| 307 TimerEventScope<TimerEventCompileFullCode> timer(info->isolate()); | 307 TimerEventScope<TimerEventCompileFullCode> timer(info->isolate()); |
| 308 | 308 |
| 309 // Ensure that the feedback vector is large enough. |
| 310 info->EnsureFeedbackVector(); |
| 311 |
| 309 Handle<Script> script = info->script(); | 312 Handle<Script> script = info->script(); |
| 310 if (!script->IsUndefined() && !script->source()->IsUndefined()) { | 313 if (!script->IsUndefined() && !script->source()->IsUndefined()) { |
| 311 int len = String::cast(script->source())->length(); | 314 int len = String::cast(script->source())->length(); |
| 312 isolate->counters()->total_full_codegen_source_size()->Increment(len); | 315 isolate->counters()->total_full_codegen_source_size()->Increment(len); |
| 313 } | 316 } |
| 314 CodeGenerator::MakeCodePrologue(info, "full"); | 317 CodeGenerator::MakeCodePrologue(info, "full"); |
| 315 const int kInitialBufferSize = 4 * KB; | 318 const int kInitialBufferSize = 4 * KB; |
| 316 MacroAssembler masm(info->isolate(), NULL, kInitialBufferSize); | 319 MacroAssembler masm(info->isolate(), NULL, kInitialBufferSize); |
| 317 if (info->will_serialize()) masm.enable_serializer(); | 320 if (info->will_serialize()) masm.enable_serializer(); |
| 318 | 321 |
| (...skipping 1470 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1789 } | 1792 } |
| 1790 return true; | 1793 return true; |
| 1791 } | 1794 } |
| 1792 #endif // DEBUG | 1795 #endif // DEBUG |
| 1793 | 1796 |
| 1794 | 1797 |
| 1795 #undef __ | 1798 #undef __ |
| 1796 | 1799 |
| 1797 | 1800 |
| 1798 } } // namespace v8::internal | 1801 } } // namespace v8::internal |
| OLD | NEW |