From patchwork Sun Dec 22 00:04:52 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "H.J. Lu" X-Patchwork-Id: 852886 Delivered-To: patch@linaro.org Received: by 2002:a5d:4888:0:b0:385:e875:8a9e with SMTP id g8csp2769420wrq; Sat, 21 Dec 2024 16:13:56 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCVfIi6B8a5eu+tNP/zx7ocqMXJPpeDKeKq24sDkcciFCmMARzU9RUz7jg9Syy9IZMwwok6Z9A==@linaro.org X-Google-Smtp-Source: AGHT+IE6UAG1kkx47xikYWZLl5X5KsADcb+jzAmOMzd6oRRup0v8xL4Qvc52zuIeQ3t2GcR3b8Yt X-Received: by 2002:a05:6214:2621:b0:6d8:b5dd:7699 with SMTP id 6a1803df08f44-6dd2360e105mr104288206d6.17.1734826436566; Sat, 21 Dec 2024 16:13:56 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1734826436; cv=pass; d=google.com; s=arc-20240605; b=BgRi1WRmJ2ZYwRlxo86vASHaeHh0N73XcVh69Z34Hm6cUKLs3IWroZ7IuJmEnSlWf/ ib68XRED+WAhJ6p2bX4tE20AVqCx7R1WzZCvzlVBU8FXDEo0yKMmuS96o+dKf5tKJ8dk CWHB1tTGo1hhaIK+OU2mXV7i+UXEiTIsqLowxNdHLVdon1pl4Ugr11Fh11tsZRjOoJhq 1R1CTAiEfUTtFTi1DLxPGDLf3UTEZn+DShdEhytHSPPbEJWIqXWHjK0MoMr+MDoidlVK nmtbwO58EcHonyQqe+hwHIPzZZpfwInNhzaLq+9hcbX5h/o5jMqFWYmCG5SeHcTtR2SH Eksg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature:arc-filter:dmarc-filter:delivered-to; bh=ceXLlC6ui3fEQNSUELVE6ds4H551ZAuPhCCHkcr1sFI=; fh=uKlFkH9AUukvL1xmvBA9M7Oe4ntiJIR8HCR4+3TPd4w=; b=MHPyUpn2DZ+RJUH+eR0D14QjuxHYVzZnFp17eh3MdLRNIzFZ4q+sAWz5Ba9CvRoxYe WQT4HIq+ClAR0kYsMvPPqWYP+cLY+ledD/6SDcQCwCZDBZW15Tc9CWrm9phPK1SPlRDU jDL0L/fJUnRRg/5TvzSP8UGDQXETaD2aVB7/lDksYFEWXV4LUvofGbgPr8kXWWubndqs k6zYMtlZ06s74ZQQXPsdaR974gOjumv6RfPEeAz5iMQarXuVngtgp9Z9gH2FQy0RJOQM p9diKNaKZ4KKtEQ8mf1BIYQmlB49PG4IV14bYFhYbecDybtkuMT9DGrEdW3J/KpDTVA5 qqCg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=jYxFWxoh; arc=pass (i=1); spf=pass (google.com: domain of libc-alpha-bounces~patch=linaro.org@sourceware.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) smtp.mailfrom="libc-alpha-bounces~patch=linaro.org@sourceware.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from server2.sourceware.org (server2.sourceware.org. [2620:52:3:1:0:246e:9693:128c]) by mx.google.com with ESMTPS id 6a1803df08f44-6dd18135f47si75987096d6.120.2024.12.21.16.13.56 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 21 Dec 2024 16:13:56 -0800 (PST) Received-SPF: pass (google.com: domain of libc-alpha-bounces~patch=linaro.org@sourceware.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) client-ip=2620:52:3:1:0:246e:9693:128c; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=jYxFWxoh; arc=pass (i=1); spf=pass (google.com: domain of libc-alpha-bounces~patch=linaro.org@sourceware.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) smtp.mailfrom="libc-alpha-bounces~patch=linaro.org@sourceware.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 335993858039 for ; Sun, 22 Dec 2024 00:13:56 +0000 (GMT) X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from mail-pl1-x62a.google.com (mail-pl1-x62a.google.com [IPv6:2607:f8b0:4864:20::62a]) by sourceware.org (Postfix) with ESMTPS id 88FF23858039 for ; Sun, 22 Dec 2024 00:05:34 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 88FF23858039 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 88FF23858039 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::62a ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1734825934; cv=none; b=m7syJOxjwlmtwmTaQSf+Gi2ghQ16IIgy1E5ZAeXNOcBycNzoH43+x46d5eTPn/+cT04IiAYgQu5qENtp685sXg/cdAwdifY9Luk9o+7CkZwYBmcUbHFVJztbkEUGrCwqT5bdx0G7K4f0xdC3lML7pi5Hx6rxevUz0VlezTUjpks= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1734825934; c=relaxed/simple; bh=sW72+8GKrgN2BGscpBwq0ZA/pKZ0rF+HMrpbuD4ZD7w=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=TJwN27q3yCTLRx5rxQpzU4WIIdzsThDfBS99Jqxu4C9w0fsn8Ojh5wKnCmGUP8bIoo9z9YT3WltTAKBbgIKXDQn31Kj88mOfSNTK9o4Bx50cnr4AifQwMFA5O5SBQjJVwepjcxmnOrPpHfXr4yMwzN1OxESB9hyO80eJWCuyTyk= ARC-Authentication-Results: i=1; server2.sourceware.org Received: by mail-pl1-x62a.google.com with SMTP id d9443c01a7336-216395e151bso20377695ad.0 for ; Sat, 21 Dec 2024 16:05:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1734825927; x=1735430727; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=ceXLlC6ui3fEQNSUELVE6ds4H551ZAuPhCCHkcr1sFI=; b=jYxFWxohyVGAf4LGh9tiZ/NwaWcYZIrLKMgNaCmjAv/yvMOecL4aPvseuQzRnyAr8W q0O1NwxIAkeOfXMK4g1jkVk5/KgiWnhqf2KUgyT65za0ezuyUuVQiNM0smrjzLm4ZmVa yvDo2Ln6FgQZWHMP5yrCenuVAKdOeGez5fEdEthdOtuZW60mFwpMK6SjBMb5af1NdcLr XEQMb5DhmlKxWqDqljmuiC4K8OEefcDH6MGEZ+g44HZ0fHA03ryNeXXyp7z8kbJ7l/Gs 75bv2f9cRgGtd2hSX375a//j6jscPln6UZZUq0E8veXEii8LuSeKOI4oofyEV9NNuWJs rFOg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1734825927; x=1735430727; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=ceXLlC6ui3fEQNSUELVE6ds4H551ZAuPhCCHkcr1sFI=; b=jR/I2soQUhpGhOPT8r2yPHsj11H/ocsDDYoZNY1lG9RB6310HTAmGwMxIhXXbi+i7H tN4X/LwgV2jad/R0mvNJSVz3YXrpm6iJRvzHjebNUBtS/sONav4//PyLI82XWrNOxrEq FunA84nWbDj/DTSrAkqRPHDJrRIZwbkzVRwnjYoS68PyK9PDneF1EAUycFR5bjjaiTSZ aZsohXV8IPudENg6Vmwhj2rTtmIKVDXfo7hsFFTFsSc17VKGRnmtgcVPLaUmFwc35ci6 ujVSCguLdnii/FA+jvrqIy81RCXd1Se83d1kmNE2LKG7dg7D6aEVtwx8Ca4Afx/sb7DF YrcQ== X-Gm-Message-State: AOJu0YxkjPpImdwN2MQvo1aK3NBJGLpabWzxb2K1TDwje7j8aBN5TSl2 UGrhUVXeFuhCX77W507RdWq74ZGqBXr+YsmnmE7UWqjxDarqhiKSsu8/1bCs52/2dg== X-Gm-Gg: ASbGnctOeVK2fGjCg1ZYfQSEUlfJoqC93zAZCnhnnZgukYzlLiz3ofcY4mbiezf9hgb +sAYqVyQ3diZZx0gcikLVbFzZuX2TzKZE/kUL8Utj1ZuA1bnzZM4pXO/nZDfrTVX5KfoNcvA+rp uNOfhYVPbhiq6mxjprnu00B9OlUUC8WyixQ9YmghalJrwpiMlfMiwmsRMqVCZaRBmUpnCNyQbmg kTIzpE0ptE4gO6NVZovSCOxeyaN0h7i2K2urnCHympyHCTZ5cF8tDAlc4LZhKC9QD5KvAE= X-Received: by 2002:a17:902:e883:b0:215:742e:5cff with SMTP id d9443c01a7336-219e6cfc163mr119671605ad.16.1734825926654; Sat, 21 Dec 2024 16:05:26 -0800 (PST) Received: from gnu-tgl-3.localdomain ([120.204.185.181]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-219dc96ea84sm49073255ad.76.2024.12.21.16.05.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 21 Dec 2024 16:05:25 -0800 (PST) Received: from gnu-tgl-3.lan (localhost [IPv6:::1]) by gnu-tgl-3.localdomain (Postfix) with ESMTP id 6E76BC0B52; Sun, 22 Dec 2024 08:05:15 +0800 (CST) From: "H.J. Lu" To: libc-alpha@sourceware.org Cc: sam@gentoo.org, Adhemerval Zanella Subject: [PATCH 29/39] math: Fix clang warnings for math/test-tgmath-ret.c Date: Sun, 22 Dec 2024 08:04:52 +0800 Message-ID: <20241222000509.2205895-30-hjl.tools@gmail.com> X-Mailer: git-send-email 2.47.1 In-Reply-To: <20241222000509.2205895-1-hjl.tools@gmail.com> References: <20241222000509.2205895-1-hjl.tools@gmail.com> MIME-Version: 1.0 X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libc-alpha-bounces~patch=linaro.org@sourceware.org From: Adhemerval Zanella clang warns that since the global variables are only used to function calls (without being actually used), there are not needed and will not be emitted. Reviewed-by: Sam James --- math/test-tgmath-ret.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/math/test-tgmath-ret.c b/math/test-tgmath-ret.c index 36dc132e4f..71f36d39fa 100644 --- a/math/test-tgmath-ret.c +++ b/math/test-tgmath-ret.c @@ -21,13 +21,19 @@ #include #include #include +#include +/* clang warns the global variables are not needed and will not be emitted. + However there are used on the CHECK_RET_* macros. */ +DIAG_PUSH_NEEDS_COMMENT_CLANG; +DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wunneeded-internal-declaration"); static float fx; static double dx; static long double lx; static int rm = FP_INT_UPWARD; static unsigned int width = 64; static int errors = 0; +DIAG_POP_NEEDS_COMMENT_CLANG; static void our_error (const char *c)