Automatic optimization of C / C ++ code
I would like to optimize the C / C ++ code and get an optimized version in C or intermediate representation (for example, LLVM IR), without actually compiling the code, mainly due to the lack of dependencies. In other words, I am looking for a way to see the optimization results on specific pieces of C code, assuming that any compiler will not compile the code due to missing libraries and dependencies.
Is it possible to use optimizations built into open source C / C ++ compilers (like GCC and Clang) without compiling the code? I'm mainly interested in the flow control graph (CFG) of functions after optimization. I am fully aware of the fact that this will not be entirely possible and will almost certainly give different results compared to when dependencies are present (due to nesting, for example).
source to share
No one has answered this question yet
Check out similar questions: