Commit aaa2a508 authored by dtu@chromium.org's avatar dtu@chromium.org

Add new fields to GPU benchmarking API.

Add droppedFrameCount, totalPaintTime, and totalRasterizeTime to chrome.gpuBenchmarking.renderingStats().


BUG=chromium:130790, chromium:137756
TEST=Launch Chrome with --enable-gpu-benchmarking and per-tile painting, open a tab to a composited page, and type chrome.gpuBenchmarking.renderingStats(). All the above fields should be present.

Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=148413

Review URL: https://chromiumcodereview.appspot.com/10823023

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@148481 0039d316-1c4b-4281-b951-d872f2087c98
parent 3c6d186f
...@@ -78,6 +78,18 @@ class GpuBenchmarkingWrapper : public v8::Extension { ...@@ -78,6 +78,18 @@ class GpuBenchmarkingWrapper : public v8::Extension {
stats_object->Set(v8::String::New("numFramesSentToScreen"), stats_object->Set(v8::String::New("numFramesSentToScreen"),
v8::Integer::New(stats.numFramesSentToScreen), v8::Integer::New(stats.numFramesSentToScreen),
v8::ReadOnly); v8::ReadOnly);
if (stats.droppedFrameCount)
stats_object->Set(v8::String::New("droppedFrameCount"),
v8::Integer::New(stats.droppedFrameCount),
v8::ReadOnly);
if (stats.totalPaintTimeInSeconds)
stats_object->Set(v8::String::New("totalPaintTimeInSeconds"),
v8::Number::New(stats.totalPaintTimeInSeconds),
v8::ReadOnly);
if (stats.totalRasterizeTimeInSeconds)
stats_object->Set(v8::String::New("totalRasterizeTimeInSeconds"),
v8::Number::New(stats.totalRasterizeTimeInSeconds),
v8::ReadOnly);
return stats_object; return stats_object;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment