From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Maxime Devos via General Guile related discussions Newsgroups: gmane.lisp.guile.user Subject: RE: Running Compiled Guile Objects Date: Sat, 14 Dec 2024 18:48:38 +0100 Message-ID: <20241214184838.ohod2D00D1Y3F3G01hoepQ@baptiste.telenet-ops.be> References: <87frmroykg.fsf@free-comp-shop.com> <20241214140118.od1H2D00P1Y3F3G01d1JPj@xavier.telenet-ops.be> <20241214155337.oetc2D0091Y3F3G06etclL@albert.telenet-ops.be> <20241214171059.ogAy2D00B1Y3F3G01gAyTM@laurent.telenet-ops.be> <20241214175016.ogqF2D00K1Y3F3G06gqG7h@michel.telenet-ops.be> Reply-To: Maxime Devos Mime-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="25321"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Keith Wright , "hakancandar@protonmail.com" , "guile-user@gnu.org" To: Nala Ginrut Original-X-From: guile-user-bounces+guile-user=m.gmane-mx.org@gnu.org Sat Dec 14 18:49:23 2024 Return-path: Envelope-to: guile-user@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 1tMWGY-0006QI-FO for guile-user@m.gmane-mx.org; Sat, 14 Dec 2024 18:49:22 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tMWFz-0002Sq-6Z; Sat, 14 Dec 2024 12:48:47 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tMWFw-0002SD-WD for guile-user@gnu.org; Sat, 14 Dec 2024 12:48:45 -0500 Original-Received: from baptiste.telenet-ops.be ([2a02:1800:120:4::f00:13]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tMWFu-0001A9-Eu for guile-user@gnu.org; Sat, 14 Dec 2024 12:48:44 -0500 Original-Received: from [IPv6:2a02:1811:8c0e:ef00:77eb:21f9:4b67:5c0] ([IPv6:2a02:1811:8c0e:ef00:77eb:21f9:4b67:5c0]) by baptiste.telenet-ops.be with cmsmtp id ohod2D00D1Y3F3G01hoepQ; Sat, 14 Dec 2024 18:48:38 +0100 Importance: normal X-Priority: 3 In-Reply-To: DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telenet.be; s=r24; t=1734198518; bh=G8Qd6eBM5kge4Cbpzyn/VYfFZfe2a/jqrVuagNJuUbA=; h=Message-ID:MIME-Version:To:Cc:From:Subject:Date:In-Reply-To: References:Content-Type:From; b=bZCJ+Qf2bsGuARAxp7/YUFm//npjlsEuyHf1NLCFQ+5h058FCxFnmwGYRrGbFyu4r OsWcft+X12p6UPmsqgy+bBImoLOsImUT9mn/icjfL8F03MGQeQixlIMIvJEXblWNQM ZjD5Qpmg/78DnwOnihuLw+5Y4db2UPw0jHI2jBFFtfIReFKdOYmhvEzyBwcYu1VLrZ ZSP74aEXIZIJIq5mDE/DQSbRJJPeRsuRLrsFT1IHBLR0ZV0kDjPLCwj5zs0VBqn5/h o1sm/3TuqVnzOmzxB+gMtdgbLglfzNphY5iaWlv1DAUw56oUkcKMdpl8GjpJYSl9XM LZdKYHf40pzgg== Received-SPF: pass client-ip=2a02:1800:120:4::f00:13; envelope-from=maximedevos@telenet.be; helo=baptiste.telenet-ops.be X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: guile-user@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: General Guile related discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-user-bounces+guile-user=m.gmane-mx.org@gnu.org Original-Sender: guile-user-bounces+guile-user=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.lisp.guile.user:19994 Archived-At: >> Also, post-hoc: your example is wrong, in the sense that you gave the co= mpiled module the wrong name! You should name it ./obj/mod/X.go, not ./obj/= mod/X.scm.go. If it then still not loads the .go, that=E2=80=99s a bug and = a regression. >I'm pretty sure to test both .go and .scm.go under 3.0.10. >If I understand you correctly, you mean b.scm will try to find b.go, or at= least auto compile to b.go, right? Both .go and .scm.go can not deny what = I just described. And the default naming is .scm.go as what I can see in the terminal. Yes, you need to adjust the default naming. IIUC, the default naming is set= up for Guile=E2=80=99s auto-compile cache, instead of for Guile=E2=80=99s = load-compiled-path (these aren=E2=80=99t the same). (Confusingly .go are in= stalled in subdirectories of a directory named =E2=80=98ccache=E2=80=99 (at= least on Debian), but IIRC if you look at the .scm->.go mapping go, you=E2= =80=99d see that the code for the auto-compilation cache is separated from = the pre-compiled .go (and .cache/guile/2.0/ccache has a different layout), = and since it is only updated at installation / package upgrades by copying = over (pre-)compiled files, by definition it isn=E2=80=99t a cache.) No, I don=E2=80=99t mean that =E2=80=98b.scm will try to find b.go=E2=80=99= . There is not reason for it to try that, and is somewhat against the point= of compilation. Rather, b.scm is not loaded at all (except for some metada= ta: the time stamp). I also don=E2=80=99t mean =E2=80=98auto compile to b.g= o=E2=80=99. That=E2=80=99s against the point of the whole pre-compilation t= hing. Instead, when the module (mod a) is loaded (whether from mod/a.scm or obj/m= od/a.go)), Guile module system is asked to load the module (mod b), and it = sees mod/b.go exists in load-compiled-path and mod/a.scm exists in in load-= path (and timestamps are ok), so it loads (obj/)mod/b.go. Since this mechanism is used for Guile=E2=80=99s own libraries as well ((sy= stem =E2=80=A6), (srfi =E2=80=A6), (ice-9 =E2=80=A6), =E2=80=A6), I would e= xpect this to still work in 3.0.10. If you have proof of the contrary you s= hould make a bug report about it. >On Sun, Dec 15, 2024, 01:50 Maxime Devos wrote: > [=E2=80=A6] I don=E2=80=99t need a copy of my own e-mails. Best regards, Maxime Devos