!EjsgbQQNuTfHXQoiax:matrix.org

BQN

220 Members
The BQN array programming language, an APL descendant13 Servers

Load older messages


SenderMessageTime
29 Nov 2021
@dzaima:matrix.orgdzaimathus, if there's no REPL, the GC just doesn't happen22:27:23
@ashermancinelli:matrix.orgashermancinelliyeah that's not that different from just letting the OS free whatever you leaked in the case of running a script then, yeah?22:27:24
@ashermancinelli:matrix.orgashermancinelliwell that makes me feel a little better haha22:27:50
@dzaima:matrix.orgdzaima from what I understood, there's some magic CC<whatever> from a library that rowan uses for automatic GCing of references. i have no clue what magic makes it possible 22:29:46
@ashermancinelli:matrix.orgashermancinellihm. well you'd still have to help it mark things I'd imagine, but maybe the magic is just in the cycle detection?22:31:19
@dzaima:matrix.orgdzaima also it's got bacon in the name, so you can't not use it 22:35:32
@dzaima:matrix.orgdzaima can't tell if that thing even can free cycles that don't involve weak pointers actually. But this seems more proper-ish - it seems to maybe somehow differentiate being stored in a structure vs being a top-level reference or something? (which is the proper thing to do, it's just that that's hard if you can't just detect that) 22:43:51
@_discord_355917200466640898:t2bot.iorowan i think it should be able to but i havent attempted gc yet. i think mark/trace is a much easier way to start then progress to something like what golang does 22:49:41
@_discord_355917200466640898:t2bot.iorowan the paper is http://researcher.watson.ibm.com/researcher/files/us-bacon/Bacon01Concurrent.pdf 22:50:56
@dzaima:matrix.orgdzaimathat's a generic GC paper. The important question, orthogonal to the paper, is retrieving the list of roots22:52:07
@_discord_355917200466640898:t2bot.iorowan this is what i did in erlang vm
i think it worked out alright but its been a while
https://github.com/cannadayr/ebqn/blob/main/src/ebqn_gc.erl#L69
22:53:50
@ashermancinelli:matrix.orgashermancinelli

well if that's semistandard, then CXBQN has a much better startup time:

$ time ./BQN -e '2+2'

real    0m0.140s
user    0m0.098s
sys     0m0.042s
23:15:47
@mlochbaum:matrix.orgMarshall
In reply to @ashermancinelli:matrix.org
Video on the BQN VM/runtime/compiler in case you're only on matrix

Great work on the visualization here! Added a link to the VM page.

23:22:34
@ashermancinelli:matrix.orgashermancinelliHey thanks!23:22:48
@ashermancinelli:matrix.orgashermancinelliHopefully I didn't say/show anything too misleading.23:23:46
@mlochbaum:matrix.orgMarshall

Well I did just change the JS line count from "about 500" to "about 600", but 667 still is about 500.

23:25:18
@mlochbaum:matrix.orgMarshall

Also documented NOTM. It's in a weird spot because it's basically a special case of VFYM, which I classified as a header-related opcode, even though NOTM isn't header-specific.

23:26:14
@ashermancinelli:matrix.orgashermancinelliIt's ~500 when compared to the number I assumed it would be when I first started learning about the VM, and assumed it would be closer to lua's23:26:22
@mlochbaum:matrix.orgMarshallCounting things like the random number generator utilities is kind of silly anyway.23:28:00
@ashermancinelli:matrix.orgashermancinelliYeah, I mean that vm animation is actually a dummed down version of the actual vm in js, so you could swap another comp unit in there and those slides/animations would still work. It's gotta be pretty simple for something like that.23:29:22
@dzaima:matrix.orgdzaima bytecode tests still have an old name for NOTM 23:29:25
@mlochbaum:matrix.orgMarshallYeah I think I gave that one up before I even got an implementation working.23:32:32
@ashermancinelli:matrix.orgashermancinelliI think it would be kinda fun to jump on a call/do a livestream where we hack together a vm as a community23:33:12
@mlochbaum:matrix.orgMarshallThat could work.23:34:27
@ashermancinelli:matrix.orgashermancinelliMight make the language seem more accessible to folks23:35:01
@mlochbaum:matrix.orgMarshallI guess you get a good feel for the array model, but the interesting primitives do stay locked away in r1, until you get to implement those.23:37:37
@mlochbaum:matrix.orgMarshall

I haven't explicitly said this yet, so 1.0 status report: features here are mostly marked with their fates now.

23:41:06
@mlochbaum:matrix.orgMarshall

I think I'll remove modifier partial application and returns from the spec now as I don't know that I want them in the language, that is, they might not be useful enough to justify the complexity.

23:42:00
@ashermancinelli:matrix.orgashermancinelliHey! How exciting!23:43:15
@mlochbaum:matrix.orgMarshall

High-rank [] syntax is the only major feature missing now. Other than that there's some spec writing for already-implemented features, and the tricky Under cases like ⌾∾. I'll take a stab at those and either get them supported or make them optional in the spec (and hopefully finish them later).

23:44:20

There are no newer messages yet.


Back to Room List