Until 2015, LLVM just unconditionally put the function prologue at the beginning of each function, even when it wasn't needed! A friendly introduction to the shrink-wrap pass here: https://reviews.llvm.org/D9210