Incredible long shader compilation time (HLSL)
category: general [glöplog]
plz:
glBegin(GL_INTRO);
glSeed1i(0x43874834);
glCoolness1i(4292967295);
glColorHint(GL_COLOR_HINT_REDDISH);
glGeometryHint(GL_GEOMETRY_HINT_SPHERES | GL_GEOMETRY_HINT_CUBES | GL_GEOMETRY_HINT_PLANES);
glEnd();
glBegin(GL_INTRO);
glSeed1i(0x43874834);
glCoolness1i(4292967295);
glColorHint(GL_COLOR_HINT_REDDISH);
glGeometryHint(GL_GEOMETRY_HINT_SPHERES | GL_GEOMETRY_HINT_CUBES | GL_GEOMETRY_HINT_PLANES);
glEnd();
plz:
D3DXGenerateMusic(0x58736946, D3DXSTYLE_DUBSTEP_WITH_A_DASS_OF_DRUM_AND_BASS, 214, D3DXKEY_CSHARP_MINOR);
D3DXGenerateMusic(0x58736946, D3DXSTYLE_DUBSTEP_WITH_A_DASS_OF_DRUM_AND_BASS, 214, D3DXKEY_CSHARP_MINOR);
*D3DXSTYLE_DUBSTEP_WITH_A_DASH_OF_DRUM_AND_BASS
Next time I will copy/paste it directly from the SDK! ;)
Next time I will copy/paste it directly from the SDK! ;)
if (time >= 60.0f) glImpressAudience();
I also started writing my own raymarcher and lately I got the same long compile time using fxc from Directx SDK august 2009. I found out that this problem occurs only using august sdk. So going back to March 2009 sdk helped in my case so no need to use d3dx_31.dll :)
Hmm... The March 2009 had the same problem for me.
Any breakthroughs on this for long shaders? compile times of a minute are quite unbearable for development (and more or less a deal breaker for compos).
it's with the cs_5_0 profile, and it seems D3D10_SHADER_SKIP_OPTIMIZATION only slows things down, and [loop] hints doesn't change a thing (important loops are all dynamic though).
The Burj Babil shader (tracing pass) takes <10s in opengl (and around 1fps), but a straight cs5 port is 55s / 2.7fps at default settings (producing a slightly wrong picture) - and 190s / 8fps(!) WITH skip_optimization and correct picture... (800x600, PII-965, HD5770)
it's with the cs_5_0 profile, and it seems D3D10_SHADER_SKIP_OPTIMIZATION only slows things down, and [loop] hints doesn't change a thing (important loops are all dynamic though).
The Burj Babil shader (tracing pass) takes <10s in opengl (and around 1fps), but a straight cs5 port is 55s / 2.7fps at default settings (producing a slightly wrong picture) - and 190s / 8fps(!) WITH skip_optimization and correct picture... (800x600, PII-965, HD5770)
Well, my 2cents, but I know that I had long compilation with D3DX while using plain texture sampling (like tex2D or Sample on D3D10)... The compilation is trying to evaluate correctly the ddx/ddy, so it's probably trying to test-run the shader on the cpu to evaluate the values... I had to revert to tex2Dlod or SampleLevel to avoid long time compilation...
That's because it won't allow LOD calculation within flow control - meaning you can only use plain sampling in unrolled loops (so your loops will be unrolled if you don't specify level).
Quote:
That's because it won't allow LOD calculation within flow control - meaning you can only use plain sampling in unrolled loops (so your loops will be unrolled if you don't specify level).
Indeed I was aware of that ;) So you mean that you are not doing any regular texture sampling in your loops (or no texture sampling at all), but you are still experiencing long compilation? Weird...
How does that work?
xTr1m, any reason why you feel you have to wait a whole minute before impressing the audience? ;)
Quote:
any reason why you feel you have to wait a whole minute before impressing the audience? ;)
I often find myself wondering about that very thing when watching 4k intros :)
you two have no sense of tension :P
Haha, the next demo with a long loading time should have a drum roll loop playing while loading.
Agreed XD
Well, even the drum roll loop will be unrolled!!!
Well, I meant the running time of the intro. I guess 60 seconds is a good time. Take lunaquatic, the "impress audience" factor is when the cube starts to vectorslime ;) Everything before that was just a preparation for that one moment.
I was kidding, but thanks for the plug :D
Quote:
the "impress audience" factor is when the cube starts to vectorslime
I can't help but state that it sounds like you're describing an early 90s PC demo :) Then again, apart from the resolution and fancy lighting, in a way things are back on that level again for some of those raymarching intros out there :-)