Hacker News new | ask | show | jobs
by tinco 3758 days ago
It's rather easy to add a calling convention to LLVM. If I would have to guess it would be that they thought LLVM was too slow for them. They said from the start compilation speed was a big point for them.

Also LLVM requires you to either write your IR in SSA or add another expensive optimisation pass to make it SSA (mem2reg). Perhaps they thought writing an SSA generator would be too much of a headache.

1 comments

The LLVM docs say that clang uses mem2reg for mutable local variables, so it can't be very slow.

From the end of

http://llvm.org/docs/tutorial/LangImpl7.html#memory-in-llvm

> Proven and well tested: clang uses this technique for local mutable variables. As such, the most common clients of LLVM are using this to handle a bulk of their variables. You can be sure that bugs are found fast and fixed early.