Hacker News new | ask | show | jobs
by cosinusoidally 3781 days ago
Why didn't you use JavaScript for that purpose (in a similar vein to how LuaJIT uses Lua for dynasm)?
2 comments

I'm not a big fan of self-hosting. I like that you can build JavaScriptCore without using JavaScriptCore.
I wasn't really referring to self hosting. I was wondering whether it made sense to write tools like JavaScriptCore's offlineasm in JavaScript rather than Ruby (as LuaJIT does by using Lua for its dynasm tool). The LuaJIT build process actually builds a cut down copy for Lua for the purposes of running dynasm, which is then used to build parts of LuaJIT.
We spend time optimizing JavaScriptCore's build time. It's a hard problem and it's important when managing such a large project. People inevitably have to do clean builds and that sucks when you have >400k lines of C++ code.

So, naturally, we want to avoid building JSC twice. ;-)

Suppose that you are developing not to push this platform, but to simple do better on this platform. What does self-hosting gain you in that case?