Crash during Cycles GPU rendering when using world shader with position as input for volume scatter #72464

Closed
opened 2019-12-15 16:40:27 +01:00 by thomas pahler · 14 comments

System Information
Operating system: Windows-10-10.0.18362 64 Bits
Graphics card: GeForce GTX 960/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 430.86

Blender Version
Broken: version: 2.81 (sub 16), branch: master, commit date: 2019-12-04 11:32, hash: f1aa4d18d4
Worked: (optional)

Short description of error
when using the position node in the world shader to control the volume scatter density, this crashes cycles when rendering on the gpu.

Exact steps for others to reproduce the error
minimal blend file to reproduce the crash:bugReport.blend

  • open
  • switch to gpu renderer (gtx960, cuda)
  • switch viewport to rendered
  • after some time and a first image, blender will freeze and close some seconds later. (during the first sample)

notes:

  • this does not occur with the cpu renderer
  • a simple max node seems to prevent the crash in some cases, but not all
    max.JPG
  • crash confirmed with newer driver version 441.66
  • inside an object shader (instead of world shader), this does not crash
**System Information** Operating system: Windows-10-10.0.18362 64 Bits Graphics card: GeForce GTX 960/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 430.86 **Blender Version** Broken: version: 2.81 (sub 16), branch: master, commit date: 2019-12-04 11:32, hash: `f1aa4d18d4` Worked: (optional) **Short description of error** when using the position node in the world shader to control the volume scatter density, this crashes cycles when rendering on the gpu. **Exact steps for others to reproduce the error** minimal blend file to reproduce the crash:[bugReport.blend](https://archive.blender.org/developer/F8223323/bugReport.blend) - open - switch to gpu renderer (gtx960, cuda) - switch viewport to rendered - after some time and a first image, blender will freeze and close some seconds later. (during the first sample) notes: - this does not occur with the cpu renderer - a simple max node seems to prevent the crash in some cases, but not all ![max.JPG](https://archive.blender.org/developer/F8223362/max.JPG) - crash confirmed with newer driver version 441.66 - inside an object shader (instead of world shader), this does not crash
Author

Added subscriber: @thomason1005

Added subscriber: @thomason1005

Added subscriber: @rjg

Added subscriber: @rjg

I can't reproduce this on Windows 10 with Nvidia Geforce GTX 1080Ti in 2.81a and latest master. Please open Blender's installation directory and double click on blender_debug_gpu.cmd. Once Blender opens, perform the same steps as you did before to make it crash. Afterwards the Windows Explorer will open and show two files. Please upload them on here, by using the upload button as shown in the screenshot below.

2019_12_04_upload_icon_developer_blender_org.png

I can't reproduce this on Windows 10 with Nvidia Geforce GTX 1080Ti in 2.81a and latest master. Please open Blender's installation directory and double click on `blender_debug_gpu.cmd`. Once Blender opens, perform the same steps as you did before to make it crash. Afterwards the Windows Explorer will open and show two files. Please upload them on here, by using the upload button as shown in the screenshot below. ![2019_12_04_upload_icon_developer_blender_org.png](https://archive.blender.org/developer/F8190038/2019_12_04_upload_icon_developer_blender_org.png)
Robert Guetzkow changed title from volume shader that contains position node crashes cycles when rendering on gpu to Crash during Cycles GPU rendering when using world shader with position as input for volume scatter 2019-12-15 18:22:22 +01:00
Author

blender_system_info.txt

blender_debug_output.txt

here are the log files.

side note: sometimes blender does not crash completely, but instead shows this image: everything still works, except the render buffer/image is frozen.
Screenshot (2881).jpg

also, i was able to avoid the crashes by adding clamp nodes to avoid divide by zero and negative values in the volume shader density.
these seem to have been the cause.
as these are bad practices anyway, i would not consider this a high priority

[blender_system_info.txt](https://archive.blender.org/developer/F8226789/blender_system_info.txt) [blender_debug_output.txt](https://archive.blender.org/developer/F8226790/blender_debug_output.txt) here are the log files. side note: sometimes blender does not crash completely, but instead shows this image: everything still works, except the render buffer/image is frozen. ![Screenshot (2881).jpg](https://archive.blender.org/developer/F8226800/Screenshot__2881_.jpg) also, i was able to avoid the crashes by adding clamp nodes to avoid divide by zero and negative values in the volume shader density. these seem to have been the cause. as these are bad practices anyway, i would not consider this a high priority

The debug logs show that cuCtxSynchronize() failed. This may be caused by a Timeout Detection and Recovery (TDR) delay that is too low and the OS reinitializes the driver and resets the GPU.

Please try to increase the TDR delay and check if that resolves the issue. Instruction on how to modify this value can be found here . Be aware that incorrect modifications of the registry can lead to serious issues and you're doing so at your own risk.

The debug logs show that `cuCtxSynchronize()` failed. This may be caused by a [Timeout Detection and Recovery (TDR) delay ](https://docs.microsoft.com/de-de/windows-hardware/drivers/display/timeout-detection-and-recovery?redirectedfrom=MSDN) that is too low and the OS reinitializes the driver and resets the GPU. Please try to increase the TDR delay and check if that resolves the issue. Instruction on how to modify this value can be found [here ](https://docs.substance3d.com/spdoc/gpu-drivers-crash-with-long-computations-128745489.html). Be aware that incorrect modifications of the registry can lead to serious issues and you're doing so at your own risk.
Author

"Please try to increase the TDR delay"

will this help you in any way? p.e. in fixing or finding a bug, or is this a problem purely related to my system / graphics card?

i would rather not make changes to my registry, but i can do it if it helps find a general bug

"Please try to increase the TDR delay" will this help you in any way? p.e. in fixing or finding a bug, or is this a problem purely related to my system / graphics card? i would rather not make changes to my registry, but i can do it if it helps find a general bug

It would help to rule out the TDR as cause of your issue. If increasing it solves the problem, then it's not a bug in Blender.

It would help to rule out the TDR as cause of your issue. If increasing it solves the problem, then it's not a bug in Blender.

Added subscriber: @dfelinto

Added subscriber: @dfelinto

@thomason1005 is this something you could try please?

@thomason1005 is this something you could try please?
Author

bugResistry.JPG
i added the delays, but unfortunately, the example file still crashes blender when rendering

![bugResistry.JPG](https://archive.blender.org/developer/F8278229/bugResistry.JPG) i added the delays, but unfortunately, the example file still crashes blender when rendering
Author

so one driver update and another restart later, blender does not crash anymore on this file.

it does, however, freeze the interface for several seconds per sample, which does not occur if the density input is clamped to positive.

so one driver update and another restart later, blender does not crash anymore on this file. it does, however, freeze the interface for several seconds per sample, which does not occur if the density input is clamped to positive.
Author

just as a confirmation:

  • clamped density above .001 renders in 5:20min 100%
  • unclamped (negative) density renders at 20:00mins+ for 50%

so there seems to be a substantial difference in computation time, i do not know if this is reproducable on other systems or worth looking into.
but the clamped density also results in a black image image, so i do not know if it is even comparable.

but at least it does not crash anymore. nice!

just as a confirmation: - clamped density above .001 renders in 5:20min 100% - unclamped (negative) density renders at 20:00mins+ for 50% so there seems to be a substantial difference in computation time, i do not know if this is reproducable on other systems or worth looking into. but the clamped density also results in a black image image, so i do not know if it is even comparable. but at least it does not crash anymore. nice!

Changed status from 'Needs User Info' to: 'Archived'

Changed status from 'Needs User Info' to: 'Archived'
Dalai Felinto self-assigned this 2020-01-16 12:34:14 +01:00

I'm glad the driver fixed the crash for you. Since the original report was about the crash (and we stick to one issue per report ;) I'm closing this now. If you think the other issue is worth looking at please submit as a separate issue. Once again, thanks for the report.

I'm glad the driver fixed the crash for you. Since the original report was about the crash (and we stick to one issue per report ;) I'm closing this now. If you think the other issue is worth looking at please submit as a separate issue. Once again, thanks for the report.
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
3 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#72464
No description provided.