Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(432)

Issue 122063002: cc: Remove racy initialization code in cc/base/switches.cc. (Closed)

Created:
6 years, 12 months ago by reveman
Modified:
6 years, 11 months ago
CC:
chromium-reviews, joi+watch-content_chromium.org, piman+watch_chromium.org, cc-bugs_chromium.org, jam, darin-cc_chromium.org, sohanjg
Visibility:
Public.

Description

cc: Remove racy initialization code in cc/base/switches.cc. This moves all lazy initialization code out of cc/base/switches.cc. Code that needs the value of these switches in a critical path should not rely on lazy initialization in cc/switches.cc but instead handle this on its own. Thread-safe lazy initialization code of impl-side painting status has been added to WebLayerImpl. This also removes the cc::switches::IsGPURasterizationEnabled() function, which for consistency should not exist unless the logic to determine the value is more complicated than HasSwitch(kEnableGPURasterization). This function was never used in performance sensitive code so lazy initialization was never necessary. BUG=330937 TBR=jamesr Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=243432

Patch Set 1 #

Total comments: 2

Patch Set 2 : s/usingPictureLayer/UsingPictureLayer/ #

Patch Set 3 : fix dynamic linking problem by adding dynamic_annotations dependency to compositor_bindings #

Unified diffs Side-by-side diffs Delta from patch set Stats (+30 lines, -38 lines) Patch
M cc/base/switches.h View 1 chunk +0 lines, -1 line 0 comments Download
M cc/base/switches.cc View 2 chunks +1 line, -19 lines 0 comments Download
M content/renderer/gpu/render_widget_compositor.cc View 1 chunk +2 lines, -1 line 0 comments Download
M webkit/renderer/compositor_bindings/compositor_bindings.gyp View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M webkit/renderer/compositor_bindings/web_content_layer_impl.cc View 1 4 chunks +3 lines, -9 lines 0 comments Download
M webkit/renderer/compositor_bindings/web_image_layer_impl.cc View 1 2 chunks +2 lines, -8 lines 0 comments Download
M webkit/renderer/compositor_bindings/web_layer_impl.h View 1 1 chunk +2 lines, -0 lines 0 comments Download
M webkit/renderer/compositor_bindings/web_layer_impl.cc View 1 3 chunks +19 lines, -0 lines 0 comments Download

Messages

