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 14:01:18 +0100 Message-ID: <20241214140118.od1H2D00P1Y3F3G01d1JPj@xavier.telenet-ops.be> References: <87frmroykg.fsf@free-comp-shop.com> 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="1824"; mail-complaints-to="usenet@ciao.gmane.io" Cc: "hakancandar@protonmail.com" , "guile-user@gnu.org" To: Nala Ginrut , Keith Wright Original-X-From: guile-user-bounces+guile-user=m.gmane-mx.org@gnu.org Sat Dec 14 14:02:38 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 1tMRn2-0000HW-Ck for guile-user@m.gmane-mx.org; Sat, 14 Dec 2024 14:02:36 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tMRmB-00031X-9G; Sat, 14 Dec 2024 08:01:43 -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 1tMRlx-0002x9-KN for guile-user@gnu.org; Sat, 14 Dec 2024 08:01:35 -0500 Original-Received: from xavier.telenet-ops.be ([2a02:1800:120:4::f00:14]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tMRlu-0005J6-IZ for guile-user@gnu.org; Sat, 14 Dec 2024 08:01:29 -0500 Original-Received: from [IPv6:2a02:1811:8c0e:ef00:77eb:21f9:4b67:5c0] ([IPv6:2a02:1811:8c0e:ef00:77eb:21f9:4b67:5c0]) by xavier.telenet-ops.be with cmsmtp id od1H2D00P1Y3F3G01d1JPj; Sat, 14 Dec 2024 14:01:18 +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=1734181278; bh=uSQyUC1yJDjnhZy3KIV+hn6K84I0DxTTEq1NRzuHamc=; h=Message-ID:MIME-Version:To:Cc:From:Subject:Date:In-Reply-To: References:Content-Type:From; b=ZmjEutWK12LvzeNc7Qb0tW09pGjjzMzNgMK1C+M9bVNIblAaIadJ7fgR3wOrywnZ4 ZZl/osl18xO5AKF9FUezG+kYzhFv8g0i/NMRuymmdSUW7N0Uo2D7s+JdEKHsjbpx+f x8oavwkH3tpjQNTvl8oeKvp/KmWL3/MVMMsFRDUEG3fNMmR7wcRJplNh3ewwQ/IuLV qQ9hifilyDXXavav/v+Qha74BqvedY+MKz8BIW2JOejQt1J61p+JGeUI00ky7DBXM0 AGNZX479tZBbRySiCk2w/pCnYXtRTOcxL+MhriBVIYFbxBsGNGocYYLfK6EMwGbZnq NclHtj18ZpNog== Received-SPF: pass client-ip=2a02:1800:120:4::f00:14; envelope-from=maximedevos@telenet.be; helo=xavier.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:19982 Archived-At: Compiling the .scm to .go ahead of time (with guild) and loading the .go di= rectly makes a lot of sense: =E2=80=A2 It avoids issues with locating the .go (no need to set .go path w= hen invoking guile, although if it does use additional dependencies, depend= ing on where they are located the script may need to set the .go (and .scm)= path). =E2=80=A2 It needs to look at less files (no need to compare .scm & .go mod= ification times) (*) =E2=80=A2 Easier to set compilation options (e.g. optimisation level) =E2=80=A2 It avoids auto-compilation (no "compiling this thing / that thing= =E2=80=9D messages, no compilation cache filled with old junk, and in case = of some forms of containerisation, avoids permission issues & transmission = vector). (*) won=E2=80=99t make a big difference since it most likely uses other mod= ules, but it=E2=80=99s something. >I tried the following commands with no luck: >guile3.0 example.scm.go >guile3.0 --language=3Dbytecode example.scm.go To my understanding of the language tower, the second is supposed to work. = What does =E2=80=9Cno luck=E2=80=9D mean here? (I don=E2=80=99t have a guil= e setup at the moment.) (You need to recompile in case of some version changes, but that=E2=80=99s = hardly Guile-specific.) (There is an internal caching mechanism for autocompilation, but AOT (to by= tecode) is a fine thing to do, and Guile supports that too. I recommend it = for things like libraries and installed software (for random scripts autoco= mpilation is likely good enough unless the extra messages or shared (per-us= er) cache directory are problematic.).) Best regards, Maxime Devos