OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium 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 <math.h> | 5 #include <math.h> |
6 | 6 |
7 #include "base/basictypes.h" | 7 #include "base/basictypes.h" |
8 #include "base/bind.h" | 8 #include "base/bind.h" |
9 #include "base/logging.h" | 9 #include "base/logging.h" |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
11 #include "base/message_loop.h" | 11 #include "base/message_loop/message_loop.h" |
12 #include "base/message_loop/message_loop_proxy.h" | 12 #include "base/message_loop/message_loop_proxy.h" |
13 #include "base/strings/string_number_conversions.h" | 13 #include "base/strings/string_number_conversions.h" |
14 #include "base/strings/string_split.h" | 14 #include "base/strings/string_split.h" |
15 #include "base/strings/string_tokenizer.h" | 15 #include "base/strings/string_tokenizer.h" |
16 #include "base/synchronization/condition_variable.h" | 16 #include "base/synchronization/condition_variable.h" |
17 #include "base/synchronization/lock.h" | 17 #include "base/synchronization/lock.h" |
18 #include "base/threading/platform_thread.h" | 18 #include "base/threading/platform_thread.h" |
19 #include "base/time/time.h" | 19 #include "base/time/time.h" |
20 #include "build/build_config.h" | 20 #include "build/build_config.h" |
21 #include "chrome/browser/metrics/thread_watcher.h" | 21 #include "chrome/browser/metrics/thread_watcher.h" |
(...skipping 588 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
610 base::Bind(&ThreadWatcher::DeActivateThreadWatching, | 610 base::Bind(&ThreadWatcher::DeActivateThreadWatching, |
611 base::Unretained(io_watcher_))); | 611 base::Unretained(io_watcher_))); |
612 WatchDogThread::PostTask( | 612 WatchDogThread::PostTask( |
613 FROM_HERE, | 613 FROM_HERE, |
614 base::Bind(&ThreadWatcher::DeActivateThreadWatching, | 614 base::Bind(&ThreadWatcher::DeActivateThreadWatching, |
615 base::Unretained(webkit_watcher_))); | 615 base::Unretained(webkit_watcher_))); |
616 | 616 |
617 // Wait for the io_watcher_'s VeryLongMethod to finish. | 617 // Wait for the io_watcher_'s VeryLongMethod to finish. |
618 io_watcher_->WaitForWaitStateChange(kUnresponsiveTime * 10, ALL_DONE); | 618 io_watcher_->WaitForWaitStateChange(kUnresponsiveTime * 10, ALL_DONE); |
619 } | 619 } |
OLD | NEW |