[patch] Disable store merging in asan_expand_mark_ifn
Eric Botcazou
ebotcazou@adacore.com
Mon Feb 11 10:03:00 GMT 2019
Hi,
asan_expand_mark_ifn does manual store merging but doesn't take into account
the alignment, so this can break on strict-alignment platforms.
Tested on SPARC/Solaris 11, where this fixes this regression:
FAIL: gcc.dg/asan/use-after-scope-5.c -O0 output pattern test
FAIL: gcc.dg/asan/use-after-scope-5.c -O1 output pattern test
FAIL: gcc.dg/asan/use-after-scope-5.c -O2 output pattern test
FAIL: gcc.dg/asan/use-after-scope-5.c -O3 -fomit-frame-pointer -funroll-
loops -fpeel-loops -ftracer -finline-functions output pattern test
FAIL: gcc.dg/asan/use-after-scope-5.c -O3 -g output pattern test
FAIL: gcc.dg/asan/use-after-scope-5.c -Os output pattern test
FAIL: gcc.dg/asan/use-after-scope-5.c -O2 -flto -flto-partition=none output
pattern test
FAIL: gcc.dg/asan/use-after-scope-5.c -O2 -flto output pattern test
OK for mainline?
2019-02-11 Eric Botcazou <ebotcazou@adacore.com>
* asan.c (asan_expand_mark_ifn): Always use a size of 1 byte for the
stores on strict-alignment platforms.
--
Eric Botcazou
-------------- next part --------------
A non-text attachment was scrubbed...
Name: p.diff
Type: text/x-patch
Size: 682 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20190211/aeed720c/attachment.bin>
More information about the Gcc-patches
mailing list