public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "msebor at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/102329] pointer "maybe uninitialized" right after assignment
Date: Wed, 15 Sep 2021 15:44:58 +0000	[thread overview]
Message-ID: <bug-102329-4-VUld7MVgjM@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-102329-4@http.gcc.gnu.org/bugzilla/>

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102329

--- Comment #4 from Martin Sebor <msebor at gcc dot gnu.org> ---
The text of the warning should be adjusted to make it clear that it's the
object the pointer points to that may be used uninitialized by the function. 
For functions like pthread_getspecific() and pthread_setspecific() that do not
access the object GCC provides attribute access none to suppress the warning:

  extern __attribute__ ((access (none, 1))) void f1 (const void *pointer);

  parent reply	other threads:[~2021-09-15 15:44 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-14 16:49 [Bug c/102329] New: " hv at crypt dot org
2021-09-14 16:56 ` [Bug c/102329] " jakub at gcc dot gnu.org
2021-09-15  3:50 ` [Bug tree-optimization/102329] " hv at crypt dot org
2021-09-15  7:55 ` rguenth at gcc dot gnu.org
2021-09-15 15:44 ` msebor at gcc dot gnu.org [this message]
2021-09-17 11:41 ` hv at crypt dot org
2021-09-20 14:56 ` msebor at gcc dot gnu.org
2021-10-18 13:51 ` fw at gcc dot gnu.org
2021-10-18 21:10 ` [Bug tree-optimization/102329] [11/12 Regression] " pinskia at gcc dot gnu.org
2022-01-20 10:00 ` rguenth at gcc dot gnu.org
2022-04-21  7:50 ` rguenth at gcc dot gnu.org
2023-05-29 10:05 ` [Bug tree-optimization/102329] [11/12/13/14 " 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-102329-4-VUld7MVgjM@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: link
Be 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).