Blender crashes when baking particles for a flow fire + smoke sim #83876

Closed
opened 2020-12-17 07:13:40 +01:00 by Peter Steel · 21 comments

System Information
Operating system: Windows 10 pro
Graphics card: RTX 2080 ti

Blender Version
Broken: 2.91.0, 2.92.0
Worked: 2.90.1

Short description of error
Blender crash when baking the dynamics of a particle system added to the flow object of a smoke simulation.

Exact steps for others to reproduce the error

  • Select the default cube
  • Use Object > Quick Effects > Quick Smoke
  • Add a particle system to the (emitter) cube
  • In Particle Properties > Cache use Bake All Dynamics

flow_source.blend

BKE_ptcache_write(PTCacheID * pid, unsigned int cfra) Line 2552	C
BKE_ptcache_bake(PTCacheBaker * baker) Line 3418	C
ptcache_job_startjob(void * customdata, short * stop, short * do_update, float * progress) Line 162	C
do_job_thread(void * job_v) Line 390	C
tslot_thread_start(void * tslot_p) Line 232	C++
**System Information** Operating system: Windows 10 pro Graphics card: RTX 2080 ti **Blender Version** Broken: 2.91.0, 2.92.0 Worked: 2.90.1 **Short description of error** Blender crash when baking the dynamics of a particle system added to the flow object of a smoke simulation. **Exact steps for others to reproduce the error** - Select the default cube - Use *Object > Quick Effects > Quick Smoke* - Add a particle system to the (emitter) cube - In *Particle Properties > Cache* use *Bake All Dynamics* [flow_source.blend](https://archive.blender.org/developer/F9525146/flow_source.blend) ```lines BKE_ptcache_write(PTCacheID * pid, unsigned int cfra) Line 2552 C BKE_ptcache_bake(PTCacheBaker * baker) Line 3418 C ptcache_job_startjob(void * customdata, short * stop, short * do_update, float * progress) Line 162 C do_job_thread(void * job_v) Line 390 C tslot_thread_start(void * tslot_p) Line 232 C++ ```
Author

Added subscriber: @ps.productions

Added subscriber: @ps.productions
Author

to clarify it is with the point cache baking stage that it crashes

to clarify it is with the point cache baking stage that it crashes

Added subscriber: @rjg

Added subscriber: @rjg

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

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

I'm not getting any crash with the file you've provided both playing the animation with the cache type set to Replay as it is set in your file and when baking with the cache type set to All. Are there any steps missing?

Please open Blender's installation directory and double click on the blender_debug_log.cmd. This will start Blender in debug mode and create log files. Try to make Blender crash again. Once it crashes the Windows Explorer should open and show you up to two files, a debug log and the system information. Add them to your bug report by clicking on the upload button as shown in the screenshot below or via drag and drop. Please also upload the crash log located in C:\Users\[your username]\AppData\Local\Temp\[project name].crash.txt (or simply type %TEMP% into the path bar of the Windows Explorer).

2019_12_04_upload_icon_developer_blender_org.png

I'm not getting any crash with the file you've provided both playing the animation with the cache type set to *Replay* as it is set in your file and when baking with the cache type set to *All*. Are there any steps missing? Please open Blender's installation directory and double click on the `blender_debug_log.cmd`. This will start Blender in debug mode and create log files. Try to make Blender crash again. Once it crashes the Windows Explorer should open and show you up to two files, a debug log and the system information. Add them to your bug report by clicking on the upload button as shown in the screenshot below or via drag and drop. Please also upload the crash log located in `C:\Users\[your username]\AppData\Local\Temp\[project name].crash.txt` (or simply type `%TEMP%` into the path bar of the Windows Explorer). ![2019_12_04_upload_icon_developer_blender_org.png](https://archive.blender.org/developer/F8190038/2019_12_04_upload_icon_developer_blender_org.png)
Author

Before I do, The issue is with the particle system bake, not the fluid so there is no options for replay, modular or all. point cache bake causes the issue.

Before I do, The issue is with the particle system bake, not the fluid so there is no options for replay, modular or all. point cache bake causes the issue.

This comment was removed by @rjg

*This comment was removed by @rjg*

I have to correct myself, I do get a crash. It seems that pid->totpoint is NULL in BKE_ptcache_write.

[Unknown/Just-In-Time compiled code] (Unknown Source:0)
BKE_ptcache_write(PTCacheID * pid, unsigned int cfra) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenkernel/intern/pointcache.c:2552)
BKE_ptcache_bake(PTCacheBaker * baker) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenkernel/intern/pointcache.c:3415)
ptcache_job_startjob(void * customdata, short * stop, short * do_update, float * progress) (/home/dev/01-data/01-git/blender-git/blender/source/blender/editors/physics/physics_pointcache.c:160)
do_job_thread(void * job_v) (/home/dev/01-data/01-git/blender-git/blender/source/blender/windowmanager/intern/wm_jobs.c:389)
tslot_thread_start(void * tslot_p) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenlib/intern/threads.cc:231)
libpthread.so.0!start_thread(void * arg) (/build/glibc-ZN95T4/glibc-2.31/nptl/pthread_create.c:477)
libc.so.6!clone() (/build/glibc-ZN95T4/glibc-2.31/sysdeps/unix/sysv/linux/x86_64/clone.S:95)
I have to correct myself, I do get a crash. It seems that `pid->totpoint` is `NULL` in `BKE_ptcache_write`. ```lines [Unknown/Just-In-Time compiled code] (Unknown Source:0) BKE_ptcache_write(PTCacheID * pid, unsigned int cfra) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenkernel/intern/pointcache.c:2552) BKE_ptcache_bake(PTCacheBaker * baker) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenkernel/intern/pointcache.c:3415) ptcache_job_startjob(void * customdata, short * stop, short * do_update, float * progress) (/home/dev/01-data/01-git/blender-git/blender/source/blender/editors/physics/physics_pointcache.c:160) do_job_thread(void * job_v) (/home/dev/01-data/01-git/blender-git/blender/source/blender/windowmanager/intern/wm_jobs.c:389) tslot_thread_start(void * tslot_p) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenlib/intern/threads.cc:231) libpthread.so.0!start_thread(void * arg) (/build/glibc-ZN95T4/glibc-2.31/nptl/pthread_create.c:477) libc.so.6!clone() (/build/glibc-ZN95T4/glibc-2.31/sysdeps/unix/sysv/linux/x86_64/clone.S:95) ```

