On 11/01/17 14:17, Richard Biener wrote:
On Wed, Jan 11, 2017 at 10:00 AM, Maxim Ostapenko
<m.ostape...@samsung.com> wrote:
Hi,
as mentioned in PR, LTO doesn't propagate node->dynamically_initialized bit
for varpool nodes that leads to ASan fails to detect initialization order
fiasco even for trivial example (e.g. from here:
https://github.com/google/sanitizers/wiki/AddressSanitizerExampleInitOrderFiasco).
This trivial patch fixes the issue. Regtested on x86_64-unknown-linux-gnu,
OK for mainline?
Ok. This is also needed on branches, correct?
Yes, branches also need this. gcc-5-branch and gcc-6-branch, right?
Thanks,
-Maxim
Richard.
-Maxim