Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(903)

Side by Side Diff: src/compiler.cc

Issue 7111034: Kill some dead code: classic frame element and const lists. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Killed CompilationZoneScope Created 9 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/compiler.h ('k') | src/isolate.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 320 matching lines...) Expand 10 before | Expand all | Expand 10 after
331 SerializedScopeInfo::Create(info->scope()); 331 SerializedScopeInfo::Create(info->scope());
332 info->shared_info()->set_scope_info(*scope_info); 332 info->shared_info()->set_scope_info(*scope_info);
333 } 333 }
334 return succeeded; 334 return succeeded;
335 } 335 }
336 #endif 336 #endif
337 337
338 338
339 static Handle<SharedFunctionInfo> MakeFunctionInfo(CompilationInfo* info) { 339 static Handle<SharedFunctionInfo> MakeFunctionInfo(CompilationInfo* info) {
340 Isolate* isolate = info->isolate(); 340 Isolate* isolate = info->isolate();
341 CompilationZoneScope zone_scope(isolate, DELETE_ON_EXIT); 341 ZoneScope zone_scope(isolate, DELETE_ON_EXIT);
342 PostponeInterruptsScope postpone(isolate); 342 PostponeInterruptsScope postpone(isolate);
343 343
344 ASSERT(!isolate->global_context().is_null()); 344 ASSERT(!isolate->global_context().is_null());
345 Handle<Script> script = info->script(); 345 Handle<Script> script = info->script();
346 script->set_context_data((*isolate->global_context())->data()); 346 script->set_context_data((*isolate->global_context())->data());
347 347
348 #ifdef ENABLE_DEBUGGER_SUPPORT 348 #ifdef ENABLE_DEBUGGER_SUPPORT
349 if (info->is_eval()) { 349 if (info->is_eval()) {
350 Script::CompilationType compilation_type = Script::COMPILATION_TYPE_EVAL; 350 Script::CompilationType compilation_type = Script::COMPILATION_TYPE_EVAL;
351 script->set_compilation_type(Smi::FromInt(compilation_type)); 351 script->set_compilation_type(Smi::FromInt(compilation_type));
(...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after
568 } 568 }
569 } 569 }
570 570
571 return result; 571 return result;
572 } 572 }
573 573
574 574
575 bool Compiler::CompileLazy(CompilationInfo* info) { 575 bool Compiler::CompileLazy(CompilationInfo* info) {
576 Isolate* isolate = info->isolate(); 576 Isolate* isolate = info->isolate();
577 577
578 CompilationZoneScope zone_scope(isolate, DELETE_ON_EXIT); 578 ZoneScope zone_scope(isolate, DELETE_ON_EXIT);
579 579
580 // The VM is in the COMPILER state until exiting this function. 580 // The VM is in the COMPILER state until exiting this function.
581 VMState state(isolate, COMPILER); 581 VMState state(isolate, COMPILER);
582 582
583 PostponeInterruptsScope postpone(isolate); 583 PostponeInterruptsScope postpone(isolate);
584 584
585 Handle<SharedFunctionInfo> shared = info->shared_info(); 585 Handle<SharedFunctionInfo> shared = info->shared_info();
586 int compiled_size = shared->end_position() - shared->start_position(); 586 int compiled_size = shared->end_position() - shared->start_position();
587 isolate->counters()->total_compile_size()->Increment(compiled_size); 587 isolate->counters()->total_compile_size()->Increment(compiled_size);
588 588
(...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after
781 shared->DebugName())); 781 shared->DebugName()));
782 } 782 }
783 } 783 }
784 784
785 GDBJIT(AddCode(Handle<String>(shared->DebugName()), 785 GDBJIT(AddCode(Handle<String>(shared->DebugName()),
786 Handle<Script>(info->script()), 786 Handle<Script>(info->script()),
787 Handle<Code>(info->code()))); 787 Handle<Code>(info->code())));
788 } 788 }
789 789
790 } } // namespace v8::internal 790 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/compiler.h ('k') | src/isolate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698