• Advertisement
Sign in to follow this  

Complicated Shader causing system freeze

This topic is 2259 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

Hi there,

I just unpleasently noticed that complex shaders can cause a system freeze.
I guess stackoverflow is the thing to blame here.

I'm using linux with proprietary ATI-drivers.
Is there a possibility to run programs in a memory-safe mode?
Would a virtual machine provide more safety for CPU- and especially GPU-memory-abuses?
Or are there more lightweighted solutions to memory-safe development?

Greets and thanks for your time.

Share this post


Link to post
Share on other sites
Advertisement
When you say shaders, it sounds like you have a ton of really slow shaders. What are your shaders? Are you sure that your GPU is not getting too hot and shutting down? 99% bet thats what it is.

Share this post


Link to post
Share on other sites
Because a shader will run on the GPU, not the CPU, it's highly unlikely to be a standard stack overflow and more likely to be a case of approaching or exceeding your hardware limits (and your hardware not handling it gracefully).

I doubt if a VM would help as the VM would be using the same hardware as the host OS, so a hardware-related problem would still lockup both.

Share this post


Link to post
Share on other sites
Hey, thanks for your replies!


When you say shaders, it sounds like you have a ton of really slow shaders. What are your shaders? Are you sure that your GPU is not getting too hot and shutting down? 99% bet thats what it is.

I've tried it with my shadowmaps pcf-calculation, where in the current implementation I have an array that stores the offsets for each sample.
If I set the sample-count too hight i get an instant freeze, so I don't think it's the GPU temperature.


Because a shader will run on the GPU, not the CPU, it's highly unlikely to be a standard stack overflow and more likely to be a case of approaching or exceeding your hardware limits (and your hardware not handling it gracefully).

I doubt if a VM would help as the VM would be using the same hardware as the host OS, so a hardware-related problem would still lockup both.

Yeah, I ment some kind of memory overflow of the GPU-memory. I don't know how the GPU works in detail, but It seemed reasonably for me to assume that each core had a stack and shared memory. I think you're right on the virtual machines, because I think they use the host-systems GPU-drivers to simulate parts of the ones on the guest-system (not sure about that).
edit: just remembered that the last time I checked, a windows-guest on a linux-host had only highly experimental 3D support, so at least Virtualbox isn't an option.


As a side note -- On Windows, if the GPU really does lock up (which is unlikely), the OS will reboot the graphics driver without having to reboot the entire system.

I've read about that, while searching for similar topics. So it might be possible to implement something similar on linux.
If someone has found/implemented such a thing please let me know :)

Share this post


Link to post
Share on other sites
i had the same problem long back on my desktop. Changed my CPU fan.

Also as you are using Linux, make sure you haven't installed any thing that is causing problem with the hardware. There's no problem in using linux, as i use it too, but recently i played with some hardware drivers and messed up the cpu fan control of my laptop, it starts and stops whenever it feels to.

Share this post


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

  • Advertisement