public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "rogerio.souza at gmail dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/106238] Inline optimization causes dangling pointer on "include/c++/12.1.0/bits/stl_tree.h" Date: Mon, 11 Jul 2022 17:26:12 +0000 [thread overview] Message-ID: <bug-106238-4-4b3b1FiruR@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-106238-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106238 --- Comment #4 from Rogério de Souza Moraes <rogerio.souza at gmail dot com> --- Hi Andrew, thank you for the quick reply. The "getLocalCopy" on this example is just to provide a quick way to reproduce the issue. Here is the getLocalCopy function of this example. extern void getLocalCopy(std::map<int*, sysDLoc>&); I added the file bug2.cpp which is another way to reproduce the issue. The issue only happens when the compiler uses inline, which triggers the error on "stl_tree.h:2090:32". I could not find any condition that would consider the example codes as invalid or that leads to "undefined behavior", do you see any? Considering that this warning only happens on GCC 12.1, the testcases are valid wouldn´t it be an issue on this compiler version? Wouldn´t it require a fix on "stl_tree.h" to prevent this warning? Regards, Rogerio
next prev parent reply other threads:[~2022-07-11 17:26 UTC|newest] Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top 2022-07-08 21:32 [Bug libstdc++/106238] New: " rogerio.souza at gmail dot com 2022-07-08 21:45 ` [Bug tree-optimization/106238] " pinskia at gcc dot gnu.org 2022-07-11 16:23 ` rogerio.souza at gmail dot com 2022-07-11 17:16 ` rogerio.souza at gmail dot com 2022-07-11 17:26 ` rogerio.souza at gmail dot com [this message] 2023-01-08 15:45 ` romain.geissler at amadeus dot com 2023-03-14 18:56 ` romain.geissler at amadeus dot com 2023-03-14 20:46 ` romain.geissler at amadeus dot com 2023-03-14 22:34 ` [Bug tree-optimization/106238] [12/13 regression] Inline optimization causes dangling pointer warning " jason at gcc dot gnu.org 2023-05-08 12:25 ` [Bug tree-optimization/106238] [12/13/14 " rguenth at gcc dot gnu.org 2023-08-15 22:58 ` romain.geissler at amadeus dot com 2024-03-15 1:19 ` [Bug tree-optimization/106238] [12 " law 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-106238-4-4b3b1FiruR@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).