linux-xfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@infradead.org>
To: Dave Chinner <david@fromorbit.com>
Cc: Eric Sandeen <sandeen@sandeen.net>, linux-xfs@vger.kernel.org
Subject: Re: [PATCH 0/4 V2] Remove a few macros
Date: Thu, 31 May 2018 22:25:39 -0700	[thread overview]
Message-ID: <20180601052539.GA23957@infradead.org> (raw)
In-Reply-To: <20180531231153.GO10363@dastard>

On Fri, Jun 01, 2018 at 09:11:53AM +1000, Dave Chinner wrote:
> 
> What was there to argue? Christoph wants us to rely on undocumented,
> compiler specific behaviour(*),

It is not undocumented.  Sections like this have been part of the
gcc manual for at least 25 years:

https://gcc.gnu.org/onlinedocs/gcc/Pointer-Arith.html

> I want it the pointer arithmetic to
> be explicitly correct with a cast.
> 
> Maintainer's choice, really.
> 
> Cheers,
> 
> Dave.
> 
> (*) It's been repeatedly demonstrated that the gcc developers don't
> care if they break code that relies on undefined behaviour in the C
> standard.

But this behavior is not undefined.  It is explicitly defined for gcc,
with other compilers (LLVM, icc) following that specification.

  parent reply	other threads:[~2018-06-01  5:25 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-03-07  9:05 [PATCH 0/4 V2] Remove a few macros Carlos Maiolino
2018-03-07  9:05 ` [PATCH 1/4] Get rid of XFS_BUF_PTR() macro Carlos Maiolino
2018-03-07  9:05 ` [PATCH 2/4] Get rid of XFS_BUF_TARGET() macro Carlos Maiolino
2018-03-07  9:05 ` [PATCH 3/4] get rid of XFS_BUF_COUNT() macro Carlos Maiolino
2018-03-07  9:05 ` [PATCH 4/4] Get rid of XFS_BUF_SET_COUNT() macro Carlos Maiolino
2018-05-31 16:58 ` [PATCH 0/4 V2] Remove a few macros Eric Sandeen
2018-05-31 17:19   ` Carlos Maiolino
2018-05-31 23:11     ` Dave Chinner
2018-05-31 23:22       ` Darrick J. Wong
2018-06-01  5:25       ` Christoph Hellwig [this message]
2018-07-24  0:06 ` Eric Sandeen

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=20180601052539.GA23957@infradead.org \
    --to=hch@infradead.org \
    --cc=david@fromorbit.com \
    --cc=linux-xfs@vger.kernel.org \
    --cc=sandeen@sandeen.net \
    /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 NNTP newsgroup(s).