Scheduling Model in LLVM
myhsu.xyz
myhsu.xyz
Nowadays, compilers seem to produce code that beats my hand-crafted assembler pretty much every time. Sure, it's still possible to optimize C/C++ code so it makes better use of caches, or tweak code to allow the compiler to make better use of available registers. But now I know why compilers do better instruction scheduling than I can, especially with the proliferation of execution architectures. I can't imagine a human competing with that level of insight into instruction throughput anymore.
Thanks for the insight.
“In this post, I went through the basics of LLVM’s scheduling model and show how to specify the scheduling information for individual instructions. On top of that, I explained different kinds of processor resource buffers and their use cases.”