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

Side by Side Diff: src/heap/mark-compact.cc

Issue 547293004: Rename Runtime_CompileUnoptimized to Runtime_CompileLazy, because that is what it does. Split Compi… (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 3 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/debug.cc ('k') | src/ia32/builtins-ia32.cc » ('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 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/base/atomicops.h" 7 #include "src/base/atomicops.h"
8 #include "src/base/bits.h" 8 #include "src/base/bits.h"
9 #include "src/code-stubs.h" 9 #include "src/code-stubs.h"
10 #include "src/compilation-cache.h" 10 #include "src/compilation-cache.h"
(...skipping 1006 matching lines...) Expand 10 before | Expand all | Expand 10 after
1017 // reachable from the objects on the marking stack, but no longer push them on 1017 // reachable from the objects on the marking stack, but no longer push them on
1018 // the marking stack. Instead, we mark them as both marked and overflowed. 1018 // the marking stack. Instead, we mark them as both marked and overflowed.
1019 // When the stack is in the overflowed state, objects marked as overflowed 1019 // When the stack is in the overflowed state, objects marked as overflowed
1020 // have been reached and marked but their children have not been visited yet. 1020 // have been reached and marked but their children have not been visited yet.
1021 // After emptying the marking stack, we clear the overflow flag and traverse 1021 // After emptying the marking stack, we clear the overflow flag and traverse
1022 // the heap looking for objects marked as overflowed, push them on the stack, 1022 // the heap looking for objects marked as overflowed, push them on the stack,
1023 // and continue with marking. This process repeats until all reachable 1023 // and continue with marking. This process repeats until all reachable
1024 // objects have been marked. 1024 // objects have been marked.
1025 1025
1026 void CodeFlusher::ProcessJSFunctionCandidates() { 1026 void CodeFlusher::ProcessJSFunctionCandidates() {
1027 Code* lazy_compile = 1027 Code* lazy_compile = isolate_->builtins()->builtin(Builtins::kCompileLazy);
1028 isolate_->builtins()->builtin(Builtins::kCompileUnoptimized);
1029 Object* undefined = isolate_->heap()->undefined_value(); 1028 Object* undefined = isolate_->heap()->undefined_value();
1030 1029
1031 JSFunction* candidate = jsfunction_candidates_head_; 1030 JSFunction* candidate = jsfunction_candidates_head_;
1032 JSFunction* next_candidate; 1031 JSFunction* next_candidate;
1033 while (candidate != NULL) { 1032 while (candidate != NULL) {
1034 next_candidate = GetNextCandidate(candidate); 1033 next_candidate = GetNextCandidate(candidate);
1035 ClearNextCandidate(candidate, undefined); 1034 ClearNextCandidate(candidate, undefined);
1036 1035
1037 SharedFunctionInfo* shared = candidate->shared(); 1036 SharedFunctionInfo* shared = candidate->shared();
1038 1037
(...skipping 24 matching lines...) Expand all
1063 shared_code_slot, shared_code_slot, *shared_code_slot); 1062 shared_code_slot, shared_code_slot, *shared_code_slot);
1064 1063
1065 candidate = next_candidate; 1064 candidate = next_candidate;
1066 } 1065 }
1067 1066
1068 jsfunction_candidates_head_ = NULL; 1067 jsfunction_candidates_head_ = NULL;
1069 } 1068 }
1070 1069
1071 1070
1072 void CodeFlusher::ProcessSharedFunctionInfoCandidates() { 1071 void CodeFlusher::ProcessSharedFunctionInfoCandidates() {
1073 Code* lazy_compile = 1072 Code* lazy_compile = isolate_->builtins()->builtin(Builtins::kCompileLazy);
1074 isolate_->builtins()->builtin(Builtins::kCompileUnoptimized);
1075 1073
1076 SharedFunctionInfo* candidate = shared_function_info_candidates_head_; 1074 SharedFunctionInfo* candidate = shared_function_info_candidates_head_;
1077 SharedFunctionInfo* next_candidate; 1075 SharedFunctionInfo* next_candidate;
1078 while (candidate != NULL) { 1076 while (candidate != NULL) {
1079 next_candidate = GetNextCandidate(candidate); 1077 next_candidate = GetNextCandidate(candidate);
1080 ClearNextCandidate(candidate); 1078 ClearNextCandidate(candidate);
1081 1079
1082 Code* code = candidate->code(); 1080 Code* code = candidate->code();
1083 MarkBit code_mark = Marking::MarkBitFrom(code); 1081 MarkBit code_mark = Marking::MarkBitFrom(code);
1084 if (!code_mark.Get()) { 1082 if (!code_mark.Get()) {
(...skipping 3470 matching lines...) Expand 10 before | Expand all | Expand 10 after
4555 SlotsBuffer* buffer = *buffer_address; 4553 SlotsBuffer* buffer = *buffer_address;
4556 while (buffer != NULL) { 4554 while (buffer != NULL) {
4557 SlotsBuffer* next_buffer = buffer->next(); 4555 SlotsBuffer* next_buffer = buffer->next();
4558 DeallocateBuffer(buffer); 4556 DeallocateBuffer(buffer);
4559 buffer = next_buffer; 4557 buffer = next_buffer;
4560 } 4558 }
4561 *buffer_address = NULL; 4559 *buffer_address = NULL;
4562 } 4560 }
4563 } 4561 }
4564 } // namespace v8::internal 4562 } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/debug.cc ('k') | src/ia32/builtins-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698