Index: webkit/glue/webkitplatformsupport_impl.cc |
diff --git a/webkit/glue/webkitplatformsupport_impl.cc b/webkit/glue/webkitplatformsupport_impl.cc |
index 34e63d231d2d0f34fecb63e44a0249bcd9ea41b6..0064ce93f12d8f0527ab298e9c69b622d8b5cdba 100644 |
--- a/webkit/glue/webkitplatformsupport_impl.cc |
+++ b/webkit/glue/webkitplatformsupport_impl.cc |
@@ -10,7 +10,6 @@ |
#include "base/allocator/allocator_extension.h" |
#include "base/bind.h" |
-#include "base/debug/trace_event.h" |
#include "base/memory/discardable_memory.h" |
#include "base/memory/scoped_ptr.h" |
#include "base/memory/singleton.h" |
@@ -453,6 +452,21 @@ const unsigned char* WebKitPlatformSupportImpl::getTraceCategoryEnabledFlag( |
return TRACE_EVENT_API_GET_CATEGORY_ENABLED(category_name); |
} |
+long* WebKitPlatformSupportImpl::getTraceSamplingState( |
+ const unsigned thread_bucket) { |
+ switch(thread_bucket) { |
+ case 0: |
+ return reinterpret_cast<long*>(&TRACE_EVENT_API_THREAD_BUCKET(0)); |
+ case 1: |
+ return reinterpret_cast<long*>(&TRACE_EVENT_API_THREAD_BUCKET(1)); |
+ case 2: |
+ return reinterpret_cast<long*>(&TRACE_EVENT_API_THREAD_BUCKET(2)); |
+ default: |
+ NOTREACHED() << "Unknown thread bucket type."; |
+ } |
+ return NULL; |
+} |
+ |
void WebKitPlatformSupportImpl::addTraceEvent( |
char phase, |
const unsigned char* category_enabled, |