Fix sampling profiler to use thread's cpu clock.
The sampling profiler was using the sampling thread's cpu clock to
measure cpu time, instead of the sampled thread's cpu clock.
Change-Id: Ief1f82e07e0353192c61521f67dec7a761905f64
diff --git a/runtime/thread.h b/runtime/thread.h
index b9b93dd..f16695d 100644
--- a/runtime/thread.h
+++ b/runtime/thread.h
@@ -267,6 +267,9 @@
// Sets the thread's name.
void SetThreadName(const char* name) SHARED_LOCKS_REQUIRED(Locks::mutator_lock_);
+ // Returns the thread-specific CPU-time clock in microseconds or -1 if unavailable.
+ uint64_t GetCpuMicroTime() const;
+
mirror::Object* GetPeer() const SHARED_LOCKS_REQUIRED(Locks::mutator_lock_) {
CHECK(jpeer_ == NULL);
return opeer_;