Jump to content
  • Advertisement
Sign in to follow this  
thallish

'Maximum temp register index exceeded'

This topic is 4081 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

What causes this issue when I try to compile my shader? and what can I do to remedy it? I have tried to google it, but can not find any information that help me on the subject.

Share this post


Link to post
Share on other sites
Advertisement
The shader has an upper limit to the number of temporary registers it uses at a given time. Most likely, the shader's computations require more registers than the selected Shader Model allows for. You can:

1) Make the shader use less registers. This might be a bit difficult to do if you're not too good with ASM shaders. It would basically mean looking at the ASM and trying to figure out how to help the shader compiler (I assume HLSL) to be able to use less registers. This might not be possible without altering what the shader is doing.
2) Use a higher shader model. I assume you're using 1.1 since this error isn't very common on higher models, unless if you use a lot of registers. Try using 1.4 if you're currently using 1.1, try 2.0 if that doesn't work, and if you must, you might have to go to 3.0.

Keep in mind that higher shader models means less hardware compatibility. While SM3 cards are more common than they used to, not everyone has them. Heck, not everyone has SM2 enabled cards, even.

Hope this helps.

Share this post


Link to post
Share on other sites
Yeah thanks for the explanation. The problem is I am using SM3.0.. yikes!!
I am trying to compile a perlin noise shader taken from nVidia's shader library, and they are compiling it using SM2.0, which I find very odd. Can there be another problem somewhere?

I will try to weed out expressions to see when it starts compiling without errors.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!