Is PS 1.4 better than PS 1.3?

binmaze

Newcomer
After reading nVIDIA's statement, i thought it had some points.
But on the other hand, I cannot help but feeling it's like a childish whining.

I think their argument valid if PS 1.4 is no better than PS 1.3.
So developers won't use 1.4 just because it has bigger name than 1.3.

So what's the truth?

1. PS 1.4 is the better? or It's just another kind of PS 1.x type?
Then why Carmack using 1.4?

2. What's the advantage of 1.3 over 1.1?
Why 3DMark03 used 1.1 rather than 1.3 as fallback?
Some claim 1.3 has no virtual merit over 1.1. Is it true?

3. Can PS 2.0 unit run PS 1.4 routines? How about 1.3 routines?

4. Which type of shader do you think developers will use the most in the near future?
1.1? 1.3? 1.4? or 1.1+1.3? 1.1+1.4? or all of them? or none of them?
 
If PS 1.4 wasn't better than 1.3, then why would MS have revised the DX 8 spec to include it? I know MS is stupid, but not that stupid...
 
PS 1.4 is a heck of alot better. The only reason why a developer would not want to use it is if they like to stick to the lowest common denominator in terms of shader capabilities. In that case, we're stuck with PS 1.1.
 
1. PS1.4 is "better" than PS1.x for x < 4, in that you can run longer shaders with greater flexibility in texture addressing, and therefore require much fewer passes for certain classes of effects - also a few effects that are not possible with PS1.1 (like combined reflection and refraction) are possible with PS1.4.

2. PS1.3, IIRC, added a dot-product usable for dependent texturing with an 1D texture, and the capability to modify the Z value of the pixel. Unlike what is the case with PS1.4, the added features of PS1.3 over PS1.1 don't seem to be very useful for the lighting/reflection/refraction effects that pixel shaders are typically used for.

3. A pixel shader unit with any given version number is required to be able to run pixel shader programs of all lower version numbers. So yes and yes.

4. If DOOM3 is any indication, they will support several paths corresponding to PS1.1, PS1.4 and PS2.0, as it varies dramatically from one platform to another which one is faster. Possibly limited to effects that PS1.1 can muster.
 
