<ArneBab>wingo: wow — cool! (more meaningful comments when I’m through :-) ) ***apteryx_ is now known as apteryx
<lloda>how to set the compilation flags for autocompilation? <lloda> ah %auto-compilation-options <lloda>do people actually precompile their Scheme? i rely entirely on autocomp <lloda>actually it isn't clear to me how one would set -o2 or w/e in %auto-compilation-options <lloda>I cannot find the format in the manual <lloda>the default is just a list of warning symbols <lloda>guild compile -Ohelp lists the flags but the summary options -O0 etc aren't available to %auto-compilation-options, or are they <lloda>I think I might have asked this before sry <lloda>oh (@ (system base optimize) optimizations-for-level) <wingo>lloda: hey this changed recently! <wingo>lloda: (use-modules ((system base compile) #:select (default-optimization-level))) <wingo>(default-optimization-level 2) <wingo>same for default-warning-level <chrislck>some error after converting all _ to gettext for guile-3.0: "WARNING: loading compiled file (...) load-thunk-from-memory: incompatible bytecode kind" using guile-3.0.1 <chrislck>oh guile-3.0 was looking into guile-2.2 cache <wingo>maybe you had some precompiled .go files in your GUILE_LOAD_COMPILED_PATH that were compiled with an older guile <civodul>wingo: optimizations-for-level is still there though, right? <wingo>though it isn't used in guile any more <wingo>whenever you can migrate to passing #:optimization-level as a param to compile-file, you should do so <wingo>civodul: incidentally one place to look for improving compile speed at -O0 / -O1 would be making fix-letrec do something simpler instead of computing SCCs <wingo>like just do the standard letrec conversion instead or something, dunno <wingo>or maybe it can be optimized in some better way <wingo>b/c letrectification can produce big graphs to be teased apart into scc's <civodul>i haven't put any thought into all this! <manumanumanu>wingo: fyi, your blog posts have been instrumental in getting me to understand what guile is doing behind the scenes. Not that I understand much, but reading through the guile posts over the last 10 years has made me write better code :D <wingo>civodul: just responded to your mail. i think you will enjoy the statprof fix :) ***ecraven- is now known as ecraven
<manumanumanu>funny to see that the -O2 produces almost the same quality code as O1, except for some select benchmarks, where the gains are substantial. That is pretty cmuch in line with my own non-structured benchmarking of code. <wingo>you mean -O3 vs -O2 perhaps? <wingo>-O2 is significantly better than -O1 <wingo>also note that the meaning of -O1 changed in master to also include -Oresolve-primitives <wingo>which it had excluded previously for $reasons <lloda>is it fair to see that @@ shouldn't be used inside Guile? <wingo>lloda: inside guile it's fair game <wingo>but better to export interfaces that are important <wingo>i mean to say it's totally possible but best to design something we aren't ashamed of :) <lloda>I used (@@ (ice-9 arrays) array-print-prefix) in pretty-print b/c I didn't want to export it <lloda>but then I used it outside Guile <lloda>but again I don't want to export it if I'm the only user :-| <wingo>lloda: in this case i think it's fine :) <wingo>like if it breaks you are holding both pieces and it's your fault ;) <wingo>but probably since you are holding both pieces it won't break! ***jr0_ is now known as jr0
***deesix_ is now known as deesix
***sneek_ is now known as sneek
<bjoli>Did you ever feel that you couldn't fizzbuzz fast enough? Look no further, I have made a (really just one procedure) module to generate wheels: https://git.sr.ht/~bjoli/wheel-utils. Now you can fizz and buzz at twice the speed, generating gigabytes of fizzing and buzzing data! <bjoli>i had it lying around. Some old code from 15 years ago when I did programming in HS. My teacher did not like that solution, even though it was by far the fastest and simplest to extend. Bless his poor soul. <bjoli>nah, I just implemented everything in scheme and ported it to whatever programming language we had to use. <chrislck>very interesting that every lisp hacker has their own style :) <dsmith-work>I guess Scheme is malleable enough that it can encode your ideas directly *chrislck made it a personal mission to eradicate most unreasonable set! from gnucash, and this is now nearly complete <dsmith-work>A long time ago, you could make guile code faster by using set! everywhere (less garbage to collect) <chrislck>also many, many loops reduced to 1 to minimise nested loops 🕺 <bjoli>Isn't also one problem that set! implicitly boxes things? <bjoli>which makes type inference not work properly and all that jazz? <civodul>wingo_: thanks a lot for the statprof fix, you made my day! :-) <civodul>wingo_: so the reap-pipes issue is indeed very weird <civodul>i guess running hooks is quite expensive because they're written in C <civodul>but i wonder if that's the only explanation <wingo_>i think that's not the explanation, guile already has some after-gc hooks for other reasons i think <wingo_>i think that hook is somehow busted; not sure tho <civodul>oh and i had forgotten that 'syntax-source' is written in terms of 'source-properties' <civodul>no wonder we're putting pressure on source-whash ***wingo_ is now known as wingo
<wingo>yeah would be nice to have a better reader! <terpri_>bjoli, i used to write tiny sets of lisp primitives in c and used it for all my cs homework (ignoring gc, etc.) <terpri_>probably looked very strange to my professors, but i never got a complaint about it :) <wingo>dsmith-work: would be nice if it returned datums + source location info <wingo>instead of datums + noodling around with weak source location table <civodul>wingo: there could be a "source" slot in syntax objects, just like for tree-il <nixfreak54>Does anyone have articles , tutorials on how to use guile for everything especially replacing it with bash scripts ? I'm looking for a language that I can script anything with , sort of like python <justin_smith>it just means "this looks cool, I tried it, but haven't used it enough to really judge it" <justin_smith>in other words, I used it for fun, but didn't have a reason to be angry at it yet :D <bjoli>wingo: there has to be more or less portable readers available, no? Or is one of the catches that it has to be in C? ***bjoli is now known as manumanumanu
<manumanumanu>the chez reader seems _ok_, and should be a lot simpler once a lot of the chez specific stuff is removed. I don't really understand the licensing stuff, though. <civodul>manumanumanu: i think there'd have to be an implementation in C <civodul>earlier wingo suggested that it could be Scheme code "transpiled" to C <ArneBab>I’ve been unable to guix pull for two months now — recently started upgrading directly from a git clone. Do you have a hint how I can fix that? <ArneBab>building /gnu/store/kmzfd8avp1qskknh4z62birwvdja9ixy-module-import-compiled.drv... 4% [##### ]builder for `/gnu/store/kmzfd8avp1qskknh4z62birwvdja9ixy-module-import-compiled.drv' failed with exit code 1 <manumanumanu>chrislck: your work on the gnucash codebase is amazing. I suspect it has gotten faster as a result. <manumanumanu>regarding match: i have the pattern (name . children), and I want to check name against a predicat. Is that possible with the (? pred? name) way? <manumanumanu>ie: i want to match a (name . children), but only if name satisfies a predicate <rekado>manumanumanu: yes, this should work <rekado>this will not match: (match '(12 "world") (((? string? name) . rest) name)) <rekado>but this will: (match '("hello" "world") (((? string? name) . rest) name)) <mwette>(match '(name . "value") ((? (lambda (p) (symbol? (car p)))) #t) (_ #f)) => #t