5 ms·
I can't imagine this working out for producing idiomatic code, especially between very divergent languages like Haskell and C++. Their example is almost straigh
by peacefulhat 6y ago
I can't imagine this working out for producing idiomatic code, especially between very divergent languages like Haskell and C++. Their example is almost straight syntactic replacement, not very impressive. And their real-world use-case is for migrating COBOL projects to python??
- disgruntledphd2 6y agoFacebook as a company do not believe in ever rewriting large code bases. You can view lots of their open source/technical achievements as out growths of this belief: - 2004, write PHP as it's fastest for now - 2008: PHP is too slow, compile it to C++ - 2011: C++ is too slow, write a VM and compile to assesmbly - 2012: PHP's type system sucks, write a better typer in OCaml (Hack) - They have done much the same for Javascript and Python (look at all the typing tools provided by Instagram). This stuff is just an outgrowth of their deep deep belief in writing code to handle the crazy amount of code they already have.
- solarkraft 6y agoHow well does that really work out? It seems like that would aggregate a lot of cruft, or are there ways around that?
- lathiat 6y agoI think the theory is a small subset of engineers can do work that speeds up the entire codebase for the rest of the engineers instead of spending time rewriting that entire code base and also retraining all of those engineers.
- Cthulhu_ 6y agoI think this is just it; at some point, code becomes a numbers game, an investment game. Rewriting their PHP codebase to, say, C++ would cost 10000 work-years, whereas creating HVVM cost 100 (random numbers) at a 1000% improvement in performance. Rewrites at that scale are really expensive and take forever, and by the time it's done they'll be running behind the facts already.
- disgruntledphd2 6y agoYeah, exactly. I like to think that Mark Zuckerberg read Joel's post and took it to heart. But the pattern is super noticeable for FB, once you start paying attention.
- PunchTornado 6y agoI think they chose the right strategy, compared to twitter which loves rewritting to another language.
- setzer22 6y agoTo be fair, there's a great use case for migrating COBOL to python. But I don't think banks would trust an automatic conversion done using ML...