summaryrefslogtreecommitdiffstats
path: root/cc/resources/content_layer_updater.cc
diff options
context:
space:
mode:
authorrsleevi@chromium.org <rsleevi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-03-29 12:56:29 +0000
committerrsleevi@chromium.org <rsleevi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-03-29 12:56:29 +0000
commitc188cdb0f36a7bc7ea1c2f2c081be05240ddf265 (patch)
treead83339ca492127942e159d6e98bec4dcf661b94 /cc/resources/content_layer_updater.cc
parentce6689f6a30933c96520ee88be43216e961852ae (diff)
downloadchromium_src-c188cdb0f36a7bc7ea1c2f2c081be05240ddf265.zip
chromium_src-c188cdb0f36a7bc7ea1c2f2c081be05240ddf265.tar.gz
chromium_src-c188cdb0f36a7bc7ea1c2f2c081be05240ddf265.tar.bz2
Revert 191327 "cc: Switch ContentLayerUpdater to use RenderingSt..."
Continued crashes on Win Aura related to cc/ and locks > cc: Switch ContentLayerUpdater to use RenderingStatsInstrumentation > > depends on: https://codereview.chromium.org/13266002/ > > BUG=181319 > > > Review URL: https://chromiumcodereview.appspot.com/13265003 TBR=egraether@chromium.org Review URL: https://codereview.chromium.org/13155003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@191344 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'cc/resources/content_layer_updater.cc')
-rw-r--r--cc/resources/content_layer_updater.cc18
1 files changed, 7 insertions, 11 deletions
diff --git a/cc/resources/content_layer_updater.cc b/cc/resources/content_layer_updater.cc
index d242ae9..0651e87 100644
--- a/cc/resources/content_layer_updater.cc
+++ b/cc/resources/content_layer_updater.cc
@@ -56,18 +56,14 @@ void ContentLayerUpdater::PaintContents(SkCanvas* canvas,
canvas->clipRect(layer_sk_rect);
gfx::RectF opaque_layer_rect;
-
- base::TimeTicks start_time =
- rendering_stats_instrumentation_->StartRecording();
-
+ base::TimeTicks paint_begin_time;
+ if (stats)
+ paint_begin_time = base::TimeTicks::Now();
painter_->Paint(canvas, layer_rect, &opaque_layer_rect);
-
- base::TimeDelta duration =
- rendering_stats_instrumentation_->EndRecording(start_time);
- rendering_stats_instrumentation_->AddPaint(
- duration,
- content_rect.width() * content_rect.height());
-
+ if (stats) {
+ stats->total_paint_time += base::TimeTicks::Now() - paint_begin_time;
+ stats->total_pixels_painted += content_rect.width() * content_rect.height();
+ }
canvas->restore();
gfx::RectF opaque_content_rect = gfx::ScaleRect(