View Full Version : assembly output of GLSL program
08-28-2006, 08:18 AM
Is it possible to get the output of the compiled GLSL program? I want to know how many instructions were needed to compile a certain program.
08-28-2006, 08:54 AM
"number of instructions" will depend on the hardware used. And don't imagine that ARB vp/fp are actual hardware instructions. The hardware already changed a lot.
08-28-2006, 10:57 AM
The Nvidia has NVemulate (http://developer.nvidia.com/object/nvemulate.html) tool which can dump the corresponding vp/fp assembly for linked GLSL programs. If you compile that assembly you may use the vp/fp api to query number of native instructions (I do not know how much precise that information is and what the driver considers a one native instruction). Of course the results of this entire process are valid only for Nvidia cards.
Alternativelly the NVShaderPerf (http://developer.nvidia.com/object/nvshaderperf_home.html) tool also prints (if I remember correctly) resulting assembly for choosen GPU family together with performance related informations for the shader on that GPU. This information is also Nvidia specific.
Powered by vBulletin® Version 4.2.3 Copyright © 2017 vBulletin Solutions, Inc. All rights reserved.