From patchwork Wed May 4 16:16:14 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Tobias Burnus X-Patchwork-Id: 1626449 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=gcc.gnu.org (client-ip=2620:52:3:1:0:246e:9693:128c; helo=sourceware.org; envelope-from=gcc-patches-bounces+incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Received: from 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 RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by bilbo.ozlabs.org (Postfix) with ESMTPS id 4KthmJ2Dx9z9sG0 for ; Thu, 5 May 2022 02:16:46 +1000 (AEST) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 004FE3856272 for ; Wed, 4 May 2022 16:16:44 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from esa2.mentor.iphmx.com (esa2.mentor.iphmx.com [68.232.141.98]) by sourceware.org (Postfix) with ESMTPS id F2D9B3858C53 for ; Wed, 4 May 2022 16:16:20 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org F2D9B3858C53 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=codesourcery.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=mentor.com X-IronPort-AV: E=Sophos;i="5.91,198,1647331200"; d="diff'?scan'208";a="75331745" Received: from orw-gwy-01-in.mentorg.com ([192.94.38.165]) by esa2.mentor.iphmx.com with ESMTP; 04 May 2022 08:16:19 -0800 IronPort-SDR: 0iSDs2rEI8clp4BDcGTyyaF7SxI03ebt1aVLmqW+lC1to+kILGtLfRqQj3Bm8mI1tF0FkKsHHX fdR/lZGMjL8SPlG8qMAd0Ac1NVaJYAvD9oSsY6WqB6stK5+cxMFXQnidBroQWbhVxzeXxymwo+ ge2co4K1EPZBGjQJ2fAGwzMtcTYwQkVoiMc3B+q4HlrCFxl7idTJv3eKP+AI6EIOE8o6wEpjK7 h/nvdjgVILOu92Q5MYGLadFUxY8quMhaHpv7DHNaXSxaWnlmgdmuMSSsJeuNbx5bhEZAf5HCe9 adM= Message-ID: <74860aa6-3a86-5150-4c25-19a189b9bbba@codesourcery.com> Date: Wed, 4 May 2022 18:16:14 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.8.1 Content-Language: en-US To: gcc-patches , Andrew Stubbs , Jakub Jelinek From: Tobias Burnus Subject: libgomp/plugin/plugin-gcn.c: Use -foffload-options= in err msg X-Originating-IP: [137.202.0.90] X-ClientProxiedBy: svr-ies-mbx-15.mgc.mentorg.com (139.181.222.15) To svr-ies-mbx-12.mgc.mentorg.com (139.181.222.12) X-Spam-Status: No, score=-11.4 required=5.0 tests=BAYES_00, GIT_PATCH_0, HEADER_FROM_DIFFERENT_DOMAINS, KAM_DMARC_STATUS, KAM_SHORT, SPF_HELO_PASS, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 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 Sender: "Gcc-patches" See also https://gcc.gnu.org/gcc-12/changes.html#languages and https://gcc.gnu.org/onlinedocs/gcc/C-Dialect-Options.html#index-foffload -foffload= was never officially documented, albeit most users will have encountered it. Since GCC 12 it is - but the -foffload=- part is officially only handled by -foffload-options=, even if it works as legacy feature with -foffload= as well. OK for GCC 13? Tobias PS: Note that -foffload=amdgcn-amdhsa=-march=gfx908 and -foffload-options=amdgcn-amdhsa=-march=gfx908 are not identical. The former (legacy feature) will disable all other supported targets, such as nvptx, while the latter keeps the default set - and just passes that additional flag to the amdgcn target compiler. ----------------- Siemens Electronic Design Automation GmbH; Anschrift: Arnulfstraße 201, 80634 München; Gesellschaft mit beschränkter Haftung; Geschäftsführer: Thomas Heurung, Frank Thürauf; Sitz der Gesellschaft: München; Registergericht München, HRB 106955 libgomp/plugin/plugin-gcn.c: Use -foffload-options= in err msg While -foffload=- works (never documented legacy feature), the documented way is to use -foffload-options=. libgomp/ChangeLog: * plugin/plugin-gcn.c (isa_matches_agent): Suggest -foffload-options. diff --git a/libgomp/plugin/plugin-gcn.c b/libgomp/plugin/plugin-gcn.c index f305d726874..2b32f5352c8 100644 --- a/libgomp/plugin/plugin-gcn.c +++ b/libgomp/plugin/plugin-gcn.c @@ -2352,7 +2352,7 @@ isa_matches_agent (struct agent_info *agent, Elf64_Ehdr *image) snprintf (msg, sizeof msg, "GCN code object ISA '%s' does not match GPU ISA '%s'.\n" - "Try to recompile with '-foffload=-march=%s'.\n", + "Try to recompile with '-foffload-options=-march=%s'.\n", isa_s, agent_isa_s, agent_isa_gcc_s); hsa_error (msg, HSA_STATUS_ERROR);