From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by sourceware.org (Postfix) with ESMTPS id 1AC393858C83 for ; Fri, 19 Aug 2022 14:06:08 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 1AC393858C83 Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-333-Prm1p7puNbqKnyIBtn3y1A-1; Fri, 19 Aug 2022 10:06:04 -0400 X-MC-Unique: Prm1p7puNbqKnyIBtn3y1A-1 Received: from smtp.corp.redhat.com (int-mx09.intmail.prod.int.rdu2.redhat.com [10.11.54.9]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id D10C53815D30; Fri, 19 Aug 2022 14:06:03 +0000 (UTC) Received: from tucnak.zalov.cz (unknown [10.39.192.41]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 92E82492C3B; Fri, 19 Aug 2022 14:06:03 +0000 (UTC) Received: from tucnak.zalov.cz (localhost [127.0.0.1]) by tucnak.zalov.cz (8.17.1/8.17.1) with ESMTPS id 27JE60u23163654 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NOT); Fri, 19 Aug 2022 16:06:01 +0200 Received: (from jakub@localhost) by tucnak.zalov.cz (8.17.1/8.17.1/Submit) id 27JE5xOF3163653; Fri, 19 Aug 2022 16:05:59 +0200 Date: Fri, 19 Aug 2022 16:05:59 +0200 From: Jakub Jelinek To: Tobias Burnus Cc: gcc-patches , Andrew Stubbs Subject: Re: [Patch] mkoffload: Cleanup temporary omp_requires_file Message-ID: Reply-To: Jakub Jelinek References: <8623b1a3-ef98-1ebb-1abc-194b646288a7@codesourcery.com> MIME-Version: 1.0 In-Reply-To: <8623b1a3-ef98-1ebb-1abc-194b646288a7@codesourcery.com> X-Scanned-By: MIMEDefang 2.85 on 10.11.54.9 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-4.5 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, KAM_SHORT, RCVD_IN_DNSWL_LOW, SPF_HELO_NONE, SPF_NONE, TXREP, T_SCC_BODY_TEXT_LINE 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.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Aug 2022 14:06:09 -0000 On Fri, Aug 19, 2022 at 04:01:10PM +0200, Tobias Burnus wrote: > Rather obvious, once found. I forgot to add some cleanup, cluttering > /tmp with ".mkoffload.omp_requires". > > The same issue exists for GCN also for ".mkoffload.dbg" > > OK for mainline? – For the dbg issue, OK also for GCC 11 and 12 backport? > > Follow-up to the 'OpenMP: Move omp requires checks to libgomp" commit > https://gcc.gnu.org/r13-1458-g683f11843974f0bdf42f79cdcbb0c2b43c7b81b0 > > For GCN, the issues exists since > https://gcc.gnu.org/r11-6683-g505caa7295b93ecdec8ac9b31595eb34dbd48c9f > > Tobias > > PS: In case you wonder why it is also added with -save-temps: The > internally called maybe_unlink removed the file, unless -save-temps. For > the latter, with verbose flag, it also shows them as '[Leaving %s]'. > > PPS: If you see some ...target.o files in /tmp, that's because of > https://gcc.gnu.org/PR106686 > ----------------- > 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 > mkoffload: Cleanup temporary omp_requires_file > > The file (suffix ".mkoffload.omp_requires") used to save the 'omp requires' > data has to be passed to maybe_unlink for cleanup or -v -save-temps stderr > diagnostic. That was missed before. - For GCN, the same has to be done for > the files with suffix ".mkoffload.dbg.o". > > gcc/ChangeLog: > > * config/gcn/mkoffload.cc (main): Add omp_requires_file and dbgobj to > files_to_cleanup. > * config/i386/intelmic-mkoffload.cc (prepare_target_image): Add > omp_requires_file to temp_files. > * config/nvptx/mkoffload.cc (omp_requires_file): New global static var. > (main): Remove local omp_requires_file var. > (tool_cleanup): Handle omp_requires_file. Ok, thanks. Jakub