My team at Stripe is working on an experimental ahead-of-time compiler for Ruby and we’ve moved our development to open source. https://t.co/Bemnr3TsI7
@nikhilbarthwal @pvsukale @patrickc As for for creating a new language that would mean replacing not only the VM but also all the development tools we use on our Ruby, like linters and editors. That would greatly extend to our “time to value”
@nikhilbarthwal @pvsukale @patrickc It also allows us to release our compiler gradually. If there’s some Ruby we don’t compile correctly or efficiently we can just let the interpreter run it until we do.
@nikhilbarthwal @pvsukale @patrickc Not quite. We’re not replacing the MRI VM. What we’re doing is compiling Ruby code into native code and registering it with the VM. The VM and our compiled code interact via the MRI’s FFI mechanism
@cperciva@colemurray@patrickc Sorry, I can't say publicly what percent of latency is attributable to what cause, but I can say given how critical purchase flows are to our customers, every aspect of latency is worth our attention. Want to know more? We're hiring :)
@dbreunig@patrickc You got it! For two main reasons. The first is that Sorbet is the "front end" of our compiler (the parser and semantic analyzer+typer). The second is that many of the compiler's optimizations depend on the static type information that Sorbet provides.