On Tue, 9 Jun 2020 at 15:22, Jakub Jelinek <ja...@redhat.com> wrote: > > On Tue, Jun 09, 2020 at 03:15:39PM +0200, Marco Elver wrote: > > gcc/ > > * params.opt: Define --param=tsan-distinguish-volatile=[0,1]. > > * sanitizer.def (BUILT_IN_TSAN_VOLATILE_READ1): Define new > > builtin for volatile instrumentation of reads/writes. > > (BUILT_IN_TSAN_VOLATILE_READ2): Likewise. > > (BUILT_IN_TSAN_VOLATILE_READ4): Likewise. > > (BUILT_IN_TSAN_VOLATILE_READ8): Likewise. > > (BUILT_IN_TSAN_VOLATILE_READ16): Likewise. > > (BUILT_IN_TSAN_VOLATILE_WRITE1): Likewise. > > (BUILT_IN_TSAN_VOLATILE_WRITE2): Likewise. > > (BUILT_IN_TSAN_VOLATILE_WRITE4): Likewise. > > (BUILT_IN_TSAN_VOLATILE_WRITE8): Likewise. > > (BUILT_IN_TSAN_VOLATILE_WRITE16): Likewise. > > * tsan.c (get_memory_access_decl): Argument if access is > > volatile. If param tsan-distinguish-volatile is non-zero, and > > access if volatile, return volatile instrumentation decl. > > (instrument_expr): Check if access is volatile. > > > > gcc/testsuite/ > > * c-c++-common/tsan/volatile.c: New test. > > > > Acked-by: Dmitry Vyukov <dvyu...@google.com> > > Ok, thanks.
I think one of you has to commit the patch, as we don't have access to the GCC git repository. Thank you! -- Marco