public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "bernd.edlinger at hotmail dot de" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug sanitizer/65400] tsan mis-compiles inlineable C functions Date: Fri, 13 Mar 2015 16:34:00 -0000 [thread overview] Message-ID: <bug-65400-4-HekAbX0nUD@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-65400-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65400 --- Comment #4 from Bernd Edlinger <bernd.edlinger at hotmail dot de> --- ok, this should fix the second regression: Index: tsan.c =================================================================== --- tsan.c (revision 221355) +++ tsan.c (working copy) @@ -682,6 +682,7 @@ { if (gimple_call_builtin_p (stmt, BUILT_IN_NORMAL)) instrument_builtin_call (gsi); + gimple_call_set_tail (as_a <gcall *> (stmt), false); return true; } else if (is_gimple_assign (stmt) -- opcua_p_binary.c.103t.sink-{ opcua_p_binary.c.103t.sink- OpcUa_StatusCode retval.25; opcua_p_binary.c.103t.sink- opcua_p_binary.c.103t.sink- <bb 2>: opcua_p_binary.c.103t.sink: retval.25_5 = OpcUa_Float_P_NativeToWire (wire_2(D), native_3(D)); [tail call] opcua_p_binary.c.103t.sink: return retval.25_5; opcua_p_binary.c.103t.sink- opcua_p_binary.c.103t.sink-} -- opcua_p_binary.c.105t.tsan1- <bb 2>: opcua_p_binary.c.105t.tsan1- _6 = __builtin_return_address (0); opcua_p_binary.c.105t.tsan1- __builtin___tsan_func_entry (_6); opcua_p_binary.c.105t.tsan1: retval.25_5 = OpcUa_Float_P_NativeToWire (wire_2(D), native_3(D)); opcua_p_binary.c.105t.tsan1- __builtin___tsan_func_exit (); opcua_p_binary.c.105t.tsan1: return retval.25_5; opcua_p_binary.c.105t.tsan1- opcua_p_binary.c.105t.tsan1-} see the "[tail call]" is removed, and the generated code is now OK. trying to use -O3 next.
next prev parent reply other threads:[~2015-03-13 16:34 UTC|newest] Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top 2015-03-12 11:11 [Bug sanitizer/65400] New: " bernd.edlinger at hotmail dot de 2015-03-12 15:33 ` [Bug sanitizer/65400] " bernd.edlinger at hotmail dot de 2015-03-12 15:58 ` bernd.edlinger at hotmail dot de 2015-03-13 12:47 ` bernd.edlinger at hotmail dot de 2015-03-13 16:34 ` bernd.edlinger at hotmail dot de [this message] 2015-03-14 3:36 ` bernd.edlinger at hotmail dot de 2015-03-16 20:32 ` bernd.edlinger at hotmail dot de 2015-03-18 17:55 ` jakub at gcc dot gnu.org 2015-03-18 20:06 ` bernd.edlinger at hotmail dot de 2015-03-19 7:54 ` jakub at gcc dot gnu.org 2015-03-19 10:27 ` [Bug sanitizer/65400] [5 Regression] " jakub at gcc dot gnu.org 2015-03-19 10:34 ` jakub 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-65400-4-HekAbX0nUD@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).