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

Side by Side Diff: src/heap.cc

Issue 669150: Try to let the context disposal GC at idle time have less... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 10 years, 9 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 | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2009 the V8 project authors. All rights reserved. 1 // Copyright 2009 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 3067 matching lines...) Expand 10 before | Expand all | Expand 10 after
3078 static const int kIdlesBeforeScavenge = 4; 3078 static const int kIdlesBeforeScavenge = 4;
3079 static const int kIdlesBeforeMarkSweep = 7; 3079 static const int kIdlesBeforeMarkSweep = 7;
3080 static const int kIdlesBeforeMarkCompact = 8; 3080 static const int kIdlesBeforeMarkCompact = 8;
3081 static int number_idle_notifications = 0; 3081 static int number_idle_notifications = 0;
3082 static int last_gc_count = gc_count_; 3082 static int last_gc_count = gc_count_;
3083 3083
3084 if (contexts_disposed_ > 0) { 3084 if (contexts_disposed_ > 0) {
3085 HistogramTimerScope scope(&Counters::gc_context); 3085 HistogramTimerScope scope(&Counters::gc_context);
3086 CollectAllGarbage(false); 3086 CollectAllGarbage(false);
3087 ASSERT(contexts_disposed_ == 0); 3087 ASSERT(contexts_disposed_ == 0);
3088 last_gc_count = gc_count_;
3088 return false; 3089 return false;
3089 } 3090 }
3090 3091
3091 bool finished = false; 3092 bool finished = false;
3092 3093
3093 if (last_gc_count == gc_count_) { 3094 if (last_gc_count == gc_count_) {
3094 number_idle_notifications++; 3095 number_idle_notifications++;
3095 } else { 3096 } else {
3096 number_idle_notifications = 0; 3097 number_idle_notifications = 0;
3097 last_gc_count = gc_count_; 3098 last_gc_count = gc_count_;
(...skipping 1140 matching lines...) Expand 10 before | Expand all | Expand 10 after
4238 void ExternalStringTable::TearDown() { 4239 void ExternalStringTable::TearDown() {
4239 new_space_strings_.Free(); 4240 new_space_strings_.Free();
4240 old_space_strings_.Free(); 4241 old_space_strings_.Free();
4241 } 4242 }
4242 4243
4243 4244
4244 List<Object*> ExternalStringTable::new_space_strings_; 4245 List<Object*> ExternalStringTable::new_space_strings_;
4245 List<Object*> ExternalStringTable::old_space_strings_; 4246 List<Object*> ExternalStringTable::old_space_strings_;
4246 4247
4247 } } // namespace v8::internal 4248 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698