public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Richard Henderson <rth@redhat.com>
To: DJ Delorie <dj@redhat.com>
Cc: Mark Mitchell <mark@codesourcery.com>,
	joseph@codesourcery.com,        gcc-patches@gcc.gnu.org
Subject: Re: patch: honor volatile bitfield types
Date: Tue, 15 Jun 2010 17:53:00 -0000	[thread overview]
Message-ID: <4C17ADA2.2050809@redhat.com> (raw)
In-Reply-To: <201006150120.o5F1K5wj024499@greed.delorie.com>

On 06/14/2010 06:20 PM, DJ Delorie wrote:
>> And, the field name should definitely be mentioned if at all
>> possible.
> 
> Sigh, not possible without major code changes.  This is the problem I
> ran into writing the patch itself - the decls are all long since lost
> by the time we get to these routines, and some of the paths that lead
> to them make it very difficult to keep track of them (if they're
> available at all).
> 
> How's this for the message?
> 
> 
> 	      if (bitsize == total_bits)
> 		warning (0, "mis-aligned access used for structure member");
> 	      else
> 		warning (0, "mis-aligned access used for structure bitfield");
> 
> 	      if (! warned_about_misalignment)
> 		{
> 		  warned_about_misalignment = true;
> 		  warning (0, "volatile objects require a single access to preserve their"
> 			   " volatility, but this member spans multiple type-sized locations."
> 			   " Normally the compiler would use multiple accesses for such fields"
> 			   " to avoid mis-aligned accesses.  This code may fail at runtime")
> 		}

Is this second message more approriate to "info" than "warning"?


r~

  parent reply	other threads:[~2010-06-15 17:35 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-06-11  4:42 DJ Delorie
2010-06-11  9:55 ` Joseph S. Myers
2010-06-11 14:42   ` DJ Delorie
2010-06-11 16:42     ` Mark Mitchell
2010-06-11 16:56       ` Jeff Law
2010-06-11 23:23       ` DJ Delorie
2010-06-12  2:28         ` Mark Mitchell
2010-06-12  3:45           ` DJ Delorie
2010-06-12  4:12             ` Mark Mitchell
2010-06-12 10:17             ` Richard Guenther
2010-06-15  2:40           ` DJ Delorie
2010-06-15  3:01             ` Mark Mitchell
2010-06-15  5:16               ` DJ Delorie
2010-06-15  6:00                 ` Mark Mitchell
2010-06-15 22:29               ` DJ Delorie
2010-06-15 22:45                 ` Manuel López-Ibáñez
2010-06-15 22:55                   ` DJ Delorie
2010-06-15 23:02                     ` Mark Mitchell
2010-06-17  7:58                       ` DJ Delorie
2010-06-22 10:42                         ` Eric Botcazou
2010-06-22 18:32                           ` DJ Delorie
2010-06-22 18:39                             ` Eric Botcazou
2010-06-22 18:57                               ` DJ Delorie
2010-06-22 20:04                                 ` Eric Botcazou
2010-06-23  0:51                                   ` DJ Delorie
2010-09-03 18:41                         ` Jie Zhang
2010-06-15 23:03                     ` Manuel López-Ibáñez
2010-06-16  0:43                       ` DJ Delorie
2010-06-16  4:23                         ` Mark Mitchell
2010-06-15 22:55                   ` DJ Delorie
2010-06-15  8:32             ` Manuel López-Ibáñez
2010-06-15 17:53             ` Richard Henderson [this message]
2010-06-15 17:26               ` DJ Delorie
2010-06-15 17:35                 ` Manuel López-Ibáñez
2010-06-15 19:20                 ` Richard Henderson
2010-06-15 19:27                   ` Manuel López-Ibáñez

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=4C17ADA2.2050809@redhat.com \
    --to=rth@redhat.com \
    --cc=dj@redhat.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=joseph@codesourcery.com \
    --cc=mark@codesourcery.com \
    /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).