@ps.productions Are you able to create the scene in 2.91 resulting in the same error or does this only happen with the one created in a previous version?

@ps.productions Are you able to create the scene in 2.91 resulting in the same error or does this only happen with the one created in a previous version?
Author

@rjg The issue is with 2.91. Did i confuse the instructions for broken and worked versions in the bug report? in version 2.90.1 I did not run into this issue. But the scene i shared was created with 2.91.0

@rjg The issue is with 2.91. Did i confuse the instructions for broken and worked versions in the bug report? in version 2.90.1 I did not run into this issue. But the scene i shared was created with 2.91.0

@ps.productions Ok, that was the question. No you didn't do anything wrong.

@ps.productions Ok, that was the question. No you didn't do anything wrong.
Author

@rjg Is there any chance this bug will be fixed before next year?

@rjg Is there any chance this bug will be fixed before next year?

Unlikely as the source of the issue hasn't been identified yet, there is no patch, there likely won't be one in time should we do a corrective release for 2.91 and 2.92 is planned to be released in February.

Unlikely as the source of the issue hasn't been identified yet, there is no patch, there likely won't be one in time should we do a corrective release for 2.91 and 2.92 is planned to be released in February.

Changed status from 'Needs User Info' to: 'Needs Developer To Reproduce'

Changed status from 'Needs User Info' to: 'Needs Developer To Reproduce'

While I can reproduce the issue with your file, I need to check if I can create a file based on the startup file that crashes as well.

While I can reproduce the issue with your file, I need to check if I can create a file based on the startup file that crashes as well.

Changed status from 'Needs Developer To Reproduce' to: 'Confirmed'

Changed status from 'Needs Developer To Reproduce' to: 'Confirmed'

Added subscriber: @rlneumiller

Added subscriber: @rlneumiller

I've reproduced with 2.91 Official with default settings and manually recreated the scene (but reduced the number of frames to speed-up reproduction of the issue).
#83876.blend

blender_debug_output.txt

blender_system_info.txt

#83876.crash.txt

I have yet to work out how it got into this state but the following prevents the crash:

diff --git a/source/blender/blenkernel/intern/pointcache.c b/source/blender/blenkernel/intern/pointcache.c
index 14e049384ef..47bacebb10b 100644
--- a/source/blender/blenkernel/intern/pointcache.c
+++ b/source/blender/blenkernel/intern/pointcache.c
@@ -2549,7 +2549,9 @@ static int ptcache_write_needed(PTCacheID *pid, int cfra, int *overwrite)
 int BKE_ptcache_write(PTCacheID *pid, unsigned int cfra)
 {
   PointCache *cache = pid->cache;
-  int totpoint = pid->totpoint(pid->calldata, cfra);
+  ParticleSystem *psys = pid->calldata;
+
+  int totpoint = psys->totpart;
   int overwrite = 0, error = 0;

   if (totpoint == 0 || (cfra ? pid->data_types == 0 : pid->info_types == 0)) {
I've reproduced with 2.91 Official with default settings and manually recreated the scene (but reduced the number of frames to speed-up reproduction of the issue). [#83876.blend](https://archive.blender.org/developer/F9546658/T83876.blend) [blender_debug_output.txt](https://archive.blender.org/developer/F9546642/blender_debug_output.txt) [blender_system_info.txt](https://archive.blender.org/developer/F9546643/blender_system_info.txt) [#83876.crash.txt](https://archive.blender.org/developer/F9546645/T83876.crash.txt) I have yet to work out how it got into this state but the following prevents the crash: ``` diff --git a/source/blender/blenkernel/intern/pointcache.c b/source/blender/blenkernel/intern/pointcache.c index 14e049384ef..47bacebb10b 100644 --- a/source/blender/blenkernel/intern/pointcache.c +++ b/source/blender/blenkernel/intern/pointcache.c @@ -2549,7 +2549,9 @@ static int ptcache_write_needed(PTCacheID *pid, int cfra, int *overwrite) int BKE_ptcache_write(PTCacheID *pid, unsigned int cfra) { PointCache *cache = pid->cache; - int totpoint = pid->totpoint(pid->calldata, cfra); + ParticleSystem *psys = pid->calldata; + + int totpoint = psys->totpart; int overwrite = 0, error = 0; if (totpoint == 0 || (cfra ? pid->data_types == 0 : pid->info_types == 0)) { ```

Bisect points to e5c0d4613a

Bisect points to e5c0d4613a

This issue was referenced by 5aab7f66a0

This issue was referenced by 5aab7f66a0bc5d7888c98fad3da697af8a623bff
Member

Changed status from 'Confirmed' to: 'Resolved'

Changed status from 'Confirmed' to: 'Resolved'
Jacques Lucke self-assigned this 2021-01-04 15:59:31 +01:00
Thomas Dinges added this to the 2.91 milestone 2023-02-08 16:20:07 +01:00
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
5 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#83876
No description provided.