Re: [PATCH 7/7] Libsanitizer merge from upstream r285547.

2016-11-07 Thread Jakub Jelinek
On Mon, Nov 07, 2016 at 11:31:18AM +0300, Maxim Ostapenko wrote: > --- a/gcc/asan.c > +++ b/gcc/asan.c > @@ -1329,6 +1329,16 @@ asan_needs_local_alias (tree decl) >return DECL_WEAK (decl) || !targetm.binds_local_p (decl); > } > > +/* Return true if DECL, a global var, is an artificial ODR

[PATCH 7/7] Libsanitizer merge from upstream r285547.

2016-11-07 Thread Maxim Ostapenko
This patch tries to implement odr indicators functionality at compiler side. We emit new __odr_asan_XXX symbol for each instrumented global that indicates whether this global was already registered and the library checks this indicator symbol at runtime. For some globals (e.g. static or