Tip-of-tree fails to start under ASan due to ODR violations |
|||||
Issue descriptionChrome Version: f5065232010251bad1cccddcc2a0d27ac2232f67 OS: Linux (Goobuntu) What steps will reproduce the problem? (1) Build chrome with ASan enabled (ninja -C out/Default chrome) (2) Attempt to start chrome (out/Default/chrome) What is the expected result? Chrome starts. What happens instead? ASan induced crash due to ODR violations: ~/chromium/src (master)$ out/Default/chrome ================================================================= ==133496==ERROR: AddressSanitizer: odr-violation (0x7f5f06e6b820): [1] size=9 'switches::kHeadless' ../../ui/gfx/switches.cc:22:12 [2] size=9 'switches::kHeadless' ../../ui/gfx/switches.cc:22:12 These globals were registered at these points: [1]: #0 0x56143e82fcde (~/chromium/src/out/Default/chrome+0x18cecde) #1 0x7f5f06c0596d (~/chromium/src/out/Default/./libgfx.so+0x39496d) [2]: #0 0x56143e82fcde (~/chromium/src/out/Default/chrome+0x18cecde) #1 0x7f5f06865b0d (~/chromium/src/out/Default/./libcolor_space.so+0x47b0d) ==133496==HINT: if you don't care about these errors you may set ASAN_OPTIONS=detect_odr_violation=0 SUMMARY: AddressSanitizer: odr-violation: global 'switches::kHeadless' at ../../ui/gfx/switches.cc:22:12 ==133496==ABORTING
,
May 19 2017
They're from different .so's. something's getting statically linked into two shlibs, which isn't so great.
,
May 19 2017
Right, a typical ODR. There are actually two instances of switches::kHeadless in the program, which can have all kinds of fun effects.
,
May 19 2017
This was broken in https://codereview.chromium.org/2795093002/ basically.
,
May 22 2017
Re #1: This was a local compilation on my desktop.
,
May 30 2017
,
May 30 2017
It looks like component("geometry_skia") also defines GFX_IMPLEMENTATION in ui/gfx/BUILD.gn. I'll look at both of them.
,
Jun 16 2017
I just hit this as well; it'd be nice to fix this. It's pretty easy to repro; the GN args I'm using on Linux are: is_component_build = true dcheck_always_on = true use_goma = true is_asan = true is_debug = false # Release build. symbol_level = 2
,
Jun 16 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/fd83a51df6653957aa077d1f1083bfe4118920c4 commit fd83a51df6653957aa077d1f1083bfe4118920c4 Author: ccameron <ccameron@chromium.org> Date: Fri Jun 16 21:26:12 2017 ui/gfx: Use separate components for color_space and switches The need for switches to be separate is a temporary consequence of many workarounds for the non-color-correct-rendering path spread throughout the code. Once these workarounds are removed, the switches component can be pulled back into color_space and sources. R=thakis TBR=avi for content/ BUG= 723608 Review-Url: https://codereview.chromium.org/2915673003 Cr-Commit-Position: refs/heads/master@{#480175} [modify] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/chrome/browser/about_flags.cc [modify] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/chrome/browser/chromeos/login/chrome_restart_request.cc [modify] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/content/browser/gpu/gpu_process_host.cc [modify] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/content/browser/renderer_host/render_process_host_impl.cc [modify] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/content/browser/renderer_host/render_view_host_impl.cc [modify] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/content/renderer/gpu/render_widget_compositor.cc [modify] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/content/shell/app/shell_main_delegate.cc [modify] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/content/test/layouttest_support.cc [modify] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/ui/compositor/compositor.cc [modify] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/ui/compositor/compositor_util.cc [modify] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/ui/display/mac/screen_mac.mm [modify] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/ui/gfx/BUILD.gn [modify] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/ui/gfx/color_space.h [add] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/ui/gfx/color_space_export.h [add] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/ui/gfx/color_space_switches.cc [add] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/ui/gfx/color_space_switches.h [modify] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/ui/gfx/color_space_win.h [modify] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/ui/gfx/icc_profile.cc [modify] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/ui/gfx/icc_profile.h [modify] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/ui/gfx/mac/io_surface.cc [modify] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/ui/gfx/skia_color_space_util.cc [modify] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/ui/gfx/skia_color_space_util.h [modify] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/ui/gfx/switches.cc [modify] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/ui/gfx/switches.h [add] https://crrev.com/fd83a51df6653957aa077d1f1083bfe4118920c4/ui/gfx/switches_export.h
,
Jun 16 2017
|
|||||
►
Sign in to add a comment |
|||||
Comment 1 by h...@chromium.org
, May 19 2017Status: Available (was: Untriaged)