Viewing compiler optimizations
I'd like to see the code a compiler generates when I compile a program. I know there is a way to do it, I just can find any info on it. Help? :)
Additionally, where can I choose which optimizations are made when I build?
You can view the assembly that a the compiler spits out with any decent debugger. What compiler/IDE are you using?
You can get MSVC to output the assembly it generates with the /FA family of switches. Optimizations can be controlled by going to Project Properties -> C/C++ -> Optimization.
Quote:Original post by SiCrane
You can get MSVC to output the assembly it generates with the /FA family of switches. Optimizations can be controlled by going to Project Properties -> C/C++ -> Optimization.
I just put a breakpoint in the code I'm interested in and hit alt-8.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement