🦋 Welcome to the IRC channel of the core developers of the Raku Programming Language (raku.org #rakulang). This channel is logged for the purpose of history keeping about its development | evalbot usage: 'm: say 3;' or /msg camelia m: ... | Logs available at irclogs.raku.org/raku-dev/live.html | For MoarVM see #moarvm
Set by lizmat on 8 June 2022.
01:04 MasterDuke joined
MasterDuke i've been experimenting with using collections from fastutil in the jvm backend. i was hoping it would help with memory usage (and speed), but i don't think it has so far. however, i have almost no experience profiling java programs, so i may just be missing something... 01:13
[Coke] put a pr together so folks can profile it? 02:12
MasterDuke yeah, probably will do that. i managed to get a little further with profiling, but i have only figured out how to start a profile of an already running program, which makes it hard to see total change... 02:17
if i'm reading things correctly, the jvm backend is spending almost all the time in runNFA (github.com/Raku/nqp/blob/main/src/...ava#L6767) 03:00
i think i've reduced the allocated objects in there by a lot, but can't tell if that's sped anything up 03:01
Voldenet profiler is useful for finding out hot code, but not useful for benchmarking it 03:10
to find out speed gains you need something like jmh 03:12
MasterDuke yeah. the problem with benchmarking this is finding something short enough that i can easily run it repeatedly, but actually exercises these code paths
Voldenet I'd consider serializing NFAInstance and mocking ThreadContext for the microbenchmark 03:15
maybe Kryo could deal with it 03:18
MasterDuke i've never used any of those tools. if you're able to get it working and tell me how it'd be much appreciated. really the biggest thing right now is that rakudo doesn't even build. `java.nio.BufferOverflowException in consume-line-chars (gen/jvm/stage2/NQPCORE>setting:824)` 03:25
anyway, i'm done for the night 03:37
07:43 sena_kun joined
Voldenet >the biggest thing right now is that rakudo doesn't even build 09:38
lizmat I guess I borked it?
could you give me a gist of the build? 09:39
10:00 finanalyst joined
Voldenet 0x0.st/HR8M.txt 10:51
releasable6 Next release in ≈3 days and ≈7 hours. There are no known blockers. Please log your changes in the ChangeLog: github.com/rakudo/rakudo/wiki/ChangeLog-Draft 11:00
Geth rakudo/main: adc30f399e | (Elizabeth Mattijsen)++ | src/vm/moar/dispatchers.nqp
HOW.archetypes is an instance method

So doesn't need any arguments
11:55
rakudo/main: 11e5ced2bb | (Elizabeth Mattijsen)++ | src/Perl6/Actions.nqp
HOW.archetypes is an instance method

Also some minor refactoring
12:01
lizmat Voldenet: I can't find the string "reverse" in the moar version, so I'm not sure wtf is going on 12:11
Geth rakudo/main: 24a1e67c43 | (Elizabeth Mattijsen)++ | src/Perl6/Metamodel/Archetypes.nqp
Streamline Archetypes creation

  - make all attributes native int, so they will default to 0
  - use bespoke new method setting attribute only if necessary
13:04
rakudo/main: 6f42c89715 | (Elizabeth Mattijsen)++ | src/Perl6/Optimizer.nqp
HOW.archetypes is an instance method
13:13
rakudo/main: 3267834f27 | (Elizabeth Mattijsen)++ | src/vm/moar/Perl6/Ops.nqp
HOW.archetypes is an instance method
13:22
rakudo/main: b168277b46 | (Elizabeth Mattijsen)++ | src/Perl6/World.nqp
HOW.archetypes is an instance method
13:32
rakudo/main: a3bb844431 | (Elizabeth Mattijsen)++ | src/Perl6/bootstrap.c/BOOTSTRAP.nqp
HOW.archetypes is an instance method
13:43
rakudo/main: 8ca1c48263 | (Elizabeth Mattijsen)++ | src/Perl6/Metamodel/GenericHOW.nqp
HOW.archetypes is an instance method
13:52
vrurg lizmat: are you sure all these locations deal with type objects and type obejcts only? Because an instance of a class might happen to be generic while its class is not. 14:15
lizmat the positional arg in the method is ignored, so yes :-) 14:16
vrurg Class' archetypes is not ignoring it.
For example, $!default in BOOTSTRAP line 1188 can be a concrete object reporting itself as a generic. 14:20
Similarly, line 1757 – $avc. And it's just a quick glance at one commit. 14:23
The argument can only be ignored if the method is invoked on a typeobject.
lizmat but where are the cases of "method archetypes" then handling those cases? 14:24
vrurg Pardon, what do you mean?
If I get you right, then see ClassHOW archetype. 14:25
Its outcome may depend on argument conretnedness.
lizmat I will in a mo, in a meeting atm 14:31
vrurg No problem. In the meantime, these would most definitely break WWW::GCloud because it depends on generic instances. Blin would detect it, but would have hard times determining which exact commit did it. :) 14:34
jdv a blin run on 3c9f07a was clean 14:45
i got rid of the fast way of doing blin so i hope that the only one we need to do 14:46
aka try not to break the build before 2/29:)
used to take 2h, now 8h for me
lizmat vrurg: ok, I guess I'm going to revisit some of the commits :-) 14:49
vrurg: so basically, in the case of foo.archetypes(foo) it's safe to remove the positional, right ? 14:52
too bad, they made core parse .5 second faster
vrurg Only if foo is a typeobject. Method outcome is invariant over types – I just can't imagine how could that be different. But a concrete object may serve as a container for a generic type. For example, a container descriptor is not generic type but it may keep record of generics requiring resoslution. 14:56
Geth rakudo/main: ad9fe2eba1 | (Elizabeth Mattijsen)++ | 7 files
Revert all "HOW.archetypes is an instance method" commits

