summaryrefslogtreecommitdiffstats
path: root/webkit
diff options
context:
space:
mode:
authorjbates@chromium.org <jbates@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-01-24 02:03:45 +0000
committerjbates@chromium.org <jbates@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-01-24 02:03:45 +0000
commita8e5b70fce9edfee935215237540e36ba5d8faf1 (patch)
treef322468240a7247c1acad4db3d5d75f93d37a1d9 /webkit
parent1b99f15022b1178849c6a990355904b09165ed44 (diff)
downloadchromium_src-a8e5b70fce9edfee935215237540e36ba5d8faf1.zip
chromium_src-a8e5b70fce9edfee935215237540e36ba5d8faf1.tar.gz
chromium_src-a8e5b70fce9edfee935215237540e36ba5d8faf1.tar.bz2
add webkitplatform support for new tracing API.
Review URL: http://codereview.chromium.org/9212019 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@118779 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit')
-rw-r--r--webkit/glue/webkitplatformsupport_impl.cc28
-rw-r--r--webkit/glue/webkitplatformsupport_impl.h14
2 files changed, 42 insertions, 0 deletions
diff --git a/webkit/glue/webkitplatformsupport_impl.cc b/webkit/glue/webkitplatformsupport_impl.cc
index 0605652..f55ecb6 100644
--- a/webkit/glue/webkitplatformsupport_impl.cc
+++ b/webkit/glue/webkitplatformsupport_impl.cc
@@ -305,6 +305,34 @@ void WebKitPlatformSupportImpl::traceEventEnd(const char* name, void* id,
TRACE_EVENT_END_ETW(name, id, extra);
}
+const unsigned char* WebKitPlatformSupportImpl::getCategoryEnabled(
+ const char* category_name) {
+ return TRACE_EVENT_API_GET_CATEGORY_ENABLED(category_name);
+}
+
+int WebKitPlatformSupportImpl::addTraceEvent(
+ char phase,
+ const unsigned char* category_enabled,
+ const char* name,
+ unsigned long long id,
+ int num_args,
+ const char** arg_names,
+ const unsigned char* arg_types,
+ const unsigned long long* arg_values,
+ int threshold_begin_id,
+ long long threshold,
+ unsigned char flags) {
+ return TRACE_EVENT_API_ADD_TRACE_EVENT(phase, category_enabled, name, id,
+ num_args, arg_names, arg_types,
+ arg_values, threshold_begin_id,
+ threshold, flags);
+}
+
+unsigned long long WebKitPlatformSupportImpl::manglePointerForTracing(
+ void* pointer) {
+ return TRACE_EVENT_API_GET_ID_FROM_POINTER(pointer);
+}
+
namespace {
WebData loadAudioSpatializationResource(WebKitPlatformSupportImpl* platform,
diff --git a/webkit/glue/webkitplatformsupport_impl.h b/webkit/glue/webkitplatformsupport_impl.h
index 7604600..ad9c4a7 100644
--- a/webkit/glue/webkitplatformsupport_impl.h
+++ b/webkit/glue/webkitplatformsupport_impl.h
@@ -73,6 +73,20 @@ class WEBKIT_GLUE_EXPORT WebKitPlatformSupportImpl :
virtual bool isTraceEventEnabled() const;
virtual void traceEventBegin(const char* name, void* id, const char* extra);
virtual void traceEventEnd(const char* name, void* id, const char* extra);
+ virtual const unsigned char* getCategoryEnabled(const char* category_name);
+ virtual int addTraceEvent(
+ char phase,
+ const unsigned char* category_enabled,
+ const char* name,
+ unsigned long long id,
+ int num_args,
+ const char** arg_names,
+ const unsigned char* arg_types,
+ const unsigned long long* arg_values,
+ int threshold_begin_id,
+ long long threshold,
+ unsigned char flags);
+ virtual unsigned long long manglePointerForTracing(void* pointer);
virtual WebKit::WebData loadResource(const char* name);
virtual bool loadAudioResource(
WebKit::WebAudioBus* destination_bus, const char* audio_file_data,