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

Side by Side Diff: src/optimizing-compiler-thread.cc

Issue 24466003: Add trace output when recompilation queues are flushed. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 2 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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 154 matching lines...) Expand 10 before | Expand all | Expand 10 after
165 } 165 }
166 166
167 167
168 void OptimizingCompilerThread::Flush() { 168 void OptimizingCompilerThread::Flush() {
169 ASSERT(!IsOptimizerThread()); 169 ASSERT(!IsOptimizerThread());
170 Release_Store(&stop_thread_, static_cast<AtomicWord>(FLUSH)); 170 Release_Store(&stop_thread_, static_cast<AtomicWord>(FLUSH));
171 input_queue_semaphore_.Signal(); 171 input_queue_semaphore_.Signal();
172 stop_semaphore_.Wait(); 172 stop_semaphore_.Wait();
173 FlushOutputQueue(true); 173 FlushOutputQueue(true);
174 if (FLAG_concurrent_osr) FlushOsrBuffer(true); 174 if (FLAG_concurrent_osr) FlushOsrBuffer(true);
175 if (FLAG_trace_concurrent_recompilation) {
176 PrintF(" ** Flushed concurrent recompilation queues.\n");
177 }
175 } 178 }
176 179
177 180
178 void OptimizingCompilerThread::Stop() { 181 void OptimizingCompilerThread::Stop() {
179 ASSERT(!IsOptimizerThread()); 182 ASSERT(!IsOptimizerThread());
180 Release_Store(&stop_thread_, static_cast<AtomicWord>(STOP)); 183 Release_Store(&stop_thread_, static_cast<AtomicWord>(STOP));
181 input_queue_semaphore_.Signal(); 184 input_queue_semaphore_.Signal();
182 stop_semaphore_.Wait(); 185 stop_semaphore_.Wait();
183 186
184 if (FLAG_concurrent_recompilation_delay != 0) { 187 if (FLAG_concurrent_recompilation_delay != 0) {
(...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after
329 #ifdef DEBUG 332 #ifdef DEBUG
330 bool OptimizingCompilerThread::IsOptimizerThread() { 333 bool OptimizingCompilerThread::IsOptimizerThread() {
331 if (!FLAG_concurrent_recompilation) return false; 334 if (!FLAG_concurrent_recompilation) return false;
332 LockGuard<Mutex> lock_guard(&thread_id_mutex_); 335 LockGuard<Mutex> lock_guard(&thread_id_mutex_);
333 return ThreadId::Current().ToInteger() == thread_id_; 336 return ThreadId::Current().ToInteger() == thread_id_;
334 } 337 }
335 #endif 338 #endif
336 339
337 340
338 } } // namespace v8::internal 341 } } // 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