As vrurg++ pointed out there are some MOP classes that *do* depend on the value passed. Too bad this optimization is not possible for this reason: it did scrape off .5 second from parsing the setting for me.
15:12
lizmat jdv vrurg ^^
vrurg ++. As to the optimization side of the things – wish there be other way around to correctly instantiate attributes. 15:14
lizmat yeah :-( 15:15
Geth rakudo/main: 4181d46105 | (Elizabeth Mattijsen)++ | 4 files
All Archetypes class (should) support .coercive

Both in Raku and NQP. So there is no need to check if they can call a method called 'coercive'.
15:25
lizmat at least that part can go in :-)
vrurg: re .archetypes(foo), isn't the issue really that we should have different HOWs for generic classes and non-generic classes ? 15:51
vrurg I would only complicate things. BTW, a class itself can't be generic, only its instance. And instances are all about runtime. 15:54
*It would
jdv huh?
vrurg is afk 15:55
lizmat too
15:57 finanalyst left
lizmat notable6: weekly 17:04
notable6 lizmat, 1 note: 2024-02-24T20:27:24Z <antononcube>: rakuforprediction.wordpress.com/20...s-zombies/
lizmat notable6: weekly reset 17:17
notable6 lizmat, Moved existing notes to “weekly_2024-02-26T17:17:03Z”
18:11 lizmat left, heartburn left, lizmat joined 18:19 heartburn joined
lizmat m: sub a($/) { dd $0, $1 }; a (42,666) # TIL :-) 18:36
camelia 42
666
lizmat and yet another Rakudo Weekly News hits the Net: rakudoweekly.blog/2024/02/26/2024-...s-zombies/ 19:12
19:28 MasterDuke left
Geth rakudo/main: 2c64cbc729 | (Elizabeth Mattijsen)++ | src/Perl6/Metamodel/DefiniteHOW.nqp
Streamline Metamodel::DefiniteHOW a bit

  - remove unnecessary args from archetype creation
  - remove istrue check: archetype methods are now guaranteed to
   return either 0 or 1
20:05
21:15 finanalyst joined 21:35 sena_kun left, sena_kun joined 21:44 MasterDuke joined
MasterDuke Voldenet, lizmat: i fixed that error already, rakudo just hasn't bumped NQP yet 21:47
Voldenet oh, that sounds easy
but I bet it still doesn't work even after 21:48
MasterDuke i fixed the `&reverse not found` error, now i get the java.nio.BufferOverflowException
Voldenet Yep, I confirm that using nqp e3225825d works 22:29
linkable6 (2024-02-24) github.com/Raku/nqp/commit/e3225825d5 Unbreak JVM build
22:33 finanalyst left 23:05 sena_kun left