No, the point of the compiler is to translate code into machine instruction.
Yes, it can optimize things for you, but that is not its purpose.
Yes, it can optimize things for you, but that is not its purpose.
A big feature of compilers is to find optimizations you wouldn't think of. I tried to make the point that compiled output is typically not read by humans