🦋 Welcome to the MAIN() IRC channel of the Raku Programming Language (raku.org). Log available at irclogs.raku.org/raku/live.html . If you're a beginner, you can also check out the #raku-beginner channel!
Set by lizmat on 6 September 2022.
00:06 reportable6 left 00:08 reportable6 joined 00:10 justache joined 00:38 derpydoo joined 00:41 MasterDuke left 00:58 MasterDuke joined 01:46 tejr joined 02:44 sortiz joined
avuserow back on the memory investigation train. if I do `for ^100 {CArray[uint8].allocate(bignum)}` then it eats up memory, but it stays under control if I manually use `nqp::force_gc` 02:54
my actual program does much fewer allocations but a much larger number of iterations, so I need to see if I am leaking memory somewhere else first 02:55
02:55 razetime joined
MasterDuke --profile-kind=heap will generate heap snapshots, which you can analyze with p6-app-moarvm-heapanalyzer. jnthn, timo, or nine are the best people to ask about how to use it 03:09
hm, `use NativeCall; for ^100_000 {CArray[uint8].allocate(10_000_000)}` does seem to leak a bunch in bind_pos() at the c/moarvm level, even with --full-cleanup... 03:13
and even if i add `VM.request-garbage-collection; VM.request-garbage-collection` before it exits... 03:19
avuserow is VM.request-garbage-collection the different from nqp::force_gc? 03:20
MasterDuke it's just a higher level api for it. all it does is call nqp::force_gc if running on the moarvm backend and warn that it's unsupported on the others 03:22
avuserow thanks, good to know :)
okay so at least some of my issue was a C-side memory leak. I might actually be fine to run this on my entire data set. 03:23
MasterDuke well, i'm not *entirely* sure it's a memory leak. --full-cleanup is not 100% effective. it's pretty good, but there are still some things it doesn't get. and heaptrack (what it am using to detect the leaks) doesn't know anything about moarvm/rakudo's garbage collection. so there's still a chance that what i'm seeing is just a red herring 03:26
but i'd suggest pinging nine. he knows this area (especially NativeCall) much better than i do and might have some suggestions 03:28
avuserow thanks for the insight. I'll see if I can golf something down and drop it in a dev channel 03:31
MasterDuke doh, it may have been killed and that's why heaptrack saw a leak. if i drop it down to 10_000 iterations and allocate(1_000_000) it says there's no leaks, and i see the CArray freeing function being called 03:34
avuserow doing 100 iterations of allocating 100MB (= 10GB total) definitely grabs 10GB of RAM. valgrind says "still reachable: 10,485,763,987 bytes in 114 blocks" 03:39
with a force_gc I get "still reachable: 104,861,587 bytes in 15 blocks" 03:40
(the other losses are the same as an empty program)
running with --full-cleanup makes it all clean, so maybe this is just a pathological use case :) 03:46
03:55 linkable6 left, evalable6 left 03:56 linkable6 joined 03:57 evalable6 joined 04:07 derpydoo left 04:10 razetime left 04:59 razetime joined 05:01 derpydoo joined 06:01 sourceable6 left, benchable6 left, quotable6 left, evalable6 left, coverable6 left, committable6 left, tellable6 left, greppable6 left, bloatable6 left, notable6 left, shareable6 left, linkable6 left, statisfiable6 left, nativecallable6 left, unicodable6 left, releasable6 left, squashable6 left, reportable6 left, bisectable6 left, benchable6 joined, releasable6 joined 06:02 evalable6 joined, coverable6 joined, sourceable6 joined, unicodable6 joined, reportable6 joined, nativecallable6 joined, committable6 joined, tellable6 joined 06:03 bisectable6 joined, greppable6 joined, quotable6 joined, squashable6 joined, shareable6 joined, statisfiable6 joined 06:04 linkable6 joined, bloatable6 joined, notable6 joined 06:11 Sauvin left 06:12 Sauvin joined 06:14 Bocaneri joined, Bocaneri is now known as Guest5611 06:17 Sauvin left 07:03 razetime left, abraxxa joined 07:07 abraxxa left 07:08 abraxxa joined 07:11 razetime joined 07:14 razetime left 07:41 sena_kun joined 07:42 Sgeo_ left 08:10 sortiz left 08:15 Bocaneri joined 08:16 Bocaneri is now known as Guest1505 08:18 Guest5611 left 08:58 dakkar joined 09:12 abraxxa left 09:13 abraxxa joined 09:17 bigfondue left 09:30 derpydoo left 09:45 epony joined 10:24 Guest1505 is now known as Sauvin 10:37 leont left, rjbs left, zostay left, rjbs joined, zostay joined, tbrowder left, SmokeMachine left 10:38 SmokeMachine joined, tbrowder joined 10:39 leont joined 10:59 razetime joined 11:37 holly joined, sena_kun left 11:39 sena_kun joined 11:50 xinming left 11:52 xinming joined 12:06 reportable6 left 12:07 reportable6 joined 12:12 holly left 12:59 tecks joined
lizmat And another Rakudo Weekly News hits the Net: rakudoweekly.blog/2022/11/07/2022-...aluersion/ 13:06
13:25 squashable6 left 13:28 squashable6 joined 13:31 derpydoo joined 13:35 tecks is now known as holly
Xliff lizmat++ 13:39
in "sub MAIN ( :$a #= HOWDY ) { ... }" is there an easy way to get the parameter object for $a? 13:40
m: sub a ($a) { &?ROUTINE.signature.params.head.name.say }; a() 13:41
camelia ===SORRY!=== Error while compiling <tmp>
Calling a() will never work with declared signature ($a)
at <tmp>:1
------> UTINE.signature.params.head.name.say }; ⏏a()
Xliff m: sub a ($a) { &?ROUTINE.signature.params.head.name.say }; a(1)
camelia $a
Xliff Hmmm...
13:47 simcop2387 left 13:50 simcop2387 joined 14:01 razetime left 14:02 razetime joined 14:22 holly left
Nemokosch Re Hackernews on Tcl, Python and GIL 14:25
> Raku is also, unfortunately, the slowest language I've ever used especially, paradoxically, for regex and string handling given its Perl lineage.
It's kinda weird, though, because the same people tend to take it as an axiom that better language design made Python win over Perl (and Tcl) *despite* worse performance 14:27
This reminds me - vrurg: any news about the Rakudo crashcourse? 14:29
14:38 Sgeo joined 14:41 abraxxa left 15:15 derpydoo left
razetime startup time for any language is something a lot of people complain about 15:33
but otherwise raku feels about as slow as any other scripting language i use 15:34
vrurg Nemokosch: stuck with my jobs, barely have spare time. Almost re-started working on it yesterday until a new serious error popped up. :( 15:36
tellable6 vrurg, I'll pass your message to Nemokosch
vrurg razetime: normally, startup is slow due to precomps taking long. Do you update your code often? 15:37
razetime update my code?
like, my raku build or my local code
vrurg your local code.
razetime yeah, I suppose I do. Generally start my work in the repl and transfer over 15:38
vrurg Normally the rule of thumb: move as much as you can of you scripts into modules. A script gets compiled every run while modules are precompiled. I tend to reduce my scripts to something like `use MyApp; MyApp.run` 15:39
Second, if you use rakubrew then better use 'env' over 'shim'. The latter includes perl startup too. 15:40
vrurg is afk again...
Anton Antonov Good to know! I moved to using "shim" a year ago... 15:43
16:15 evalable6 left, linkable6 left, linkable6 joined 16:17 evalable6 joined
Nemokosch > And, in fact, the ~~ operator works as a small topicalizer; that is, it binds $_ to the value of the left side for the evaluation of the right side. Use the underlying .ACCEPTS form to avoid this topicalization. 16:31
It's not "Rakudo behavior" at least.
Okay, the design document is clearly not authoritative anymore 16:45
lizmat indeed, they are not
Nemokosch there's loads of useful stuff in there 16:51
is it common that Rakudo fails Roast tests? 16:52
I mean not accidentally but long-term
lizmat there are a few flappers... but generally it should be clean 16:55
All tests successful.
Files=1355, Tests=116442, 206 wallclock secs (16.64 usr 3.97 sys + 1238.14 cusr 59.56 csys = 1318.31 CPU)
Result: PASS
Sat Nov 5 23:55:42 CET 2022
was the last one I ran
Nemokosch I'm still thinking about smartmatch on Matches 17:02
but anyway, these design documents are invaluable regarding the tiny little details and motives that they contain
17:04 swaggboi left
lizmat agree :) 17:05
17:05 derpydoo joined 17:17 swaggboi joined 17:22 razetime left 17:37 dakkar left
Anton Antonov @lizmat I think using Jupyter is many ways like use vi -- if you try the former you might like it. 17:39
lizmat Perhaps... but my fingers were first mangled by Wordstar, then WordPerfect, then vi, then vim.... 17:40
and inbetween all of that, I even *wrote* an editor for a system now long lost in the mists of time :-) 17:41
Anton Antonov @lizmat I understand -- for the record I stay away from Jupyter as much I as it is possible. Also, I prefer using emacs. 🙂 17:44
lizmat :-)
Nemokosch Is there anyone under 40 who is using emacs and doesn't have a degree in mathematics in particular? 17:47
Anton Antonov <@297037173541175296> I definitely have not met anyone using emacs under 35... (I am not sure about < 40.) 17:52
18:06 reportable6 left 18:07 reportable6 joined
[Coke] I think all the emacs users I know were in college with me (or older), so nope. :) 18:19
though I myself am a diehard vi/m user, having learned vi on the mainframe because it was better than the alternatives and transferable to the *nix boxes.
Is Anton Antonov the person who recently released 2 raku vids on youtube? 18:20
Either way, hello.
Nemokosch that's one way to put it 😉 18:22
El_Che [Coke]: some people have an old soul 18:31
[Coke]: and 20 fingers
xinming Nemokosch: me, 37 using emacs and a junior school drop out. :-) 18:32
tellable6 xinming, I'll pass your message to Nemokosch
El_Che cirrus ci is so slow, that working on a automatic integration with github releases and cloudsmith may be a waste of time. So a simple manual script after the build may suffice to release arm64 builds 18:33
cirrus waited 30 minutes for start building and then build each pkg one by one, so it will take hours :) 18:34
xinming I was a full-day emacs user beforef, there is a time where I need to edit config file on slow network frequently, and I found emacs slowing start is quite boring in this case, I started to use vim. and I don't remember when I switched most of my editing to vim anyway. 18:36
El_Che accordingly, failing tests is extra painful on cirrus 18:38
avuserow Some of my classmates from college picked up emacs and they would be <35. Though vim was the popular editor on campus (due to being recommended in some classes). 18:40
El_Che I picked up vi(m) because it was the only thing you could be sure it was installed on alle the different unix machines 18:43
I have nothing against emacs, but it's good for joking :)
like the :q! jokes for vim 18:44
Nemokosch same tbh
I can easily imagine your average Emacs is actually better than Vim or even Neovim possibly 18:45
but that doesn't create a userbase...
lizmat how many people are using Dvorak keyboard layouts rather than qwerty / qwerzu /azerty ? 18:48
[Coke] qwerty here - I got good enough that it wasn't worth switching to eke out a few wpm
lizmat well, same for me... and I'm still typing with only 5 fingers :-) 18:49
Nemokosch Pretty much the same. I didn't count the amount but I'm definitely not using that cool 10 finger system
never had to type so much that it would become a bottleneck 18:50
but I'm even worse on phone...
lucs I type with most of my fingers, but not especially for speed, more because I don't need to look at the keyboard. 18:51
Nemokosch I'm literally using touch screen like a grandma would. Keep it in one hand, press it with the index finger
lucs And anyway, I can already type faster than I can think (which is not very fast, eh).
Nemokosch: That's how I type on my phone :) 18:52
tellable6 lucs, I'll pass your message to Nemokosch
Anton Antonov vi == kitchen knife; emacs == laser saber | vi == Ford Model T; emacs == Tesla Model S 19:04
My analogies above might appear a little biased… 19:05
tonyo never seen a practical light saber in real life so that seems fair : )
tellable6 2022-11-04T12:59:29Z #raku <tbrowder> tonyo: if you plan to close those pending fixes in CSV::Parser, i will abandon my simple csv parser.
lizmat imagines editing with light saber sounds :-) 19:06
lucs Only just a little bit 🙂
tonyo tbrowder: i do plan to revamp it, i can prioritize it. i'm currently working on my own start up and working full time so i'm working on raku when i need a break from go/typescript/python 19:07
19:07 linkable6 left, evalable6 left 19:08 evalable6 joined, linkable6 joined
tbrowder ok, no problem, i can use it as is and hide tmp work-arounds, good luck on yr endeavors! 19:09
tonyo thanks my man
tbrowder 👍🏻
19:11 Nemokosch joined
Nemokosch . 19:12
tellable6 2022-11-04T18:35:26Z #raku <tbrowder> Nemokosch: no, it’s unpublished, and probably not needed (CSV::Parser::Simple)
2022-11-07T15:36:05Z #raku <vrurg> Nemokosch: stuck with my jobs, barely have spare time. Almost re-started working on it yesterday until a new serious error popped up. :(
2022-11-07T18:32:29Z #raku <xinming> Nemokosch: me, 37 using emacs and a junior school drop out. :-)
2022-11-07T18:52:27Z #raku <lucs> Nemokosch: That's how I type on my phone :)
Nemokosch o.O
19:12 Nemokosch left
Anton Antonov @lizmat There was an MacOS app that would do laser saber effects : osxdaily.com/2006/12/06/macsaber-t...ightsaber/ 19:12
lizmat hehe :-) 19:13
Anton Antonov Of course also consider this appeal to authority : xkcd.com/378/ 19:15
Nemokosch yeah... butterflies
lizmat hehe yeah, nice one 19:16
19:24 m_athias left, perryprog left, tiziodcaio left, spacekookie left, spacekookie_ joined, perryprog_ joined, m_athias joined 19:26 perryprog_ is now known as perryprog
tbrowder anyone know where 2023 raku conf us or canada will be? i heard site is selected but haven’t heard any more 19:26
heard where
Anton Antonov <@755062053282119803> Interesting question! 19:29
19:32 tiziodcaio joined
tonyo tbrowder: those fixes are already in, i use the close-pending tag to let someone know i think their issue is resolved and as a reminder to myself that after 7 days of no response i'm okay to close 19:33
if you grab 0.1.3 you should have all of those `close-pending` tags resolved
tbrowder okey dokey 19:34
19:36 melezhik joined
melezhik o/ 19:36
I've made an example CI build for different Rakudos/Linux Distros for raku-audio-taglib - last 4 builds on ci.sparrowhub.io - this is how one can test Rakudo modules that require distro specific tests and also want to measure tests time change  over recent Rakudo releases 19:39
19:41 irc_user joined 19:49 melezhik left
Nemokosch reiteration: lambert lum is looking for raku speakers for svperl on Jan 5, 2023 19:54
El_Che sverige? 20:00
Nemokosch silicon valley 🙂 20:04
from what I heard, online presentations are also welcome
20:04 bigfondue joined
tonyo what kind of speakers? 20:11
i have some vandersteens
El_Che mr high-end audio 20:12
Nemokosch I don't know a lot about it but as it has "Perl" in the name so I was immediately told that it's good to aim entry-level
tonyo El_Che: a very lucky local record store find 20:13
El_Che nice 20:35
21:04 linkable6 left, evalable6 left 21:06 evalable6 joined, linkable6 joined 21:14 derpydoo left 21:27 swaggboi left 21:31 jjido joined 21:41 swaggboi joined 22:41 irc_user left 22:42 sortiz joined
Nemokosch > github.com/rakudo/rakudo/pull/5095 22:58
is something like this tied to the MoarVM runtime or would it be shared across all Rakudo backends? trying to understand the architecture still 23:00
ugexe github.com/Raku/nqp/commit/2e7924c...55b20be443 23:01
23:05 jjido left
Nemokosch so kind of neither, or one could say "shared" as long as the backends properly implement NQP on their own 23:06
ugexe m: say -1.UInt 23:09
camelia -1
[Coke] m: say (-1).UInt 23:12
camelia Coercion to UInt out of range. Is: -1, should be in 0..^Inf
in block <unit> at <tmp> line 1
Nemokosch _points at the decision to not make negative numbers literals_
23:16 Nemokosch joined
Nemokosch m: say -1 .Uint 23:16
camelia No such method 'Uint' for invocant of type 'Int'. Did you mean any of
these: 'UInt', 'Int', 'List', 'gist', 'list', 'min', 'print', 'sin',
'sinh', 'sink'?
in block <unit> at <tmp> line 1
Nemokosch nothing that couldn't be fixed with a little hacking
lizmat that should be fixable
now, did you find a reason in the specs that shows why -1 is not codegenned as a literal ? 23:17
Nemokosch not gonna lie, it dropped low on the priority list and I didn't look hard 23:18
sena_kun Nemokosch, hi! re framework for the website: I cannot recommend any, but I'd rather avoid anything heavy. 23:19
tellable6 2022-10-16T21:13:18Z #raku-dev <[Coke]> sena_kun - did you cc me on that email?
2022-10-16T21:13:34Z #raku-dev <[Coke]> sena_kun that is, the infra email
sena_kun .tell [Coke] I certainly did, I believe. 23:20
tellable6 sena_kun, I'll pass your message to [Coke]
sena_kun goes to sleep
23:20 sena_kun left
Nemokosch well, good night :D that's some speedy sleep 23:20
m: my $works = :1a; my $fails = :-1a; 23:22
camelia ===SORRY!=== Error while compiling <tmp>
Malformed initializer
at <tmp>:1
------> my $works = :1a; my $fails = :⏏-1a;
expecting any of:
colon pair
Nemokosch lizmat: I don't feel stronly about ^ this in particular but it's another consequence of minus-as-operator-only at parsing
lizmat the :42a syntax is only for positive ints anyway 23:23
it was supposed to make things like :3rd and :2nd and :1st more readable, only positive ints 23:24
Nemokosch well well, I don't see this as a useful restriction, kinda neither-a-bug-nor-a-feature 23:25
guifa I mean, I suppose :- would be ungrammatical otherwise
at least, I'm trying to think where it would be grammatical
Nemokosch can't say it for sure but I think it only fails because negative numbers don't have literals 23:26
guifa Well I'm thinking where colons are used
they're used for adverbing
and no-parentheses method calling
but foo.bar:arg is invalid, you have to have a space
or it'd be interpreted as a subname thingy maybe 23:27
but an immediate minus would be a parse error there too
oh 23:28
Nemokosch well well 23:29
bluntly put: I think the grammar of Raku has several issues but many of them are by design and it might not be possible/worth it to fix that 23:30
m: [ && ](True, False) 23:31
camelia No such method 'CALL-ME' for invocant of type 'Array'
in block <unit> at <tmp> line 1
Nemokosch do you know this one? :P
either way, with most of the grammar issues, DIHWIDT seems fair. What seems safe is usually indeed safe 23:36
23:46 Nemokosch left