From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13876 invoked by alias); 21 Nov 2013 11:05:18 -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 13848 invoked by uid 89); 21 Nov 2013 11:05:18 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=0.1 required=5.0 tests=AWL,BAYES_50,RDNS_NONE,SPF_PASS autolearn=no version=3.3.2 X-HELO: arjuna.pair.com Received: from Unknown (HELO arjuna.pair.com) (209.68.5.131) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with SMTP; Thu, 21 Nov 2013 11:05:16 +0000 Received: (qmail 44456 invoked by uid 3006); 21 Nov 2013 11:05:08 -0000 Received: from localhost (sendmail-bs@127.0.0.1) by localhost with SMTP; 21 Nov 2013 11:05:08 -0000 Date: Thu, 21 Nov 2013 13:19:00 -0000 From: Hans-Peter Nilsson To: "Joseph S. Myers" cc: gcc-patches@gcc.gnu.org, amacleod@redhat.com Subject: Re: Implement C11 _Atomic In-Reply-To: Message-ID: References: User-Agent: Alpine 2.02 (BSF 1266 2009-07-14) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-IsSubscribed: yes X-SW-Source: 2013-11/txt/msg02692.txt.bz2 On Tue, 5 Nov 2013, Joseph S. Myers wrote: Thanks for doing this! However, without examples I have trouble reading out the bits I need as a target maintainer, and I can't read out the answers from the patch, so pardon a few questions. > This patch, relative to trunk and based on work done on the C11-atomic > branch, adds support for C11 _Atomic. It is intended to include all > the required language support. > > It does not include the header; there's a version on the > branch, but it needs further review against the standard and test > coverage adding to the testsuite before I can propose it for mainline. > > Support for atomic types having bigger alignment than the > corresponding non-atomic types is limited: it includes the code to > increase the alignment of types whose size is exactly 1, 2, 4, 8 or 16 > to that of the corresponding integer type [*], but not anything for > target-specific alignment increases. Target-maintainer perspective here: do I read that correctly, that by default adding _Atomic raises the alignment of that type to the "natural" one, for all targets? To wit, > There's code for target-specific > alignment on the branch (and I intend to merge trunk back to the > branch once this patch is on trunk, so it's easy to tell what the > changes still left on the branch are), should any target maintainers > wish to have such alignment. ...is that part needed for alignment that is only target-specific and other-than-natural? For example, 8-byte aligment where required for atomic 4-byte types? Or is that part also required for anything-other-than-ordinary-C-type alignment for the target; say, natural 4-byte alignment of 4-byte-types for targets where alignment is otherwise "packed"; where only 1-byte alignment of the basic type is ABI-mandated? brgds, H-P