From patchwork Mon Oct 21 12:42:53 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Stubbs X-Patchwork-Id: 1999929 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.a=rsa-sha256 header.s=20230601 header.b=RtMc03sU; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=gcc.gnu.org (client-ip=2620:52:3:1:0:246e:9693:128c; helo=server2.sourceware.org; envelope-from=gcc-patches-bounces~incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=patchwork.ozlabs.org) Received: from server2.sourceware.org (server2.sourceware.org [IPv6:2620:52:3:1:0:246e:9693:128c]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4XXFNb2G9Vz1xwb for ; Mon, 21 Oct 2024 23:43:40 +1100 (AEDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 3C8A1385840F for ; Mon, 21 Oct 2024 12:43:38 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from mail-wm1-x336.google.com (mail-wm1-x336.google.com [IPv6:2a00:1450:4864:20::336]) by sourceware.org (Postfix) with ESMTPS id 1BB633858D20 for ; Mon, 21 Oct 2024 12:43:00 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 1BB633858D20 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=baylibre.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 1BB633858D20 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2a00:1450:4864:20::336 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1729514590; cv=none; b=Obwz0CH0+xQGt/5NFJDnJOt3GyVPAPq1Bqog6108TFftpulDfBf5L4YJT1/tOTovkxdJAB7mnLr7IStzzmKo638/lm0RLUARnhR4y1082e+kkLyA9MzlLi+4HcEvgGG9zWMu7QAHNATZdLpYHytATndi9iDUkv0/irT7fKQ3grY= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1729514590; c=relaxed/simple; bh=1XKNyvXpxZeyK4C5BrcusRZtw1hXqO6PaYvqVJJPi34=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=ksNse1a/dC2WoIr6uhVUtriFNGlSz/Ou1nawpCvE69VmInHuzvgCxZqpqPYv1cS954KVESYOXzSZz667Ts7MYbmw5ogj5BS2+QAFlOBbH1qV1Wlm/tEpKjCdhxiQPqQynLi/e4AM5SE0N/ddFEtjWgSUoBMfYDJQGjRkGvi+F30= ARC-Authentication-Results: i=1; server2.sourceware.org Received: by mail-wm1-x336.google.com with SMTP id 5b1f17b1804b1-43159c9f617so41816375e9.2 for ; Mon, 21 Oct 2024 05:43:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1729514578; x=1730119378; darn=gcc.gnu.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=1puL9xyvF3fvmYxCNdM9moVRlgMHs1HCXOHgQXOvYBA=; b=RtMc03sUCXF2DHhoNN2QWb0p5q/UsWDv0rAM/FL3yeb7LffJI8EF3pyne0YUfwCoSe HUz8nXPAo3HBnI41tCY3aJ5pxHvfqTkq7LKKhJN1qQIbvE/xT3GVwS5/DHDCB+cHTdJ8 sMgdfOR6lLbZKm4Ri/7oGXmJUzUbb+RhOUfUE6MiiTwRzJdaPiafMKaMVR3tFqQltenW g4IcL2sTgBZSLhVC/AVGc4e/4hbvZ6dgOF/72c7KB/H30rjO/W/zqVn2gt54uBIZiOoo ZJ0M63cskgkHEQT8XzNiylmVXj3zt70dHYW35nNQOxABskQMS5VRCJQ9Rz/HPnbgRDg6 Nx/w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729514578; x=1730119378; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=1puL9xyvF3fvmYxCNdM9moVRlgMHs1HCXOHgQXOvYBA=; b=YwV7GJkz0SwRV5xDCzHBVAJfANZcz3A/5tfpc+ANbPBQieYn0/0XzgDjKXaaMOThzG I3i8QyEJSrRPQdXsvqWZ6SJC3cod9dPDDlptqB+MgOQeOL5ZUJcAa8IvzEPiC8hWQGed Mr2UiKLgR9Gxy9KSUI6NsE/4ITOoCXwLRm3N3wWVPLuU43apeug8FiS9ILWtoaSg6DU0 n5On6kAr4JebzBH7I/RsbSNLfRyNTdA6KQ4015dFZiSZ8YeDoT+j3ViiLoNlEjsT3/ah DqtWZLhMDCmiJ5MTxfFZnfeSDQvZxzng7sCPBbRewB6ZWdhMR80h/AR1sisXRJbqHAkN xLqw== X-Gm-Message-State: AOJu0YwuTEy7NfrCt/J/AWJUouziy/SMjFUpuALnqhAV2YD+Dw+7LFQb w+9Rt6cG+gPw9D894ljFoSEG5NuGGotpieth19YlwXUyPSdNjYC0QkykGicJ8iXPySXn/rKcwUc J X-Google-Smtp-Source: AGHT+IGTL+VHnbHJH2rFXNJ1ljVVHcUFefcIAMDikImgDPfHAnTEqFlXvHMFyky5u6BOkvRhV2oJow== X-Received: by 2002:a05:600c:4709:b0:430:56c1:644c with SMTP id 5b1f17b1804b1-43161693a2emr80956415e9.31.1729514578106; Mon, 21 Oct 2024 05:42:58 -0700 (PDT) Received: from carlos.baylibre ([217.13.61.132]) by smtp.googlemail.com with ESMTPSA id 5b1f17b1804b1-43160682759sm118409615e9.1.2024.10.21.05.42.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 21 Oct 2024 05:42:57 -0700 (PDT) From: Andrew Stubbs To: gcc-patches@gcc.gnu.org Cc: tburnus@baylibre.com Subject: [committed] amdgcn: silence warning Date: Mon, 21 Oct 2024 12:42:53 +0000 Message-ID: <20241021124254.733775-1-ams@baylibre.com> X-Mailer: git-send-email 2.46.0 MIME-Version: 1.0 X-Spam-Status: No, score=-11.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, GIT_PATCH_0, 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 X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gcc-patches-bounces~incoming=patchwork.ozlabs.org@gcc.gnu.org FIRST_SGPR_REG is register zero so the compiler always claims this comparison is redundant. It's right, of course, but I'd have preferred to keep the comparison for completeness. Probably the "correct" solution is to use an enum for these values. gcc/ChangeLog: * config/gcn/gcn.h (SGPR_REGNO_P): Silence warning. --- gcc/config/gcn/gcn.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gcc/config/gcn/gcn.h b/gcc/config/gcn/gcn.h index 1a4631dd39f..faefe68cdfa 100644 --- a/gcc/config/gcn/gcn.h +++ b/gcc/config/gcn/gcn.h @@ -191,7 +191,7 @@ STATIC_ASSERT (LAST_AVGPR_REG + 1 - FIRST_AVGPR_REG == 256); #define HARD_FRAME_POINTER_IS_ARG_POINTER 0 #define HARD_FRAME_POINTER_IS_FRAME_POINTER 0 -#define SGPR_REGNO_P(N) ((N) >= FIRST_SGPR_REG && (N) <= LAST_SGPR_REG) +#define SGPR_REGNO_P(N) (/*(N) >= FIRST_SGPR_REG &&*/ (N) <= LAST_SGPR_REG) #define VGPR_REGNO_P(N) ((N) >= FIRST_VGPR_REG && (N) <= LAST_VGPR_REG) #define AVGPR_REGNO_P(N) ((N) >= FIRST_AVGPR_REG && (N) <= LAST_AVGPR_REG) #define SSRC_REGNO_P(N) ((N) <= SCC_REG && (N) != VCCZ_REG)