Memory leak after importing a model/ toggling shading workspace #88033

Closed
opened 2021-05-04 21:24:05 +02:00 by Ankit Meel · 13 comments
Member

System Information
Operating system: macOS 10.14

Blender Version
broken: 08f4bab658

Short description of error
In a build with WITH_PYTHON_SAFETY, you can easily find memory leaks.
One when importing an .obj file:

Error: Not freed memory blocks: 8, total unfreed memory 0.004288 MB
rna_global_pool len: 64 0x60c0000db7f8
memory pool len: 48 0x60b0001149e8
BLI_Mempool Chunk len: 2024 0x61d000f802b8
rna_id len: 64 0x60c0002f0478
memory pool len: 48 0x60b00065b838
BLI_Mempool Chunk len: 2024 0x61d0014a50b8
ghash_buckets_resize len: 88 0x60e0003d22b8
ghash_buckets_resize len: 136 0x611000c6d6f8

Another when switching workspace:

Error: Not freed memory blocks: 52, total unfreed memory 0.023712 MB
python keying set info len: 448 
KeyingSet len: 480 
python keying set info len: 448 
KeyingSet len: 480 
python keying set info len: 448 
KeyingSet len: 480 
python keying set info len: 448 
...
rna_id len: 64 0x60c000127938
ghash_buckets_resize len: 40 0x60b000273808
memory pool len: 48 0x60b000273ac8
BLI_Mempool Chunk len: 2024 0x61d00109beb8
ghash_buckets_resize len: 136 0x611000722fb8

Exact steps for others to reproduce the error 1

  • Build with WITH_PYTHON_SAFETY
  • Import .obj file attached
  • Quit

LSAN report without any suppressions: #88033.txt
G3_Myrtana_Vanguard_Magic_Barrier_01.obj


Exact steps for others to reproduce the error 2

  • Build with WITH_PYTHON_SAFETY
  • Switch to shading workspace
  • switch back to layout workspace
  • Quit
**System Information** Operating system: macOS 10.14 **Blender Version** broken: 08f4bab658cd8c930450c11862540ff2da434151 **Short description of error** In a build with `WITH_PYTHON_SAFETY`, you can easily find memory leaks. One when importing an .obj file: ``` Error: Not freed memory blocks: 8, total unfreed memory 0.004288 MB rna_global_pool len: 64 0x60c0000db7f8 memory pool len: 48 0x60b0001149e8 BLI_Mempool Chunk len: 2024 0x61d000f802b8 rna_id len: 64 0x60c0002f0478 memory pool len: 48 0x60b00065b838 BLI_Mempool Chunk len: 2024 0x61d0014a50b8 ghash_buckets_resize len: 88 0x60e0003d22b8 ghash_buckets_resize len: 136 0x611000c6d6f8 ``` Another when switching workspace: ``` Error: Not freed memory blocks: 52, total unfreed memory 0.023712 MB python keying set info len: 448 KeyingSet len: 480 python keying set info len: 448 KeyingSet len: 480 python keying set info len: 448 KeyingSet len: 480 python keying set info len: 448 ... rna_id len: 64 0x60c000127938 ghash_buckets_resize len: 40 0x60b000273808 memory pool len: 48 0x60b000273ac8 BLI_Mempool Chunk len: 2024 0x61d00109beb8 ghash_buckets_resize len: 136 0x611000722fb8 ``` --- **Exact steps for others to reproduce the error 1** - Build with `WITH_PYTHON_SAFETY` - Import .obj file attached - Quit LSAN report without any suppressions: [#88033.txt](https://archive.blender.org/developer/F10053622/T88033.txt) [G3_Myrtana_Vanguard_Magic_Barrier_01.obj](https://archive.blender.org/developer/F10053091/G3_Myrtana_Vanguard_Magic_Barrier_01.obj) --- **Exact steps for others to reproduce the error 2** - Build with `WITH_PYTHON_SAFETY` - Switch to shading workspace - switch back to layout workspace - Quit
Author
Member

Added subscriber: @ankitm

Added subscriber: @ankitm
Member

Added subscriber: @PratikPB2123

Added subscriber: @PratikPB2123
Member

May be OS specific issue. I am not able to reproduce it on windows.
Tested on version 3.0.0 alpha, hash: 8e0995d0062


System Information:
Operating system : Windows-10-10.0.18362-SP0 64 Bits
Graphics card : AMD Radeon(TM) 535 ATI Technologies .

May be OS specific issue. I am not able to reproduce it on windows. Tested on version 3.0.0 alpha, hash: `8e0995d0062` --- **System Information:** Operating system : Windows-10-10.0.18362-SP0 64 Bits Graphics card : AMD Radeon(TM) 535 ATI Technologies .
Ankit Meel changed title from Memory leak after importing a model to Memory leak after importing a model/ toggling shading workspace 2021-05-05 20:24:02 +02:00
Author
Member

@PratikPB2123 does the method 2 create a mem leak ?

@PratikPB2123 does the method 2 create a mem leak ?
Member

I still can not reproduce the crash.

I still can not reproduce the crash.

Added subscriber: @mano-wii

Added subscriber: @mano-wii

Changed status from 'Needs Triage' to: 'Confirmed'

Changed status from 'Needs Triage' to: 'Confirmed'

I'm not sure if the two bugs are related, but as they only occur if the WITH_PYTHON_SAFETY option is enabled then it seems valid to be reported together.

I'm not sure if the two bugs are related, but as they only occur if the `WITH_PYTHON_SAFETY` option is enabled then it seems valid to be reported together.
Author
Member

Removed subscriber: @ankitm

Removed subscriber: @ankitm
Author
Member

Added subscriber: @ankitm

Added subscriber: @ankitm
First-time contributor

This issue was referenced by 06ecdab9bc

This issue was referenced by 06ecdab9bc6a7ec43fbf7906fc6db6520a73f465
First-time contributor

This issue was referenced by cbc671947a

This issue was referenced by cbc671947a3baca3da7d6c5a2980a86b7f6a7055

Changed status from 'Confirmed' to: 'Resolved'

Changed status from 'Confirmed' to: 'Resolved'
Campbell Barton self-assigned this 2021-08-11 09:40:13 +02: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
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#88033
No description provided.