japhb MasterDuke: intarray[int32]? 00:01
(Just guessing that the parameterization is on native int size) 00:02
MasterDuke ah
m: my int32 @a; say @a.^roles
evalable6 ((array::intarray[int32]) (Positional[int32]) (Iterable))
MasterDuke japhb++ 00:03
MasterDuke m: constant N = 1_000_000; my int @a[N]; @a[$_] = $_ for ^N; say @a[N-1]; say now - INIT now 00:27
evalable6 999999
4.92626373
MasterDuke ^^^ hits github.com/rakudo/rakudo/blob/mast...tch.nqp#L4 (find_method) 1_000_000 times where it's looking for ASSIGN-POS in array[int] 00:28
and github.com/rakudo/rakudo/blob/mast...ng.nqp#L14 is hit 2_000_000 times 00:30
m: constant N = 1_000_000; my int @a; @a[$_] = $_ for ^N; say @a[N-1]; say now - INIT now # the unshaped version doesn't hit those (find_method and type_check) 00:38
evalable6 999999
0.1614093
|Tux| Rakudo version 2020.02.1-98-gcf01f7a25 - MoarVM version 2020.02.1-35-ga7fa6daad
csv-ip5xs0.694 - 0.694
csv-ip5xs-205.649 - 5.720
csv-parser23.081 - 23.299
csv-test-xs-200.361 - 0.361
test7.515 - 7.642
test-t1.839 - 1.863
test-t --race0.838 - 0.871
test-t-2030.356 - 31.413
test-t-20 --race8.911 - 9.106
09:54
Xliff . 20:10
o/
I had an idea last night and I believe I've brought up parts of it, but I'd like to bring it up here for consideration. 20:11
I'd like to discuss the feasibility of having perl6 compile .moarvm code so that it can be stored in a database with BLOB support. 20:12
How feasible is this with the current implementation? I know I can do the storage part, already using --target and --output. 20:13
Retrieval is easy enough.
What about execution?
Would a `sub EVAL (Blob)` function work? In my mind, the return value would be a CompUnit that one could then massage into something executable. 20:15
jnthn What's the use case? 20:16
Xliff An application server.
jnthn Remember that a compiler upgrade invalidates all the blobs. :)
Or any dependent module update. 20:17
Xliff True, but that would be at the app server leve.
All modules would be in the database.
jnthn But anyway, I'd take a look at CompUnitRepo stuff
Also maybe precompilation store
I think alternative impls of those could be used to achieve this.
Xliff Yes. My thought were along those lines. I was falling asleep at the time, but was wondering if current rakudo would be up to this. 20:18
The application server would need to reimplement much of the loader functionality for this to work. I am wary that the current code is not modular enough to accommodate this. 20:19
jnthn In theory it's possible, and we won't know in practice until somebody tries. 20:20
Xliff OK. Then I will have to look into it. 20:21
Do you think a write-up of this might be worth a grant from the TPF?
vrurg_ Xliff: you should try, I think. 20:25
Xliff vrurg: I think so, too. However my time has become very limited, these days. 20:28
Thanks, everyone! I have a some things to think about. :) 20:46
o7
MasterDuke jnthn: got a couple minutes for questions? 20:53
discord6 <how-1ie> What's the TPF? 22:03
leont The Perl Foundation 22:04