From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id pzegAACajWEhRgAAWB0awg (envelope-from ) for ; Thu, 11 Nov 2021 17:32:32 -0500 Received: by simark.ca (Postfix, from userid 112) id E6C2F1F0BD; Thu, 11 Nov 2021 17:32:31 -0500 (EST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-3.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,NICE_REPLY_A,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.2 Received: from sourceware.org (server2.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 63A1D1ECEB for ; Thu, 11 Nov 2021 17:32:31 -0500 (EST) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id DFCB73857823 for ; Thu, 11 Nov 2021 22:32:30 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org DFCB73857823 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1636669950; bh=/9f3bJo89BZk0SiIMpLB+NP50IGw8HUF7epizwoPthA=; h=Subject:To:References:Date:In-Reply-To:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=KZlw9hUadyHsnc6GVvgu0QAlUzwI1PFIB4Uu+UG0uRh0xggPOJRd87XmB84HjUDYi e97nAsDnsTxg4JE5cEvod/UbaQBf84LB03255TvAjS7Sj8XuTfO6BGim/kMn23jq8d OEMTgf9mtlfEo/PLD3SLuJVQcG0y/jOkA0JKtwXo= Received: from mail-vk1-xa29.google.com (mail-vk1-xa29.google.com [IPv6:2607:f8b0:4864:20::a29]) by sourceware.org (Postfix) with ESMTPS id 19F03385840E for ; Thu, 11 Nov 2021 22:32:08 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 19F03385840E Received: by mail-vk1-xa29.google.com with SMTP id n201so4108768vkn.12 for ; Thu, 11 Nov 2021 14:32:08 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=/9f3bJo89BZk0SiIMpLB+NP50IGw8HUF7epizwoPthA=; b=Ds+aI1xRpJLTyZ6jbrKJ7+7eQyYkomcaUZO4tkbu9JjksLgCTDNUIYSmG4GxTK7Max 9NtSzPSDOn7h9HXGAmgH5WF284wNSYmw9JDfSas7nVkBuEIh4eLqCcPouxr1XKBru5zk /g09PTijeVd7O9NRNyVYcVUBkhR4O/DQCjiF9FYO70/v1VparP6nLUs0K7ZtU3T9tmVB Ip3qKrWOjiN6qaQafhWsO9iuv9fpnsCwjxdbWgwgDmdYMBuprREh1ONHFJ5Rx9ryZV9E FlmbYJwrb/o+A7o64T66wBo3Wt3xoczh7VIc7qr7RZDHFdoiPJdgObvLiMlMJypiDo3v XmEA== X-Gm-Message-State: AOAM531HtW4bYjXXSOSX2V0GSyUgWhyfrDFiZyW9ETRGKY4QDSGF4wMu uWjcpMaVMGeOXJduPtewQ7o5IyvqPC2Jww== X-Google-Smtp-Source: ABdhPJyLnEjx8IYHUfXZNc8lG3qwFLoAYNl0EkFplJyOG/4BUcPBEC0QDk6/c9cy18pT57tITEKbLA== X-Received: by 2002:a1f:c341:: with SMTP id t62mr16478301vkf.12.1636669927398; Thu, 11 Nov 2021 14:32:07 -0800 (PST) Received: from ?IPv6:2804:7f0:4841:487c:f853:f29d:cfe6:370b? ([2804:7f0:4841:487c:f853:f29d:cfe6:370b]) by smtp.gmail.com with ESMTPSA id m186sm2977220vsm.11.2021.11.11.14.32.06 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 11 Nov 2021 14:32:06 -0800 (PST) Subject: Re: [PATCH 1/6] sim: sh: rework register layout with anonymous unions & structs To: gdb-patches@sourceware.org References: <20211107003254.4298-1-vapier@gentoo.org> <68a4c7ee-700a-22f5-62ad-9257de03e9f9@linaro.org> Message-ID: Date: Thu, 11 Nov 2021 19:32:04 -0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.13.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit 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: Luis Machado via Gdb-patches Reply-To: Luis Machado Errors-To: gdb-patches-bounces+public-inbox=simark.ca@sourceware.org Sender: "Gdb-patches" On 11/11/21 7:25 PM, Mike Frysinger wrote: > On 11 Nov 2021 09:41, Luis Machado wrote: >> I can't pinpoint the exact SH patch, but builds are broken for >> --enable-targets=all in Ubuntu 18.04 with GCC 7.5: > > pretty sure the warnings have always been there for you, we just turned > -Werror in more cases recently > That's fine and I'm all for more -Werror. But builds should be able to complete regardless, right? >> binutils-gdb/sim/sh/interp.c: In function ‘ppi_insn’: >> ./ppi.c:875:21: error: assuming signed overflow does not occur when >> assuming that (X + c) < X is always false [-Werror=strict-overflow] >> carry = res < Sy; >> ~~~~^~~~ >> ./ppi.c:849:21: error: assuming signed overflow does not occur when >> assuming that (X - c) > X is always false [-Werror=strict-overflow] >> carry = res > Sy; >> ~~~~^~~~ >> ./ppi.c:823:21: error: assuming signed overflow does not occur when >> assuming that (X + c) < X is always false [-Werror=strict-overflow] >> carry = res < Sx; >> ~~~~^~~~ >> ./ppi.c:797:21: error: assuming signed overflow does not occur when >> assuming that (X - c) > X is always false [-Werror=strict-overflow] >> carry = res > Sx; >> ~~~~^~~~ >> binutils-gdb-arm64-bionic/sim/../../../repos/binutils-gdb/sim/sh/interp.c: >> In function ‘sim_resume’: >> ./ppi.c:1178:28: warning: ‘res’ may be used uninitialized in this >> function [-Wmaybe-uninitialized] >> MACL = DSP_R (z) = res; >> ./ppi.c:44:7: note: ‘res’ was declared here >> int res, res_grd; >> ^~~ > > how exactly are you building things ? we don't enable -Wstrict-overflow. No special way. I just ./configure with --enable-targets=all and let it run. I can bisect it or gather a bit more information if you think it would be useful. Worth mentioning that it doesn't run into such warnings/failures on Ubuntu 20.04 with gcc 9.3.