Shader Debugger is not available
I am trying to use the shader debugger feature of NSight. Here are some details of my setup: Software: C++ DirectX 11 Visual Studio 2013 Compiled as Debug x64 Target: 64-bit Windows 7 Ultimate Intel Core i7 CPU X 990 @ 3.47GHz 12 GB RAM GTX 580 Host: 64-bit Windows 7 Professional Intel Core i7-2860QM CPU @ 2.50GHz 16 GB RAM Quadro 2000M When I "Start Graphics Debugging", my software launches on the target machine and I am able to use the frame debug features, but the shader list shows "Shader Debugger is not available" for all shaders. It is worth noting that once upon a time I used the shader debugger on the same program successfully with this same pair of PCs. It was a while ago and my program has changed quite a bit since then, but the bulk of the underlying graphics code has not. Here are some things I've tried to no avail: [list] [.]I had updated to the latest version of NSight, but then realized that it had dropped support for the GTX 580. Since then, I have tried versions 5.0, 4.7 and 4.0. When I did this, I installed the same version on both the target and host machines.[/.] [.]I thought my trouble could be due to the way I was compiling my shader code at runtime. I tried updating my code to use the compilation flags to produce debug information. I tried using different versions of API compilation functions. I also attempted to use an older version of <D3DCompiler.h> so it would use an earlier version of the DLL than "d3dcompiler_47.dll" - but I couldn't seem to get that to work right - every time I ran my program it would still require "d3dcompiler_47.dll" be present.[/.] [.]Finally I pulled out the runtime shader compilation and reorganzied my shader code into .hlsl files that would be pre-compiled by VS2013 and then loaded from .cso files at runtime. I made sure the files were set to compile with the /Gfp, /Zi, and /Od flags. Still, "Shader Debugger is not available".[/.] [.]Have tried compiling my program both with and without the D3D11_CREATE_DEVICE_DEBUG flag set.[/.] [/list] Any ideas are much appreciated!
I am trying to use the shader debugger feature of NSight. Here are some details of my setup:

Software:
C++ DirectX 11
Visual Studio 2013
Compiled as Debug x64

Target:
64-bit Windows 7 Ultimate
Intel Core i7 CPU X 990 @ 3.47GHz
12 GB RAM
GTX 580

Host:
64-bit Windows 7 Professional
Intel Core i7-2860QM CPU @ 2.50GHz
16 GB RAM
Quadro 2000M

When I "Start Graphics Debugging", my software launches on the target machine and I am able to use the frame debug features, but the shader list shows "Shader Debugger is not available" for all shaders.

It is worth noting that once upon a time I used the shader debugger on the same program successfully with this same pair of PCs. It was a while ago and my program has changed quite a bit since then, but the bulk of the underlying graphics code has not.

Here are some things I've tried to no avail:
  • I had updated to the latest version of NSight, but then realized that it had dropped support for the GTX 580. Since then, I have tried versions 5.0, 4.7 and 4.0. When I did this, I installed the same version on both the target and host machines.
  • I thought my trouble could be due to the way I was compiling my shader code at runtime. I tried updating my code to use the compilation flags to produce debug information. I tried using different versions of API compilation functions. I also attempted to use an older version of <D3DCompiler.h> so it would use an earlier version of the DLL than "d3dcompiler_47.dll" - but I couldn't seem to get that to work right - every time I ran my program it would still require "d3dcompiler_47.dll" be present.
  • Finally I pulled out the runtime shader compilation and reorganzied my shader code into .hlsl files that would be pre-compiled by VS2013 and then loaded from .cso files at runtime. I made sure the files were set to compile with the /Gfp, /Zi, and /Od flags. Still, "Shader Debugger is not available".
  • Have tried compiling my program both with and without the D3D11_CREATE_DEVICE_DEBUG flag set.


Any ideas are much appreciated!

#1
Posted 09/12/2016 05:00 PM   
On a side note, in case it gives any clues, I have also tried using Visual Studio's built-in Graphics Diagnostics features, but it throws an access violation immediately in dxgi.dll. I have tried to track down what is causing this, but it somehow seems to happen before my program's main function is even entered, as I added some debug output code right at the beginning that never seems to execute...
On a side note, in case it gives any clues, I have also tried using Visual Studio's built-in Graphics Diagnostics features, but it throws an access violation immediately in dxgi.dll. I have tried to track down what is causing this, but it somehow seems to happen before my program's main function is even entered, as I added some debug output code right at the beginning that never seems to execute...

#2
Posted 09/12/2016 05:03 PM   
Hi timcoolman, It's hard to say why, please take some try of these: - make sure your driver matches your Nsight - please make sure the cso file you loaded do contain debug information. - check Nsight->Options->Graphics->Preferred remote shader debugging is not set to disable. Thanks An
Hi timcoolman,

It's hard to say why, please take some try of these:

- make sure your driver matches your Nsight
- please make sure the cso file you loaded do contain debug information.
- check Nsight->Options->Graphics->Preferred remote shader debugging is not set to disable.

Thanks
An

#3
Posted 09/13/2016 06:37 AM   
[list] [.]I have the latest driver available for my GPU. Is the driver version listed for each NSight version a [b]minimum[/b] requirement? Or do I need to roll back my driver version for the version of NSight I'm using?[/.] [.]Other than making sure I have set the necessary flags in the compilation settings, is there any way I can tell that my .cso files do in fact contain debug info? I do know that at first I hadn't added the /Gfp flag, and I was seeing a warning in the output when the shaders were being loaded. After adding the flag and recompiling shaders, those warnings went away and now I see no warnings at all.[/.] [.]Shader debugging is not disabled in my Nsight options.[/.] [/list]
  • I have the latest driver available for my GPU. Is the driver version listed for each NSight version a minimum requirement? Or do I need to roll back my driver version for the version of NSight I'm using?
  • Other than making sure I have set the necessary flags in the compilation settings, is there any way I can tell that my .cso files do in fact contain debug info? I do know that at first I hadn't added the /Gfp flag, and I was seeing a warning in the output when the shaders were being loaded. After adding the flag and recompiling shaders, those warnings went away and now I see no warnings at all.
  • Shader debugging is not disabled in my Nsight options.

#4
Posted 09/14/2016 03:10 PM   
Hi timmcoolman, >>>Other than making sure I have set the necessary flags in the compilation settings, is there any way I can tell that my .cso files do in fact contain debug info? I do know that at first I hadn't added the /Gfp flag, and I was seeing a warning in the output when the shaders were being loaded. After adding the flag and recompiling shaders, those warnings went away and now I see no warnings at all. => Yes, you can try to use fxc.exe which is MSFT shader offline compiler. Try these arguments: /Od /Zi /Gfp Please note, Nsight have some limitation when you try to do shader debug on CS, you might not be able to step into some codes. are you be able to hit the bp, but not do f10/f11, or just can't hit the bp? Thanks An
Hi timmcoolman,

>>>Other than making sure I have set the necessary flags in the compilation settings, is there any way I can tell that my .cso files do in fact contain debug info? I do know that at first I hadn't added the /Gfp flag, and I was seeing a warning in the output when the shaders were being loaded. After adding the flag and recompiling shaders, those warnings went away and now I see no warnings at all.

=> Yes, you can try to use fxc.exe which is MSFT shader offline compiler. Try these arguments: /Od /Zi /Gfp

Please note, Nsight have some limitation when you try to do shader debug on CS, you might not be able to step into some codes. are you be able to hit the bp, but not do f10/f11, or just can't hit the bp?

Thanks
An

#5
Posted 10/13/2016 06:46 AM   
Scroll To Top

Add Reply