Loop unrolling, inlining, dead code elimination does not change the asymptotical complexity of the program. This optimisation does.
The time when mortals could more or less 'see' what the memory usage and execution time of a C++ code fragment are is well beyond us.