From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by sourceware.org (Postfix) with ESMTPS id 7B34E3858400 for ; Wed, 5 Jan 2022 10:24:24 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 7B34E3858400 Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 739FE2112A; Wed, 5 Jan 2022 10:24:23 +0000 (UTC) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 4F92013B98; Wed, 5 Jan 2022 10:24:23 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id fgMyEtdx1WERXgAAMHmgww (envelope-from ); Wed, 05 Jan 2022 10:24:23 +0000 Message-ID: <9583a974-a5a2-ac23-eba1-9cb86ae2f6e4@suse.de> Date: Wed, 5 Jan 2022 11:24:22 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.4.0 Subject: Re: [PATCH] nvptx: bump default to PTX 4.1 Content-Language: en-US To: Andrew Stubbs , "gcc-patches@gcc.gnu.org" References: <25ad524d-f0d6-1970-b8e9-9b11b6cde68b@codesourcery.com> <8b5136c0-2d30-8838-e870-78609f3885e6@codesourcery.com> From: Tom de Vries Cc: Tobias Burnus , Jakub Jelinek In-Reply-To: <8b5136c0-2d30-8838-e870-78609f3885e6@codesourcery.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-12.8 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, KAM_NUMSUBJECT, NICE_REPLY_A, SPF_HELO_NONE, SPF_PASS, TXREP 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: , X-List-Received-Date: Wed, 05 Jan 2022 10:24:26 -0000 On 12/21/21 12:33, Andrew Stubbs wrote: > On 20/12/2021 15:58, Andrew Stubbs wrote: >> In order to support the %dynamic_smem_size PTX feature is is necessary >> to bump the minimum supported PTX version from 3.1 (~2013) to 4.1 >> (~2014). > > Tobias has pointed out, privately, that the default version is both > documented and encoded in the -mptx option, so I need to fix that too. > > This patch adds -mptx=4.1, sets it as the default, and updates the > documentation accordingly. > > The -mptx=3.1 option is kept for backwards compatibility as an alias for > 4.1. There's no point in actually allowing 3.1 as any program linked > against libgomp will fail (and that's all offloading programs). > > OK for stage 1? Just keep -mptx=3.1 as is, and add -mptx=4.1. AFAIU, there's actually only one file required to have -mptx=4.1, the one using %dynamic_smem_size. Since it's somewhat cumbersome to add flags for a single file, how about: ... diff --git a/libgomp/configure.tgt b/libgomp/configure.tgt index d4f1e741b5a..92242697f24 100644 --- a/libgomp/configure.tgt +++ b/libgomp/configure.tgt @@ -162,6 +162,7 @@ case "${target}" in nvptx*-*-*) config_path="nvptx accel" + XCFLAGS="$XCFLAGS -mptx=4.1" ;; *-*-rtems*) ... ? Thanks, - Tom