Nova

Nova

@trynova.dev

a JavaScript (ECMAScript) and WebAssembly engine written in Rust and following data-oriented design principles

118 followers25 following11 posts

Nova reposted

trynova.dev/blog/garbage... Last Sunday I discovered that lifetimes on #Rustlang garbage collected handles should be contravariant on their lifetime parameter. This is an open research question, but I think this opens a path to meaningful lifetimes on self-referential structs. Check it out!

trynova.devGarbage collection is contrarian · NovaModeling unrooted handles to garbage collected data using contravariant lifetimes.
AapoAlas@aapoalas.trynova.dev

I'm being a total nutcase, but I found what I think is an important discovery about modeling garbage collected handles to the #Rustlang borrow checker: the lifetime of GC handles is contravariant! Instead of validity "rising up the call stack" it "droops down from the heap". Blog incoming!

Nova reposted

I'll be writing a year's end blog post on Nova JavaScript engine but here's something you can do while you wait (You were waiting for that, weren't you?): Star us on GitHub to make us break 1k stars before the year's end! Stars are the ultimate currency, after all.

Nova@trynova.dev

Nova JavaScript engine is only a hair's breadth away from 1k GitHub stars! Now that would be a nice way to end the year, wouldn't it?

The downside in a moving GC with unrooted stack values is that the engine needs to be very careful around things that could trigger GC: Thankfully Rust can make this a build-time check. The upside is that you see all the places where JS code can be called. It's terrifying: How does anything work!

It's not a big surprise that JIT compilers are notoriously complicated and dangerous: The number of edge cases that can call into user code is effectively unbounded. If we ever get into a JIT, let us hope it's very strongly typed!

You are up to date.