public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
* [Bug middle-end/89543] Don't modify TREE_NO_WARNING during folding in place [not found] <bug-89543-4@http.gcc.gnu.org/bugzilla/> @ 2021-12-24 21:38 ` pinskia at gcc dot gnu.org 2021-12-24 21:48 ` pinskia at gcc dot gnu.org ` (4 subsequent siblings) 5 siblings, 0 replies; 6+ messages in thread From: pinskia at gcc dot gnu.org @ 2021-12-24 21:38 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89543 Andrew Pinski <pinskia at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Last reconfirmed| |2021-12-24 Ever confirmed|0 |1 Target Milestone|--- |12.0 --- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> --- Fixed for GCC 12 by r12-1805-ge9e2bad7251477 which removes all uses of TREE_NO_WARNING from fold-const.c and builtin* and move over to location based warning supression system. Except the usage in fold_checksum_tree was moved over too incorrectly and should have been removed instead. ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug middle-end/89543] Don't modify TREE_NO_WARNING during folding in place [not found] <bug-89543-4@http.gcc.gnu.org/bugzilla/> 2021-12-24 21:38 ` [Bug middle-end/89543] Don't modify TREE_NO_WARNING during folding in place pinskia at gcc dot gnu.org @ 2021-12-24 21:48 ` pinskia at gcc dot gnu.org 2021-12-25 17:33 ` pinskia at gcc dot gnu.org ` (3 subsequent siblings) 5 siblings, 0 replies; 6+ messages in thread From: pinskia at gcc dot gnu.org @ 2021-12-24 21:48 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89543 Andrew Pinski <pinskia at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|unassigned at gcc dot gnu.org |pinskia at gcc dot gnu.org Status|NEW |ASSIGNED --- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> --- Testing the obvious patch to remove the special handling in fold_checksum_tree. ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug middle-end/89543] Don't modify TREE_NO_WARNING during folding in place [not found] <bug-89543-4@http.gcc.gnu.org/bugzilla/> 2021-12-24 21:38 ` [Bug middle-end/89543] Don't modify TREE_NO_WARNING during folding in place pinskia at gcc dot gnu.org 2021-12-24 21:48 ` pinskia at gcc dot gnu.org @ 2021-12-25 17:33 ` pinskia at gcc dot gnu.org 2021-12-25 21:24 ` pinskia at gcc dot gnu.org ` (2 subsequent siblings) 5 siblings, 0 replies; 6+ messages in thread From: pinskia at gcc dot gnu.org @ 2021-12-25 17:33 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89543 Andrew Pinski <pinskia at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Target Milestone|12.0 |--- --- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> --- FAIL: c-c++-common/Warray-bounds-7.c -Wc++-compat (internal compiler error: fold check: original tree changed by fold) Looks like there are a few left. ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug middle-end/89543] Don't modify TREE_NO_WARNING during folding in place [not found] <bug-89543-4@http.gcc.gnu.org/bugzilla/> ` (2 preceding siblings ...) 2021-12-25 17:33 ` pinskia at gcc dot gnu.org @ 2021-12-25 21:24 ` pinskia at gcc dot gnu.org 2021-12-25 21:45 ` pinskia at gcc dot gnu.org 2021-12-25 21:52 ` pinskia at gcc dot gnu.org 5 siblings, 0 replies; 6+ messages in thread From: pinskia at gcc dot gnu.org @ 2021-12-25 21:24 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89543 --- Comment #4 from Andrew Pinski <pinskia at gcc dot gnu.org> --- [apinski@xeond2 upstream-gcc-git]$ gdb --args ./gcc/objdir/stage1-gcc/cc1 /home/apinski/src/upstream-gcc-git/gcc/gcc/testsuite/gcc.dg/Wstringop-overread-6.c .... (gdb) p debug_generic_expr(expr) strlen ((const char *) &arr + 4) ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug middle-end/89543] Don't modify TREE_NO_WARNING during folding in place [not found] <bug-89543-4@http.gcc.gnu.org/bugzilla/> ` (3 preceding siblings ...) 2021-12-25 21:24 ` pinskia at gcc dot gnu.org @ 2021-12-25 21:45 ` pinskia at gcc dot gnu.org 2021-12-25 21:52 ` pinskia at gcc dot gnu.org 5 siblings, 0 replies; 6+ messages in thread From: pinskia at gcc dot gnu.org @ 2021-12-25 21:45 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89543 --- Comment #5 from Andrew Pinski <pinskia at gcc dot gnu.org> --- (In reply to Andrew Pinski from comment #4) > [apinski@xeond2 upstream-gcc-git]$ gdb --args ./gcc/objdir/stage1-gcc/cc1 > /home/apinski/src/upstream-gcc-git/gcc/gcc/testsuite/gcc.dg/Wstringop- > overread-6.c > > .... > (gdb) p debug_generic_expr(expr) > strlen ((const char *) &arr + 4) Here is the reduced testcase: const char arr[7] = "abc\0def"; int warn_strlen (void) { return __builtin_strlen (arr+4); } ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug middle-end/89543] Don't modify TREE_NO_WARNING during folding in place [not found] <bug-89543-4@http.gcc.gnu.org/bugzilla/> ` (4 preceding siblings ...) 2021-12-25 21:45 ` pinskia at gcc dot gnu.org @ 2021-12-25 21:52 ` pinskia at gcc dot gnu.org 5 siblings, 0 replies; 6+ messages in thread From: pinskia at gcc dot gnu.org @ 2021-12-25 21:52 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89543 Andrew Pinski <pinskia at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |NEW --- Comment #6 from Andrew Pinski <pinskia at gcc dot gnu.org> --- (In reply to Andrew Pinski from comment #5) > (In reply to Andrew Pinski from comment #4) > > [apinski@xeond2 upstream-gcc-git]$ gdb --args ./gcc/objdir/stage1-gcc/cc1 > > /home/apinski/src/upstream-gcc-git/gcc/gcc/testsuite/gcc.dg/Wstringop- > > overread-6.c > > > > .... > > (gdb) p debug_generic_expr(expr) > > strlen ((const char *) &arr + 4) > > Here is the reduced testcase: > const char arr[7] = "abc\0def"; > int warn_strlen (void) > { > return __builtin_strlen (arr+4); > } fold_builtin_strlen->warn_string_no_nul->suppress_warning->set_no_warning_bit (expr, supp); Which then sets the bit. No longer working on this. But at least I recorded where one of the TREE_NO_WARNING flag is set these days. ^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2021-12-25 21:52 UTC | newest] Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- [not found] <bug-89543-4@http.gcc.gnu.org/bugzilla/> 2021-12-24 21:38 ` [Bug middle-end/89543] Don't modify TREE_NO_WARNING during folding in place pinskia at gcc dot gnu.org 2021-12-24 21:48 ` pinskia at gcc dot gnu.org 2021-12-25 17:33 ` pinskia at gcc dot gnu.org 2021-12-25 21:24 ` pinskia at gcc dot gnu.org 2021-12-25 21:45 ` pinskia at gcc dot gnu.org 2021-12-25 21:52 ` pinskia at gcc dot gnu.org
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).