summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--content/common/devtools_messages.h2
-rw-r--r--content/common/gpu/devtools_gpu_agent.cc4
-rw-r--r--content/common/gpu/devtools_gpu_agent.h3
-rw-r--r--content/renderer/devtools/devtools_agent.cc2
4 files changed, 6 insertions, 5 deletions
diff --git a/content/common/devtools_messages.h b/content/common/devtools_messages.h
index 5d67c22..9154aaf 100644
--- a/content/common/devtools_messages.h
+++ b/content/common/devtools_messages.h
@@ -128,7 +128,7 @@ IPC_MESSAGE_ROUTED0(DevToolsHostMsg_ClearBrowserCookies)
IPC_STRUCT_BEGIN(GpuTaskInfo)
IPC_STRUCT_MEMBER(double, timestamp)
IPC_STRUCT_MEMBER(int, phase)
- IPC_STRUCT_MEMBER(unsigned, owner_pid)
+ IPC_STRUCT_MEMBER(bool, foreign)
IPC_STRUCT_END()
// Recorded events are passed in chunks to the renderer process.
diff --git a/content/common/gpu/devtools_gpu_agent.cc b/content/common/gpu/devtools_gpu_agent.cc
index 315be90..ecdf739 100644
--- a/content/common/gpu/devtools_gpu_agent.cc
+++ b/content/common/gpu/devtools_gpu_agent.cc
@@ -48,7 +48,7 @@ void DevToolsGpuAgent::StopEventsRecording() {
void DevToolsGpuAgent::ProcessEvent(
TimeTicks timestamp,
GpuEventsDispatcher::EventPhase phase,
- int owner_pid) {
+ base::ProcessId owner_pid) {
DCHECK(CalledOnValidThread());
if (route_id_ == MSG_ROUTING_NONE)
return;
@@ -56,7 +56,7 @@ void DevToolsGpuAgent::ProcessEvent(
GpuTaskInfo task;
task.timestamp = (timestamp - TimeTicks()).InSecondsF();
task.phase = phase;
- task.owner_pid = owner_pid;
+ task.foreign = gpu_channel_->renderer_pid() != owner_pid;
const int kFlushIntervalMs = 100;
const unsigned kMaxPendingItems = 100;
diff --git a/content/common/gpu/devtools_gpu_agent.h b/content/common/gpu/devtools_gpu_agent.h
index 94174bf..ef2529d 100644
--- a/content/common/gpu/devtools_gpu_agent.h
+++ b/content/common/gpu/devtools_gpu_agent.h
@@ -6,6 +6,7 @@
#define CONTENT_COMMON_GPU_DEVTOOLS_GPU_AGENT_H_
#include "base/memory/scoped_ptr.h"
+#include "base/process/process.h"
#include "base/threading/non_thread_safe.h"
#include "base/time/time.h"
#include "content/common/gpu/devtools_gpu_instrumentation.h"
@@ -28,7 +29,7 @@ class DevToolsGpuAgent : public base::NonThreadSafe {
void ProcessEvent(TimeTicks timestamp,
GpuEventsDispatcher::EventPhase,
- int owner_pid);
+ base::ProcessId owner_pid);
void StartEventsRecording(int32* route_id);
void StopEventsRecording();
diff --git a/content/renderer/devtools/devtools_agent.cc b/content/renderer/devtools/devtools_agent.cc
index 8cc13d9..102029a 100644
--- a/content/renderer/devtools/devtools_agent.cc
+++ b/content/renderer/devtools/devtools_agent.cc
@@ -205,7 +205,7 @@ void DevToolsAgent::OnGpuTasksChunk(const std::vector<GpuTaskInfo>& tasks) {
return;
for (size_t i = 0; i < tasks.size(); i++) {
const GpuTaskInfo& task = tasks[i];
- web_agent->processGPUEvent(task.timestamp, task.phase, task.owner_pid);
+ web_agent->processGPUEvent(task.timestamp, task.phase, task.foreign);
}
}