Regression: Vertex Weight Mix crash on apply/undo when mesh has shape keys #109523

Closed
opened 2023-06-29 18:00:17 +02:00 by Thomas Barlow · 5 comments
Member

System Information
Operating system: Windows-10-10.0.19045-SP0 64 Bits
Graphics card: NVIDIA GeForce GTX 1070 Ti/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 531.41

Blender Version
Broken: version: 3.4.0 Alpha, branch: master, commit date: 2022-09-09 22:58, hash: rB352d55b1c887
Worked: version: 3.4.0 Alpha, branch: master, commit date: 2022-09-09 00:25, hash: rB81558783e403

Short description of error
I'm getting a crash in a community addon when it applies a Vertex Weight Mix modifier to a mesh with shape keys.

No crash occurs with the addon when running Blender with --debug-memory, instead a lot of Memoryblock add_shapekey_layers: double free and Memoryblock free: pointer not in memlist are printed to the system console.

I have been unable to reproduce the exact scenario present in the addon in isolation, whereby a crash occurs when applying the modifier, but does not crash when --debug-memory is used. However, I have managed to produce similar crashes with Vertex Weight Mix that I'm guessing are related.

Exact steps for others to reproduce the error

Crash applying modifier (seems to always crash even with --debug-memory)

  1. Start with a default cube
  2. Add two shape keys (so there is the 'Basis' and one other shape key)
  3. Add a Vertex Group
  4. Add a Vertex Weight Mix modifier
  5. Set the Vertex Group you created as both the A and B vertex group (it's not necessary for both A and B to be the same, the crash still occurs if you were to have added two vertex groups and set one as A and the other as B)
  6. Apply the modifier
  7. Crash with the following printed to the System Console:
Malloc returns null: len=2096855700656 in dupli_malloc, total 19523832
Error   : EXCEPTION_ACCESS_VIOLATION
Address : 0x00007FFB94071470
Module  : VCRUNTIME140.dll
Thread  : 000059d8

Crash on undo unless --debug-memory is used:

  1. Open the attached .blend
  2. Apply the Vertex Weight Mix modifier on the cube
    1. When using --debug-memory, this also seems to make the mesh invisible unless the shape keys are removed
  3. Undo
  4. Crash occurs if not using --debug-memory, otherwise Memoryblock free: pointer not in memlist is printed once to the System Console. Nothing is printed to the System console if not using --debug-memory.

Crash on entering Edit mode after applying modifier (sometimes doesn't crash with --debug-memory):

  1. Open the attached .blend
  2. Apply the Vertex Weight Mix modifier on the cube
    1. When using --debug-memory, this also seems to make the mesh invisible unless the shape keys are removed
  3. Enter edit mode
  4. Crash with the following printed to the System Console:
Error   : EXCEPTION_ACCESS_VIOLATION
Address : 0x00007FF664FA2674
Module  : blender.exe
Thread  : 00005840
**System Information** Operating system: Windows-10-10.0.19045-SP0 64 Bits Graphics card: NVIDIA GeForce GTX 1070 Ti/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 531.41 **Blender Version** Broken: version: 3.4.0 Alpha, branch: master, commit date: 2022-09-09 22:58, hash: `rB352d55b1c887` Worked: version: 3.4.0 Alpha, branch: master, commit date: 2022-09-09 00:25, hash: `rB81558783e403` **Short description of error** I'm getting a crash in a community addon when it applies a Vertex Weight Mix modifier to a mesh with shape keys. No crash occurs with the addon when running Blender with `--debug-memory`, instead a lot of `Memoryblock add_shapekey_layers: double free` and `Memoryblock free: pointer not in memlist` are printed to the system console. I have been unable to reproduce the exact scenario present in the addon in isolation, whereby a crash occurs when applying the modifier, but does not crash when `--debug-memory` is used. However, I have managed to produce similar crashes with Vertex Weight Mix that I'm guessing are related. **Exact steps for others to reproduce the error** Crash applying modifier (seems to always crash even with `--debug-memory`) 1. Start with a default cube 1. Add two shape keys (so there is the 'Basis' and one other shape key) 1. Add a Vertex Group 1. Add a Vertex Weight Mix modifier 1. Set the Vertex Group you created as both the A and B vertex group (it's not necessary for both A and B to be the same, the crash still occurs if you were to have added two vertex groups and set one as A and the other as B) 1. Apply the modifier 1. Crash with the following printed to the System Console: ``` Malloc returns null: len=2096855700656 in dupli_malloc, total 19523832 Error : EXCEPTION_ACCESS_VIOLATION Address : 0x00007FFB94071470 Module : VCRUNTIME140.dll Thread : 000059d8 ``` Crash on undo unless `--debug-memory` is used: 1. Open the attached .blend 1. Apply the Vertex Weight Mix modifier on the cube 1. When using `--debug-memory`, this also seems to make the mesh invisible unless the shape keys are removed 1. Undo 1. Crash occurs if not using `--debug-memory`, otherwise `Memoryblock free: pointer not in memlist` is printed once to the System Console. Nothing is printed to the System console if not using `--debug-memory`. Crash on entering Edit mode after applying modifier (sometimes doesn't crash with `--debug-memory`): 1. Open the attached .blend 1. Apply the Vertex Weight Mix modifier on the cube 1. When using `--debug-memory`, this also seems to make the mesh invisible unless the shape keys are removed 1. Enter edit mode 1. Crash with the following printed to the System Console: ``` Error : EXCEPTION_ACCESS_VIOLATION Address : 0x00007FF664FA2674 Module : blender.exe Thread : 00005840 ```
Thomas Barlow added the
Type
Report
Status
Needs Triage
Priority
Normal
labels 2023-06-29 18:00:18 +02:00

Can confirm in last 4.0 debug build from scratch
Assertion failed: alignment < 1024, file F:\Blender_build\first\blender\intern\guardedalloc\intern\mallocn_lockfree_impl.c, line 290

Can confirm in last 4.0 debug build from scratch `Assertion failed: alignment < 1024, file F:\Blender_build\first\blender\intern\guardedalloc\intern\mallocn_lockfree_impl.c, line 290`
Iliya Katushenock changed title from Vertex Weight Mix crash on apply/undo when mesh has shape keys to Regression: Vertex Weight Mix crash on apply/undo when mesh has shape keys 2023-06-29 18:03:36 +02:00
Iliya Katushenock added this to the 3.6 LTS milestone 2023-06-29 18:10:50 +02:00

Potentially caused by 21f2bacad9
@HooglyBoogly

Potentially caused by 21f2bacad977d3fd83d9e4730f2a14dc9932f043 @HooglyBoogly
Hans Goudey self-assigned this 2023-06-29 18:20:25 +02:00
Author
Member

Hmm, I see you've modified the report body to specify 3.4.0a broken and working versions, though I don't get a crash with any of the three sets of reproduction steps on Blender 3.3.8, 3.4.0, 3.4.1 or 3.5.1.

Hmm, I see you've modified the report body to specify 3.4.0a broken and working versions, though I don't get a crash with any of the three sets of reproduction steps on Blender 3.3.8, 3.4.0, 3.4.1 or 3.5.1.

Yes, I have a folder of 300 blender versions from the last 5-6 years, and going through them, I found what was crashing for me. Not sure if there are any reasons why this result might be inaccurate.

Yes, I have a folder of 300 blender versions from the last 5-6 years, and going through them, I found what was crashing for me. Not sure if there are any reasons why this result might be inaccurate.

@Mysteryem Here is my simplest example

@Mysteryem Here is my simplest example
Hans Goudey added
Type
Bug
and removed
Type
Report
labels 2023-06-30 16:58:49 +02:00
Blender Bot added
Status
Resolved
and removed
Status
Confirmed
labels 2023-06-30 17:55:35 +02:00
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset System
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
Asset Browser Project
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
2 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#109523
No description provided.