User forums > Help
Profiling in Code::Blocks
(1/1)
zacaj:
Im trying to profile my program. Origionally, I would develop without an IDE, and could just at -pg to the compile line to profile it, and then run gprof. In code::blocks, theres a -pg option in build options, so I enabled it and compiled my program, than ran gprof main.exe, but it says there are no symbols. I also though there might be a plugin, but the plugin doesnt have a wiki page, and I cant find any links to download it.
Jenna:
You should also use -g (generate debug-symbols) and make sure, you do not strip the symbols or optimize the code.
zacaj:
Thanks, removing optimization fixed it
oBFusCATed:
Profiling unoptimized code is almost pointless.
I've no problems profiling -O2 compiled code!
Navigation
[0] Message Index
Go to full version