From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pj1-x1034.google.com (mail-pj1-x1034.google.com [IPv6:2607:f8b0:4864:20::1034]) by sourceware.org (Postfix) with ESMTPS id 72B0B385841C for ; Fri, 3 Feb 2023 15:56:49 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 72B0B385841C Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-pj1-x1034.google.com with SMTP id o13so5442364pjg.2 for ; Fri, 03 Feb 2023 07:56:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=vZGS0Zz0a/EFxeVlgd7ax/EVBemNh9/LzcKNTsUe1pY=; b=VZixMfqkoc2o2KmHTEHh0UU2D6UUWnsZ3x0GxNXyY7xKNszyvVxbOkdSi+dYht+g2E sDhnV+AwbGWfstry+Io9vw5gGYBxmL0L7iuaXNBqVAmG8fMIP8/QALSVfnXYs0/WhFjs 9pHQBQOs3rp8mt0xQ/NAdlHL/teAVsY5/CpBaWklfle3ey5R/nbX5WCq39aM5Va5cG+l yOxsiE41halbdCWNWOz+Ggi/UwPuJyUDL6mBRHi4fa8GY/Ywfn1J6a3swFDGNjvShew0 H3aO6gbMhm/WYCyjLxJXTxUlcYWomPWH2ZikM+qbqJj03a6knLnnEgL4XqQqKYLO80Bz YaBw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=vZGS0Zz0a/EFxeVlgd7ax/EVBemNh9/LzcKNTsUe1pY=; b=cmuFZonVhMl2StpnxMcyZ0nWPzzn0Q2LdDylaBaIGL46GAKDMYG/OEk/fso+Sv3MDg 6PZpOOg+7/vaSSGMcMg25L9eO9P6qVFkXWdYMo/8SIswxj8XlmsOcaAl5I9iJuAKLCk+ BEWb7R4d04DfnMdhCwI0HkC/GeZDQOnt2H3ypROWh+7eZN3/xUfAJS885e6uP70eM5i+ ZEK7MUZXdrNyvKQu9907P9SYK+hZwZn0EcTIM9LipZKa2O0VVwkVSvYV9FpJ3mn7+Tgs IUmEn5rhW1RMiUuzl0zU7Hgc3ncUaQZmkmYzenx7zU4UbnPEHewd56jyc6S8l/xEYqwg qq9Q== X-Gm-Message-State: AO0yUKXBrn9IwSmb6DNT9iIyq5EIP4gXc1Jzrb9I2j6bv5O4TJPGltOe FG2cNHqJtdd+mihxbN0A8QVLpd/TY5U= X-Google-Smtp-Source: AK7set/VGxZrNdKCqfot7seyDDT8xrKeTrKJPZ4+ajPJTZfzLnEidm3HqcoSuZsMyKWgFMnJsVz6aA== X-Received: by 2002:a17:903:2310:b0:196:13cd:a49 with SMTP id d16-20020a170903231000b0019613cd0a49mr13133847plh.27.1675439807571; Fri, 03 Feb 2023 07:56:47 -0800 (PST) Received: from ?IPV6:2601:681:8600:13d0::f0a? ([2601:681:8600:13d0::f0a]) by smtp.gmail.com with ESMTPSA id b5-20020a170902d30500b0018911ae9dfasm1770944plc.232.2023.02.03.07.56.46 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 03 Feb 2023 07:56:47 -0800 (PST) Message-ID: <16691824-7348-53b7-0f85-1dabd7a1a924@gmail.com> Date: Fri, 3 Feb 2023 08:56:45 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.6.0 Subject: Re: [PATCH 2/2] Documentation Update. Content-Language: en-US To: gcc-patches@gcc.gnu.org References: <20230131141140.3610133-1-qing.zhao@oracle.com> <20230131141140.3610133-3-qing.zhao@oracle.com> <1AB22124-10D2-416D-B1BD-D4FF728AB0E2@oracle.com> <6832ED41-E086-49E0-8BD2-51387710DECD@oracle.com> <63dbed50.a70a0220.3e5e5.24a2@mx.google.com> From: Jeff Law In-Reply-To: <63dbed50.a70a0220.3e5e5.24a2@mx.google.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.4 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On 2/2/23 10:05, Kees Cook via Gcc-patches wrote: > > Right -- this can lead (at least) to type confusion and other problems > too. We've been trying to remove all of these overlaps in the Linux > kernel. I mention it the "Overlapping composite structure members" > section at https://people.kernel.org/kees/bounded-flexible-arrays-in-c Good. We found several of these when Martin S was doing his work on the diagnostics a few years back. It wasn't hard to see what the intent was, but it struck me as a poor (ab)use of the feature and that I wouldn't be surprised if compilers might differ in their semantics around this stuff. jeff