Instrument bit field and unaligned accesses for TSAN.
gcc/ChangeLog:
2015-01-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
Instrument bit field and unaligned accesses for TSAN.
* sanitizer.def (BUILT_IN_TSAN_READ_RANGE): New built-in function.
(BUILT_IN_TSAN_WRITE_RANGE): New built-in function.
* tsan.c (instrument_expr): Handle COMPONENT_REF and BIT_FIELD_REF.
Use BUILT_IN_TSAN_READ_RANGE and BUILT_IN_TSAN_WRITE_RANGE for
unaligned memory regions.
testsuite/ChangeLog:
2015-01-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
* c-c++-common/tsan/bitfield_race.c: New testcase.
* g++.dg/tsan/aligned_vs_unaligned_race.C: Fixed.
From-SVN: r219150