From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stephen Gildea Newsgroups: gmane.emacs.bugs Subject: bug#50975: 28.0.60; mh-utils-tests fail with native compilation Date: Mon, 04 Oct 2021 17:29:02 -0700 Message-ID: <540302.1633393742@pental> References: <9fd40a2f-c653-60b7-7f59-09c925122bf5@cornell.edu> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="6543"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 50975@debbugs.gnu.org To: Andrea Corallo Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Oct 05 02:30:10 2021 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mXYLS-0001ZN-8e for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 05 Oct 2021 02:30:10 +0200 Original-Received: from localhost ([::1]:51424 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mXYLQ-0003LC-CE for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 04 Oct 2021 20:30:08 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:57908) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mXYLK-0003L3-CK for bug-gnu-emacs@gnu.org; Mon, 04 Oct 2021 20:30:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:55307) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mXYLK-0007ac-3t for bug-gnu-emacs@gnu.org; Mon, 04 Oct 2021 20:30:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mXYLJ-0008R4-TR for bug-gnu-emacs@gnu.org; Mon, 04 Oct 2021 20:30:01 -0400 X-Loop: help-debbugs@gnu.org In-Reply-To: <9fd40a2f-c653-60b7-7f59-09c925122bf5@cornell.edu> Resent-From: Stephen Gildea Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 05 Oct 2021 00:30:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 50975 X-GNU-PR-Package: emacs Original-Received: via spool by 50975-submit@debbugs.gnu.org id=B50975.163339374932347 (code B ref 50975); Tue, 05 Oct 2021 00:30:01 +0000 Original-Received: (at 50975) by debbugs.gnu.org; 5 Oct 2021 00:29:09 +0000 Original-Received: from localhost ([127.0.0.1]:38620 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mXYKT-0008Pe-JG for submit@debbugs.gnu.org; Mon, 04 Oct 2021 20:29:09 -0400 Original-Received: from tigger.sg.gildea.net ([99.65.78.170]:60820 helo=pental.sg.gildea.net) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mXYKS-0008PP-1b for 50975@debbugs.gnu.org; Mon, 04 Oct 2021 20:29:08 -0400 Original-Received: from pental (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by pental.sg.gildea.net (Postfix) with ESMTPS id 6578F246C73; Mon, 4 Oct 2021 17:29:02 -0700 (PDT) X-Mailer: MH-E 8.6+git; nmh 1.7.1; GNU Emacs 29.0.50 Content-ID: <540298.1633393742.1@pental> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:216404 Archived-At: Thank you, Andrea, for the native-trampolines patch to mh-utils-tests.el. In this patch, the test explicitly compiles trampolines before redefining two functions that are defined in C. Is it necessary to provide trampolines at all for these short-lived test functions? The following works for me: (mapc (lambda (x) (add-to-list 'native-comp-never-optimize-functions x)) '(call-process file-directory-p)) Before redefining the functions, the test could create a dynamic local binding for native-comp-never-optimize-functions and add to it as above. If that is a reasonable approach, can we go further? Can the native-compile code detect that this is a test and automatically suppress trying to compile a trampoline, without the test having to be aware of native-compile? < Stephen