From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 50330 invoked by alias); 16 Jun 2015 11:28:06 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 50318 invoked by uid 89); 16 Jun 2015 11:28:05 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.6 required=5.0 tests=AWL,BAYES_00,SPF_PASS autolearn=ham version=3.3.2 X-HELO: eu-smtp-delivery-143.mimecast.com Received: from eu-smtp-delivery-143.mimecast.com (HELO eu-smtp-delivery-143.mimecast.com) (207.82.80.143) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 16 Jun 2015 11:28:04 +0000 Received: from cam-owa2.Emea.Arm.com (fw-tnat.cambridge.arm.com [217.140.96.140]) by uk-mta-30.uk.mimecast.lan; Tue, 16 Jun 2015 12:28:01 +0100 Received: from localhost ([10.1.2.79]) by cam-owa2.Emea.Arm.com with Microsoft SMTPSVC(6.0.3790.3959); Tue, 16 Jun 2015 12:28:01 +0100 From: Richard Sandiford To: Eric Botcazou Mail-Followup-To: Eric Botcazou ,gcc-patches@gcc.gnu.org, richard.sandiford@arm.com Cc: gcc-patches@gcc.gnu.org Subject: Re: [patch 2/6] scalar-storage-order merge: C front-end References: <3247494.5bgQPARZRk@polaris> <2396877.AqT21tpnmO@polaris> Date: Tue, 16 Jun 2015 11:39:00 -0000 In-Reply-To: <2396877.AqT21tpnmO@polaris> (Eric Botcazou's message of "Tue, 16 Jun 2015 10:54:59 +0200") Message-ID: <87mvzzzyda.fsf@e105548-lin.cambridge.arm.com> User-Agent: Gnus/5.130012 (Ma Gnus v0.12) Emacs/24.3 (gnu/linux) MIME-Version: 1.0 X-MC-Unique: 1uorWef8S1Sdy95j-MT53w-1 Content-Type: text/plain; charset=WINDOWS-1252 Content-Transfer-Encoding: quoted-printable X-SW-Source: 2015-06/txt/msg01111.txt.bz2 Eric Botcazou writes: > This is the C front-end + C family part. > > * doc/extend.texi (type attributes): Document scalar_storage_order. > * doc/invoke.texi (Warnings): Document -Wno-scalar-storage-order. > c-family/ > * c-common.c (c_common_attributes): Add scalar_storage_order. > (handle_scalar_storage_order_attribute): New function. > * c.opt (Wscalar-storage-order): New warning. > c/ > * c-decl.c (finish_struct): If the structure has reverse scalar storage > order, rewrite the type of array fields with scalar component. > * c-typeck.c (build_unary_op) : Remove left-overs. Issue > errors on bit-fields and reverse SSO here and not... > (c_mark_addressable): ...here. > > doc/extend.texi | 47 +++++++++++++++++++++++++++++++++++++++++++++ > doc/invoke.texi | 6 +++++ > c-family/c.opt | 4 +++ > c-family/c-common.c | 54 +++++++++++++++++++++++++++++++++++++++++++++= ++++- > c/c-typeck.c | 53 +++++++++++++++++++++++++++++++--------------= ----- > c/c-decl.c | 45 +++++++++++++++++++++++++++++-------------- > 6 files changed, 175 insertions(+), 34 deletions(-) Sorry for the nit, but: > +@itemize > +@item Taking the address of a scalar field of a @code{union} or a > +@code{struct} with reverse scalar storage order is illegal and will > +yield an error > +@item Taking the address of an array field, whose component is scalar, of > +a @code{union} or a @code{struct} with reverse scalar storage order is > +permitted but will yield a warning, unless @option{-Wno-scalar-storage-o= rder} > +is specified > +@item Taking the address of a @code{union} or a @code{struct} with rever= se > +scalar storage order is permitted > +@end itemize "illegal" -> "invalid" or "not permitted" Thanks, Richard