Profiling Torque with VTune
by Kuju Manila · in Torque Game Engine · 12/13/2007 (9:12 pm) · 6 replies
First of all, I know already that Torque has a built-in profiler. But what I wanted is to profile Torque itself with VTune.
Now, I need help in marrying Intel VTune with Torque. That is, I want to make use of VTune's Call Graph analysis to Torque. However, that is not possible without compiling the Torque Engine with the /FIXED:NO command line option. Whenever I haved that option added in the command line of the Torque Demo VC++ project, I get compilation errors such as:
Note.. the AFX codes also has the same error... the ones above are just a selection. But in reality, it's all over.
I need help in how to compile Torque with the /FIXED:NO option as required by VTune to make use of Call Graph.
Now, I need help in marrying Intel VTune with Torque. That is, I want to make use of VTune's Call Graph analysis to Torque. However, that is not possible without compiling the Torque Engine with the /FIXED:NO command line option. Whenever I haved that option added in the command line of the Torque Demo VC++ project, I get compilation errors such as:
1>volLight.cc 1>..\engine\lightingSystem\volLight.cc : fatal error C1083: Cannot open include file: 'XED:NO': No such file or directory 1>sgScenePersist.cc 1>..\engine\lightingSystem\sgScenePersist.cc : fatal error C1083: Cannot open include file: 'XED:NO': No such file or directory 1>sgSceneLightingTerrain.cc 1>..\engine\lightingSystem\sgSceneLightingTerrain.cc : fatal error C1083: Cannot open include file: 'XED:NO': No such file or directory 1>sgSceneLightingInterior.cc 1>..\engine\lightingSystem\sgSceneLightingInterior.cc : fatal error C1083: Cannot open include file: 'XED:NO': No such file or directory 1>sgSceneLighting.cc 1>..\engine\lightingSystem\sgSceneLighting.cc : fatal error C1083: Cannot open include file: 'XED:NO': No such file or directory 1>sgObjectShadows.cc 1>..\engine\lightingSystem\sgObjectShadows.cc : fatal error C1083: Cannot open include file: 'XED:NO': No such file or directory 1>sgMissionLightingFilter.cc 1>..\engine\lightingSystem\sgMissionLightingFilter.cc : fatal error C1083: Cannot open include file: 'XED:NO': No such file or directory 1>sgLightObject.cc 1>..\engine\lightingSystem\sgLightObject.cc : fatal error C1083: Cannot open include file: 'XED:NO': No such file or directory 1>sgLightMap.cc 1>..\engine\lightingSystem\sgLightMap.cc : fatal error C1083: Cannot open include file: 'XED:NO': No such file or directory
Note.. the AFX codes also has the same error... the ones above are just a selection. But in reality, it's all over.
I need help in how to compile Torque with the /FIXED:NO option as required by VTune to make use of Call Graph.
#2
Shot in the dark.
12/14/2007 (10:26 am)
I don't know the command line switches, but just from looking at that, it looks like /FI is "force include" and it's using the rest of the command as the argument, so you are force including "XED:NO".Shot in the dark.
#3
here are screenshots of the VS settings which worked to get a callgraph-able release build.
(particular libraries and such censored, sorry ;)
link 1
link 2
link 3
link 4
link 5
link 6
link 7
link 8
link 9
link 10
link 11
link 12
link 13
link 14
link 15
link 16
link 17
link 18
link 19
12/14/2007 (10:51 am)
Not sure it'll help, buthere are screenshots of the VS settings which worked to get a callgraph-able release build.
(particular libraries and such censored, sorry ;)
link 1
link 2
link 3
link 4
link 5
link 6
link 7
link 8
link 9
link 10
link 11
link 12
link 13
link 14
link 15
link 16
link 17
link 18
link 19
#4
12/15/2007 (12:28 am)
Oh crap. Actually after posting this, I've found the solution to the problem and I immediately requested deletion of this thread... seems it did not apply. Anyway, the problem was i'm placing the /FIXED:NO option on the command line of the compiler not linker! Haha stupid me. Anyway, I hope other Vtune users will find this useful.
#5
1>Torque Engine - 0 error(s), 876 warning(s)
Maybe some GG employee might want to check those warning cause most of them seem stupid programming errors. The game still works fine, and I don't get any FPS boost.
12/28/2007 (1:09 pm)
I didn't try VTunes and I don't know about most compiller/linker command line switches neither, but I just tried to compile the engine with Intel C Plus Plus Compiler v10.1.013 and the result is1>Torque Engine - 0 error(s), 876 warning(s)
Maybe some GG employee might want to check those warning cause most of them seem stupid programming errors. The game still works fine, and I don't get any FPS boost.
#6
Most of the warnings are related to data conversions, both safe and unsafe. The default practice for getting rid of errors in Torque has been to turn down the warning level. For Torque2 we turned it up, and fixed the warnings.
12/28/2007 (1:56 pm)
There are far more than 876 stupid programming errors in Torque. Most of the warnings are related to data conversions, both safe and unsafe. The default practice for getting rid of errors in Torque has been to turn down the warning level. For Torque2 we turned it up, and fixed the warnings.
Associate Orion Elenzil
Real Life Plus
but i'm unfamiliar with the /FIXED:NO option.
it took some futzing but as i recall i just compiled TGE with symbols and let vTune do its thing.
i'll try to check on the exact process tomorrow.