public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "shaohua.li at inf dot ethz.ch" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug sanitizer/107698] ASAN misses a global-buffer-overflow Date: Wed, 16 Nov 2022 09:32:06 +0000 [thread overview] Message-ID: <bug-107698-4-d1WjEB4AbL@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-107698-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107698 --- Comment #2 from Li Shaohua <shaohua.li at inf dot ethz.ch> --- I found a new test where gcc-O1 misses the global-buffer-overflow. Not sure if these two have the same root cause: % cat a.c int a, c; int *b = &a; int main() { int d = *b; for (; c < 3; c++) b = b + (d == *b); } % % gcc-tk -O1 -fsanitize=address a.c && ./a.out % % gcc-tk -O3 -fsanitize=address a.c && ./a.out ================================================================= ==3536571==ERROR: AddressSanitizer: global-buffer-overflow on address 0x000000404204 at pc 0x000000401130 bp 0x7ffe232ffd40 sp 0x7ffe232ffd38 ... %
next prev parent reply other threads:[~2022-11-16 9:32 UTC|newest] Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top 2022-11-15 13:52 [Bug sanitizer/107698] New: " shaohua.li at inf dot ethz.ch 2022-11-15 14:43 ` [Bug sanitizer/107698] " marxin at gcc dot gnu.org 2022-11-16 9:32 ` shaohua.li at inf dot ethz.ch [this message] 2022-12-02 12:51 ` marxin at gcc dot gnu.org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-107698-4-d1WjEB4AbL@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).