Lovely to see support for building escripts in the compiler.
I’d be excited to see that go one step further and provide something like the deno/bun/node compile feature, allowing one to export a binary that includes the BEAM and compiled code in a single file. I know some people are working on tools like that already and it’s not trivial, but having it in the compiler would be really neat.
Huh, I didn't know how much I needed a "todo" type until now. So often I'll be defining a packet sumtype, or a collection, and not have created the type yet, so just use ubyte, or Object, or whatever. Having an explicit "todo" type would be amazing in other languages.
The BEAM JIT is all done when .beam files are loaded. It's a runtime JIT, because you can always load new code, but it's not a tracing JIT and it's designed to be pretty fast to do it while loading. For most applications of BEAM, I think the time spent loading code, including JIT, is probably immaterial.
If you have a special need, I haven't seen anyone do it, but I would expect it wouldn't be that hard to run the jit ahead of time. I haven't fully studied it, but I think the expectation is the output from jit should be pretty much the same every run, so it seems doable to generate it once and load many times.
Compile to js target and leverage v8 compiler cache? I dunno, just riffing. You’re probably BEAMing vs js runtime-ing for server workloads, but periodically i compile to node and do stuff
J7jKW2AAsgXhWm | 22 days ago
sunjester | 22 days ago
m8s | 22 days ago
__jonas | 22 days ago
trescenzi | 22 days ago
3stacks | 22 days ago
batisteo | 22 days ago
> Black lives matter. Trans rights are human rights. No nazi bullsh*t.
Is it enforced? I just hope so.
sltr | 22 days ago
Defletter | 22 days ago
adamdecaf | 22 days ago
https://scala-lang.org/api/3.3.1/scala/Predef$.html#???-0
packetlost | 21 days ago
0xdeafbeef | 21 days ago
packetlost | 21 days ago
stevefan1999 | 22 days ago
toast0 | 22 days ago
If you have a special need, I haven't seen anyone do it, but I would expect it wouldn't be that hard to run the jit ahead of time. I haven't fully studied it, but I think the expectation is the output from jit should be pretty much the same every run, so it seems doable to generate it once and load many times.
cdaringe | 21 days ago
ofrzeta | 22 days ago
okkdev | 22 days ago