|
|
|
|
|
by obl
2945 days ago
|
|
yeah. even LLVM is very slow for a JIT. Ask any project using LLVM as a backend for a JIT and they'll tell you it's an recurring issue. See for example https://webkit.org/blog/5852/introducing-the-b3-jit-compiler... I know very little about ruby specifically but IME for this kind of dynamic language you get most of the initial gains by : - removing (by analysis or speculation) dynamic dispatch - unboxing / avoiding allocations in the easy cases Once you've done that, you can generate pretty dumb assembly and still come out way ahead of your interpreter (and avoid very costly optimization / instruction selection / regalloc / scheduling). Most of what llvm / gcc do only make sense when you've got your code down close to whatever you would actually write in C. |
|