For sure it works, because it's the most primitive hack one can think of. But it doesn't scale when the filesystem locking gets in your way, esp. on slow systems. In Perl we did something similar with an embedded tcc, but then eventually switched to emit machine-code directly to memory, or using llvm with linked bitcode, as later done in postgresql.
Shame that his stack branch also got turned down, because this was more important.