(all this taken from Microsoft's DX9 SDK. I may have misread something. If you want to investigate further and/or show me wrong, it can be downloaded from Microsoft (it is HUGE though!))

binmaze said:
1. PS 1.4 is the better? or It's just another kind of PS 1.x type?
Then why Carmack using 1.4?
The main difference is that 1.4 contains the ability to perform two phases. Each phase consists of some texture sampling instructions followed by some ALU instructions. The texture sampling instructions in the second phase can be dependent reads based upon the ALU calculations in the first phase - which is what John Carmack needs in order to do his lighting algorithm in a single pass.

1.1-1.3 can also do dependent lookups, but in a very restrictive way - arbitrary ALU operations cannot be applied (which prevents JC single pass lighting). The 1.4 model for handling dependent textures is simpler - just 4 texture unit commands instead of about 20.

1.4 also has more instructions (14 - I think this is 14 instructions per phase and so actually 28 total instructions, but the DX9 SDK is unclear on this point, I could be wrong here).

I'm pretty sure that any 1.1-1.3 shader can be implemented in 1.4.

binmaze said:
2. What's the advantage of 1.3 over 1.1?
Why 3DMark03 used 1.1 rather than 1.3 as fallback?
Some claim 1.3 has no virtual merit over 1.1. Is it true?
1.1, 1.2 and 1.3 are almost identical. 1.2 and 1.3 add the ability to have 12 instructions instead of 8. 1.3 adds the ability to modify the depth value from inside the shader, and a couple of extra texture unit instructions (that aren't that useful). 1.3 also adds the ability to use 3 texture coordinate sources on the same instruction. I don't think it has any other significant improvement over 1.1.

If you don't need any of these new functions, then there's no point using it because not all DX8 hardware necessarily supports 1.3, whereas ALL DX8 hardware must support 1.1. (Edit: if they support pixel shaders at all)

binmaze said:
3. Can PS 2.0 unit run PS 1.4 routines? How about 1.3 routines?
PS 2.0 hardware has to support all legacy shader paths to pass WHQL, I believe.

binmaze said:
4. Which type of shader do you think developers will use the most in the near future?
1.1? 1.3? 1.4? or 1.1+1.3? 1.1+1.4? or all of them? or none of them?
If you need to update depth in a shader, and/or exceed the 8 instruction limit, it cannot be done with 1.1 and so 1.3 or 1.4 will be required. Both these seem rare in current applications (with only 4 textures max at input, to need more than 4 ALU operations isn't really common).

Otherwise, the most important are clearly 1.1 (because everything supports it) and 1.4 (because it can do dependent lookups and therefore get rid of a multipass operation in most cases).
 
One more thing on 1.4: I think it is required to have 6 texture units, 6 interpolants, and 6 temporary registers rather than 1.1-1.3's 4, 4 and 2.
 
Dio said:
1.4 also has more instructions (14 - I think this is 14 instructions per phase and so actually 28 total instructions, but the DX9 SDK is unclear on this point, I could be wrong here).

Nope, you're right. 8 arithmethic instructions, plus 6 texture sampling instructions per phase, for a total of 28.
 
arjan is right. Also, remember that 1.4 allows 6 textures per pass, vs. 4 for 1.1 to 1.3. That alone is a good reason for the performance gain.
 
My god.

Thanks guys for enlightening me.

Then what in the world of this fuss about the new 3DMark?
I see no unfair, invalid, or biased featuring of using PS 1.4? Am I biased or what?
 
Re: My god.

binmaze said:
Thanks guys for enlightenling me.

Then what in the world of this fuss about the new 3DMark?
I see no unfair, invalid, or biased featuring of using PS 1.4? Am I biased or what?
A hint, Nvidia till GFFX doesn't support PS 1.4 ;)
 
Re: My god.

Evildeus said:
binmaze said:
Thanks guys for enlightenling me.

Then what in the world of this fuss about the new 3DMark?
I see no unfair, invalid, or biased featuring of using PS 1.4? Am I biased or what?
A hint, Nvidia till GFFX doesn't support PS 1.4 ;)

I may sound insane saying this, but I believe nVidia doesn't care about 3DMark 2003 using PS1.4.
In barely a few months, the whole GF4 Ti family will not be manufactured anymore. The NV31 and NV34 are to replace the GF4 Ti and GF4 MX respectively.
So, if their GF4 looks worse than it actually is and they got the best mainstream product real soon, then that means people will be more interested in upgrading to their new products.

And that's good for them.

I think that what nVidia doesn't like about 3DMark 2003 is the time they'll need to optimize their drivers for it ( their driver team is already VERY busy with the NV30 optimizations & NV34 software shader system )
Also, they don't like so little different shader programs are used. The NV30 got a slight advantage when more shader programs are used, because they're stored in video memory ( the R300, I think, got to send them through AGP, and thus with higher latency, everytime )

Also, no 3DMark 2003 shader needs multiple passes on DX9 hardware. nVidia would have loved to have their instruction limits used a little more.


Uttar
 
Re: My god.

Uttar said:
I may sound insane saying this, but I believe nVidia doesn't care about 3DMark 2003 using PS1.4.
In barely a few months, the whole GF4 Ti family will not be manufactured anymore. The NV31 and NV34 are to replace the GF4 Ti and GF4 MX respectively.
So, if their GF4 looks worse than it actually is and they got the best mainstream product real soon, then that means people will be more interested in upgrading to their new products.

And that's good for them.

I think that what nVidia doesn't like about 3DMark 2003 is the time they'll need to optimize their drivers for it ( their driver team is already VERY busy with the NV30 optimizations & NV34 software shader system )
Also, they don't like so little different shader programs are used. The NV30 got a slight advantage when more shader programs are used, because they're stored in video memory ( the R300, I think, got to send them through AGP, and thus with higher latency, everytime )

Also, no 3DMark 2003 shader needs multiple passes on DX9 hardware. nVidia would have loved to have their instruction limits used a little more.


Uttar

I couldn't find any evidence to support this so far. Where can i find one?
 
Dio said:
binmaze said:
Then why Carmack using 1.4?
The main difference is that 1.4 contains the ability to perform two phases. Each phase consists of some texture sampling instructions followed by some ALU instructions. The texture sampling instructions in the second phase can be dependent reads based upon the ALU calculations in the first phase - which is what John Carmack needs in order to do his lighting algorithm in a single pass.

AFAIK, John Carmack doesn't use dependent lookups.
He needs two phases to perform 7 texture reads.
While PS1.4 only has access 6 textures, luckily for JC two of his texture reads are from the same texture (normalization cubemap).
And PS1.4 allows reading a texture twice (once in each phase).

1.1-1.3 can also do dependent lookups, but in a very restrictive way - arbitrary ALU operations cannot be applied (which prevents JC single pass lighting). The 1.4 model for handling dependent textures is simpler - just 4 texture unit commands instead of about 20.

This is irrelevant.
PS1.1-1.3 can only perform 4 texture reads which forces JC to use multiple passes.
 
Dio said:
One more thing on 1.4: I think it is required to have 6 texture units, 6 interpolants, and 6 temporary registers rather than 1.1-1.3's 4, 4 and 2.

Actually the 2 temps are practically equal to the 6 temps in PS1.4, because the texture registers are read-only in PS1.4
 
arjan de lumens said:
Also a few effects that are not possible with PS1.1 (like combined reflection and refraction) are possible with PS1.4.

See the Advanced Pixel Shader test in 3DMark2001 for combined reflection and refraction.

So... what you're saying again?
 
Hyp-X said:
arjan de lumens said:
Also a few effects that are not possible with PS1.1 (like combined reflection and refraction) are possible with PS1.4.

See the Advanced Pixel Shader test in 3DMark2001 for combined reflection and refraction.

So... what you're saying again?

I believe he means in a single pass.
 
Re: My god.

Uttar said:
Also, no 3DMark 2003 shader needs multiple passes on DX9 hardware. nVidia would have loved to have their instruction limits used a little more.


Uttar

I know they would, going above and Beyond DX9 spec is not going to be supported for any developer in their right mind...I had the arguement on here for months with CG. DX9 won't expose them, but sure as heck the CG HLSL would...and why it was released.
 
Re: My god.

Doomtrooper said:
I know they would, going above and Beyond DX9 spec is not going to be supported for any developer in their right mind...I had the arguement on here for months with CG. DX9 won't expose them, but sure as heck the CG HLSL would...and why it was released.

Err, what?
DX9 HLSL allows you to go beyond DX9 specs. Sure, not as far as Cg, but still a lot more far than VS2.0 and PS2.0!
And anyway, going multi-pass on DX9 hardware is not like you can't do it on that hardware. It's just slower.


Uttar
 
Actually DX9 specifications are quite broad (from shader model 2.0 to shader model 3.0). So no one is going "above and beyond DX9 specifications" for some time.
Also DX9 HLSL has to stay within shader limitations of DX 9, just as Cg has. DX9 HLSL currently can target ps_2_0 and vs_2_0 max, while Cg can target extended 2.0 shader model (and DX9 HLSL will be able to do this soon).
Of course you'll still need to multipass sometimes, like in Doom 3 case (fill z-buffer first, then draw), but developers will make all the actuall rendering in a single pass on GeForce FX for quite some time in the future.
 
Back
Top