From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id BZ0rCel42WJSHhgAWB0awg (envelope-from ) for ; Thu, 21 Jul 2022 12:03:53 -0400 Received: by simark.ca (Postfix, from userid 112) id 16EAC1E5EA; Thu, 21 Jul 2022 12:03:53 -0400 (EDT) Authentication-Results: simark.ca; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.a=rsa-sha256 header.s=default header.b=PzOJ18n3; dkim-atps=neutral X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RDNS_DYNAMIC,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 Received: from sourceware.org (ip-8-43-85-97.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id BCF361E21F for ; Thu, 21 Jul 2022 12:03:52 -0400 (EDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id E33933857429 for ; Thu, 21 Jul 2022 16:03:51 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org E33933857429 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1658419431; bh=nDc505U4DQG3U06FI4li0KPbixzwxmBrA3PQIxyG0YM=; h=Date:To:In-Reply-To:Subject:References:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=PzOJ18n3f+R6c+yjNHKJ+fayls7/dyni0gdKv2quuEOtp04rVWNrOUB30p8yA6MQO pYzx49/q7FqFKQM497PJcBg60dlvM8xY180NE4frRw1jCcHl7v2Dtc3zb3lYEQZLgN ypSGiG+Hf2ZkexYkBckES/ZKojJjp+5iE9dZB9tA= Received: from eggs.gnu.org (eggs.gnu.org [209.51.188.92]) by sourceware.org (Postfix) with ESMTPS id 1F0BC3858C56 for ; Thu, 21 Jul 2022 16:03:24 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 1F0BC3858C56 Received: from fencepost.gnu.org ([2001:470:142:3::e]:54192) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oEYe3-0008G3-IF; Thu, 21 Jul 2022 12:03:23 -0400 Received: from [87.69.77.57] (port=3967 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oEYe2-0006l3-Ra; Thu, 21 Jul 2022 12:03:23 -0400 Date: Thu, 21 Jul 2022 19:03:14 +0300 Message-Id: <83h73amp19.fsf@gnu.org> To: Pedro Alves In-Reply-To: <20220721152132.3489524-2-pedro@palves.net> (message from Pedro Alves on Thu, 21 Jul 2022 16:21:30 +0100) Subject: Re: [PATCH 1/3] struct packed: Use gcc_struct on Windows References: <20220721152132.3489524-1-pedro@palves.net> <20220721152132.3489524-2-pedro@palves.net> X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Eli Zaretskii via Gdb-patches Reply-To: Eli Zaretskii Cc: gdb-patches@sourceware.org Errors-To: gdb-patches-bounces+public-inbox=simark.ca@sourceware.org Sender: "Gdb-patches" > From: Pedro Alves > Date: Thu, 21 Jul 2022 16:21:30 +0100 > > The issue is that mingw gcc defaults to "-mms-bitfields", which > affects how bitfields are laid out. We can however tell GCC that we > want the regular GCC layout instead using attribute gcc_struct. Is that a good idea? It means the code emitted by GCC for this source file will be incompatible with any other library compiled with MinGW that GDB uses. So we are risking ABI incompatibilities here. Right? Can you tell why we must have the regular GCC layout of bitfields here? Thanks.