From nobody Mon Nov 23 04:29:58 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1793142552; cv=none; d=zohomail.com; s=zohoarc; b=f/+lvEg3mGflhXxtc+VKh44E2yB35Za+7cRTSf0kLYEew+YiAuRPemtr+GfjU7ra8LqZWUDpf841Z/Yu432Yu0lYMVck4iNwFasDxDB4WhaTP5m4Cz1DPwmV/2H1H0VIEJ4rtrbvspQyxZNOmKWAX8o26j+TeR0TiF0/o3iGyCk= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1793142552; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=IJIhwwAJ5SzGlSqwxPayI3RZ8IqvJdbV9eWM1K61wVI=; b=gFSTBU/N52M0ygto3F+HeLIyX74SQc7QZvZ0odvDF2vGx9jaeWETXlKhA93NHT2HQfXMy67SMLLt4OnJv6qdZdTHWQVQrQk/HMmm95WLrxx3slE8DfuqdcDZid9EuJ604Y0OoimHHImgeFZrNck0YNSkEh7nk2tB+SvsilagoPY= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists1p.gnu.org (lists1p.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1793142552949509.74266895911455; Tue, 27 Oct 2026 16:09:12 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists1p.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1xLqHN-0001Gm-Kq; Tue, 27 Oct 2026 19:08:29 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xLqHM-0001Eo-1i for qemu-devel@nongnu.org; Tue, 27 Oct 2026 19:08:28 -0400 Received: from mail-ot1-x333.google.com ([2607:f8b0:4864:20::333]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1xLqHK-0006cC-68 for qemu-devel@nongnu.org; Tue, 27 Oct 2026 19:08:27 -0400 Received: by mail-ot1-x333.google.com with SMTP id 46e09a7af769-8439fe796ebso267458a34.3 for ; Tue, 27 Oct 2026 16:08:25 -0700 (PDT) Received: from stoup ([50.233.235.3]) by smtp.gmail.com with ESMTPSA id 46e09a7af769-850fc002444sm11965882a34.23.2026.10.27.16.08.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 27 Oct 2026 16:08:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1793142504; x=1793747304; darn=nongnu.org; h=content-transfer-encoding:content-type:mime-version:message-id:date :subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to :content-type; bh=IJIhwwAJ5SzGlSqwxPayI3RZ8IqvJdbV9eWM1K61wVI=; b=mK9ME2Hav1g1JmmMQA4KyZcahazzoi9AgC4QnOioJM36wNIAWM7IEAvSakteX00IE2 SW4BFPE4ByimjzVCBB8/JAIVei7rEq2a/wSfuK+KJhkR2X+D2Tf1eyVHzqXn3syX+jOp 9YFKI8v3JHFfyOzHpVCbDuLUoRAL/OLXCjihEFxfQP1uFUeJGdKDEcRajR1Up2494irp eZ0YbureSlOcafLwJTrUDCsxuySLjpr7FWrX24vozV24P0KbIOhIjl+LStTsw5rZy972 Pu/HgP71FoupGn9q9JfSOj/tvCzvkjeDXjc+zDBedTzNnY8EqV/2w6vk2gQVTlxl8nXR 451w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1793142504; x=1793747304; h=content-transfer-encoding:content-type:mime-version:message-id:date :subject:cc:to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject :date:message-id:reply-to:content-type; bh=IJIhwwAJ5SzGlSqwxPayI3RZ8IqvJdbV9eWM1K61wVI=; b=bHznAcsDkUKmwG230HJe9TByWb1PjkPE9OP3VVTjtZfWgBUfFd8HbeNFOdSIUyN30W pIqXn7r/w+l6nLlw/xzScx/K+EVgd5rdkJME7C36KdDYtcoSmoVmNsWuFEMsit9UHt07 254+5E/WRk+F62EewBU7UA3SZeQWtF8Azc2IyxwPsVGEBbQ40Cga2X6SwYFM4VgOWnNC AMk5RtPnAS8CSCY9VQjPxWD/Y+YnW6rTu6OhbClI2a987FveRbEN7/q8myuTHIzKikb8 +4A6HxLe2wXKRqY0sYt2GeND0DDm+KFTlIIPkxsjN1iDPK65RZAQGJel5VugUM9viawb Gq+g== X-Gm-Message-State: AFq9FYISFRMgr2kTjcyOb0FNAQhEUbyxLvxHsEXY8+zvgfpyub7QXhs3 qNx5AebYjjjxXo5XrRuaRvtNuuMPhfsD59vVsLGIF4VFJ7BiGvGI65WuYrKTB747SVTNhYvpPPy frA+V X-Gm-Gg: AYBFou3KhSTYqMwYoOw/yAYp6xYRTOq313ECZZzmG4KSirqmscJvjbedRMXFvjT/slW 0SIQunx3OVcgu0v6HjIEazEMMNQ8nl99KyQmf6h0Q7ZaUE+3qnjWf62GjO7A3GUHpuXkVKcgK8F TWEoq3/nL4u/ayU2PbEb++1d+Bnr+NB46tr8FgT7GhPh9/ESmHZW6RW46ORO6TyxOZuNlPfwEzz QF7xmrGEKXyFAO+2A5U36drRrO4SdG4eYXgqrkJ4m7hTH6OPl0ZjT8aXjqzEvQlXdnZtwwGyljk eQApmqdc3ps1B8QY61+pJWmloqyatvD5MwWv1K0IwbrkkaWm+oBw0thUQyluEMG75dNM64LzNxa DTxhrPuYBmkGIW1aM+P2pIWp6ihRY+wQvqsMvDqpiCgqYTKqd/PNEkMaeOLWreYmakQYqqc5caX 17Q7bK+5DVn1st8of/C3/+gc3lH1t/vIY8qvyYbSsmzq3ORTqhKWMCdCGXpOYEoFaxFtqyfiE+h UP/zxEOewEvWi3KNlcpuUZnGyGpadUWBUcaogiuHuCn1mXrEUu6roSl X-Received: by 2002:a05:6830:8296:b0:85b:c75:dc59 with SMTP id 46e09a7af769-85b0c75e5e8mr117122a34.29.1793142504489; Tue, 27 Oct 2026 16:08:24 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Cc: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Subject: [PATCH] tcg: Adjust NONNULL annotation on *_diff functions Date: Tue, 27 Oct 2026 18:08:16 -0500 Message-ID: <20261027230816.201808-1-richard.henderson@linaro.org> X-Mailer: git-send-email 2.53.0 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists1p.gnu.org; Received-SPF: pass client-ip=2607:f8b0:4864:20::333; envelope-from=richard.henderson@linaro.org; helo=mail-ot1-x333.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: qemu development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1793142555398154100 In tcg/sparc64 we use tcg_tbrel_diff with NULL as a negative addend in a relocation. Fixes: b0b6701a4018 ("tcg: Annotate functions in tcg.h with QEMU_*_NONNULL") Reported-by: Philippe Mathieu-Daud=C3=A9 Signed-off-by: Richard Henderson Reviewed-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Pierrick Bouvier Tested-by: Pierrick Bouvier --- include/tcg/tcg.h | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/include/tcg/tcg.h b/include/tcg/tcg.h index 8f409b23b7..3dc26b919d 100644 --- a/include/tcg/tcg.h +++ b/include/tcg/tcg.h @@ -881,7 +881,6 @@ static inline TCGLabel *arg_label(TCGArg i) * This version relies on GCC's void pointer arithmetic to get the * correct result. */ -QEMU_ARG_NONNULL static inline ptrdiff_t tcg_ptr_byte_diff(const void *a, const void *b) { return a - b; @@ -895,7 +894,7 @@ static inline ptrdiff_t tcg_ptr_byte_diff(const void *a= , const void *b) * Produce a pc-relative difference, from the current code_ptr * to the destination address. */ -QEMU_ARG_NONNULL +QEMU_ARG_LIST_NONNULL(1) static inline ptrdiff_t tcg_pcrel_diff(TCGContext *s, const void *target) { return tcg_ptr_byte_diff(target, tcg_splitwx_to_rx(s->code_ptr)); @@ -909,7 +908,7 @@ static inline ptrdiff_t tcg_pcrel_diff(TCGContext *s, c= onst void *target) * Produce a difference, from the beginning of the current TB code * to the destination address. */ -QEMU_ARG_NONNULL +QEMU_ARG_LIST_NONNULL(1) static inline ptrdiff_t tcg_tbrel_diff(TCGContext *s, const void *target) { return tcg_ptr_byte_diff(target, tcg_splitwx_to_rx(s->code_buf)); --=20 2.53.0