Total messages: 27 (0 generated)
reveman
6 years, 12 months ago (2013-12-28 13:42:35 UTC) #1
reveman
+sohanjg
6 years, 12 months ago (2013-12-28 14:47:17 UTC) #2
tomhudson
What triggers the potential race, being called from multiple raster worker threads?
6 years, 11 months ago (2013-12-30 11:20:00 UTC) #3
reveman
On 2013/12/30 11:20:00, tomhudson wrote: > What triggers the potential race, being called from multiple ...
6 years, 11 months ago (2013-12-31 00:41:04 UTC) #4
danakj1
On Dec 30, 2013 7:41 PM, <reveman@chromium.org> wrote: > > On 2013/12/30 11:20:00, tomhudson wrote: ...
6 years, 11 months ago (2013-12-31 08:48:01 UTC) #5
tomhudson
On 2013/12/31 08:48:01, danakj1 wrote: > On Dec 30, 2013 7:41 PM, <mailto:reveman@chromium.org> wrote: > ...
6 years, 11 months ago (2013-12-31 10:02:33 UTC) #6
reveman
On 2013/12/31 08:48:01, danakj1 wrote: > On Dec 30, 2013 7:41 PM, <mailto:reveman@chromium.org> wrote: > ...
6 years, 11 months ago (2013-12-31 20:33:40 UTC) #7
danakj1
On Dec 31, 2013 3:33 PM, <reveman@chromium.org> wrote: > > On 2013/12/31 08:48:01, danakj1 wrote: ...
6 years, 11 months ago (2014-01-01 02:38:53 UTC) #8
reveman
On 2014/01/01 02:38:53, danakj1 wrote: > On Dec 31, 2013 3:33 PM, <mailto:reveman@chromium.org> wrote: > ...
6 years, 11 months ago (2014-01-01 23:01:43 UTC) #9
enne (OOO)
lgtm I think this race is benign in that multiple threads would initialize that static ...
6 years, 11 months ago (2014-01-02 18:12:07 UTC) #10
reveman
On 2014/01/02 18:12:07, enne wrote: > lgtm > > I think this race is benign ...
6 years, 11 months ago (2014-01-02 19:25:32 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/reveman@chromium.org/122063002/1
6 years, 11 months ago (2014-01-03 02:18:21 UTC) #12
commit-bot: I haz the power
Retried try job too often on chromium_presubmit for step(s) presubmit http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=chromium_presubmit&number=43128
6 years, 11 months ago (2014-01-03 02:33:34 UTC) #13
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/reveman@chromium.org/122063002/1
6 years, 11 months ago (2014-01-03 03:05:47 UTC) #14
commit-bot: I haz the power
Retried try job too often on linux_rel for step(s) chromedriver2_unittests http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=linux_rel&number=209425
6 years, 11 months ago (2014-01-03 03:29:50 UTC) #15
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/reveman@chromium.org/122063002/1
6 years, 11 months ago (2014-01-03 06:30:29 UTC) #16
commit-bot: I haz the power
Retried try job too often on linux_rel for step(s) chromedriver2_unittests http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=linux_rel&number=209454
6 years, 11 months ago (2014-01-03 07:15:10 UTC) #17
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/reveman@chromium.org/122063002/1
6 years, 11 months ago (2014-01-03 17:11:26 UTC) #18
commit-bot: I haz the power
Retried try job too often on mac_rel for step(s) chromedriver2_unittests http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=mac_rel&number=207497
6 years, 11 months ago (2014-01-03 17:58:58 UTC) #19
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/reveman@chromium.org/122063002/1
6 years, 11 months ago (2014-01-03 19:57:53 UTC) #20
commit-bot: I haz the power
Retried try job too often on android_clang_dbg for step(s) slave_steps http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=android_clang_dbg&number=104149
6 years, 11 months ago (2014-01-03 20:54:35 UTC) #21
danakj
https://codereview.chromium.org/122063002/diff/1/webkit/renderer/compositor_bindings/web_layer_impl.h File webkit/renderer/compositor_bindings/web_layer_impl.h (right): https://codereview.chromium.org/122063002/diff/1/webkit/renderer/compositor_bindings/web_layer_impl.h#newcode55 webkit/renderer/compositor_bindings/web_layer_impl.h:55: static bool usingPictureLayer(); nit: since this isn't overriding a ...
6 years, 11 months ago (2014-01-06 18:13:24 UTC) #22
reveman
https://codereview.chromium.org/122063002/diff/1/webkit/renderer/compositor_bindings/web_layer_impl.h File webkit/renderer/compositor_bindings/web_layer_impl.h (right): https://codereview.chromium.org/122063002/diff/1/webkit/renderer/compositor_bindings/web_layer_impl.h#newcode55 webkit/renderer/compositor_bindings/web_layer_impl.h:55: static bool usingPictureLayer(); On 2014/01/06 18:13:25, danakj wrote: > ...
6 years, 11 months ago (2014-01-06 18:32:28 UTC) #23
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/reveman@chromium.org/122063002/800001
6 years, 11 months ago (2014-01-06 23:27:23 UTC) #24
commit-bot: I haz the power
Retried try job too often on android_clang_dbg for step(s) slave_steps http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=android_clang_dbg&number=104540
6 years, 11 months ago (2014-01-07 01:01:41 UTC) #25
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/reveman@chromium.org/122063002/1080001
6 years, 11 months ago (2014-01-07 21:10:47 UTC) #26
commit-bot: I haz the power
6 years, 11 months ago (2014-01-07 23:34:52 UTC) #27
Message was sent while issue was closed.
Change committed as 243432

Powered by Google App Engine
This is Rietveld 408576698