Assert in looptri calculation after recent changes #52852

Closed
opened 2017-09-20 17:36:14 +02:00 by Ray molenkamp · 11 comments
Member

Latest master, debug build with tests enabled, while running cycles_report_test i'm hitting the following assert when running the T42475_1/2 tests.

62: BLI_assert failed: K:\BlenderGit\blender\source\blender\blenkernel\intern\cdderivedmesh.c:1922, CDDM_recalc_looptri(), at 'cddm->dm.looptris.array_wip != ((void *)0)'
62: [ RUN      ] T42475_1
62: 31: BLI_system_backtrace - 0x41404610
62: 30: CDDM_recalc_looptri - 0x40F63C10
62: 29: dm_getLoopTriArray - 0x40EEBAC0
62: 28: cloth_from_mesh - 0x40FFDFA0
62: 27: cloth_from_object - 0x40FFE160
62: 26: do_init_cloth - 0x41000830
62: 25: clothModifier_do - 0x40FFD200
62: 24: do_hair_dynamics - 0x40F12BC0
62: 23: hair_step - 0x40F12FB0
62: 22: particle_system_update - 0x40F07940
62: 21: deformVerts - 0x409C3330
62: 20: modwrap_deformVerts - 0x40D65AC0
62: 19: mesh_calc_modifiers - 0x40EECCC0
62: 18: mesh_build_data - 0x40EEF480
62: 17: makeDerivedMesh - 0x40EE4AA0
62: 16: BKE_object_handle_data_update - 0x41030480
62: 15: BKE_object_handle_update_ex - 0x40E7EF60
62: 14: scene_update_object_func - 0x40DB3690
62: 13: BLI_task_pool_work_and_wait - 0x41450110
62: 12: scene_update_objects - 0x40DB3BC0
62: 11: scene_update_tagged_recursive - 0x40DB3E00
62: 10: BKE_scene_update_tagged - 0x40DB0A60
62: 9: wm_file_read_post - 0x3FFB5AD0
62: 8: WM_file_read - 0x3FFB2910
62: 7: arg_handle_load_file - 0x3FFAE370
62: 6: BLI_argsParse - 0x413FECA0
62: 5: main_args_setup_post - 0x3FFAAA40
62: 4: main - 0x3FFA92A0
62: 3: __tmainCRTStartup - 0x451425A0
62: 2: mainCRTStartup - 0x451427C0
62: 1: BaseThreadInitThunk - 0x772459C0
62: 0: RtlUserThreadStart - 0x7737A540
62: BLI_assert failed: K:\BlenderGit\blender\source\blender\blenkernel\intern\cdderivedmesh.c:1922, CDDM_recalc_looptri(), at 'cddm->dm.looptris.array_wip != ((void *)0)'
[... couple hundred lines of stackdumps...]
62: [       OK ] T42475_1 (8799 ms)

yet the test still gets marked as a 'pass'

full log:

cycles_report.txt

Latest master, debug build with tests enabled, while running cycles_report_test i'm hitting the following assert when running the T42475_1/2 tests. ``` 62: BLI_assert failed: K:\BlenderGit\blender\source\blender\blenkernel\intern\cdderivedmesh.c:1922, CDDM_recalc_looptri(), at 'cddm->dm.looptris.array_wip != ((void *)0)' ``` ``` 62: [ RUN ] T42475_1 62: 31: BLI_system_backtrace - 0x41404610 62: 30: CDDM_recalc_looptri - 0x40F63C10 62: 29: dm_getLoopTriArray - 0x40EEBAC0 62: 28: cloth_from_mesh - 0x40FFDFA0 62: 27: cloth_from_object - 0x40FFE160 62: 26: do_init_cloth - 0x41000830 62: 25: clothModifier_do - 0x40FFD200 62: 24: do_hair_dynamics - 0x40F12BC0 62: 23: hair_step - 0x40F12FB0 62: 22: particle_system_update - 0x40F07940 62: 21: deformVerts - 0x409C3330 62: 20: modwrap_deformVerts - 0x40D65AC0 62: 19: mesh_calc_modifiers - 0x40EECCC0 62: 18: mesh_build_data - 0x40EEF480 62: 17: makeDerivedMesh - 0x40EE4AA0 62: 16: BKE_object_handle_data_update - 0x41030480 62: 15: BKE_object_handle_update_ex - 0x40E7EF60 62: 14: scene_update_object_func - 0x40DB3690 62: 13: BLI_task_pool_work_and_wait - 0x41450110 62: 12: scene_update_objects - 0x40DB3BC0 62: 11: scene_update_tagged_recursive - 0x40DB3E00 62: 10: BKE_scene_update_tagged - 0x40DB0A60 62: 9: wm_file_read_post - 0x3FFB5AD0 62: 8: WM_file_read - 0x3FFB2910 62: 7: arg_handle_load_file - 0x3FFAE370 62: 6: BLI_argsParse - 0x413FECA0 62: 5: main_args_setup_post - 0x3FFAAA40 62: 4: main - 0x3FFA92A0 62: 3: __tmainCRTStartup - 0x451425A0 62: 2: mainCRTStartup - 0x451427C0 62: 1: BaseThreadInitThunk - 0x772459C0 62: 0: RtlUserThreadStart - 0x7737A540 62: BLI_assert failed: K:\BlenderGit\blender\source\blender\blenkernel\intern\cdderivedmesh.c:1922, CDDM_recalc_looptri(), at 'cddm->dm.looptris.array_wip != ((void *)0)' [... couple hundred lines of stackdumps...] 62: [ OK ] T42475_1 (8799 ms) ``` yet the test still gets marked as a 'pass' full log: [cycles_report.txt](https://archive.blender.org/developer/F838340/cycles_report.txt)
Author
Member

Changed status to: 'Open'

Changed status to: 'Open'
Author
Member

Added subscriber: @LazyDodo

Added subscriber: @LazyDodo
Sergey Sharybin was assigned by Ray molenkamp 2017-09-20 19:16:55 +02:00

Added subscribers: @Sergey, @brecht

Added subscribers: @Sergey, @brecht
Sergey Sharybin was unassigned by Brecht Van Lommel 2017-09-20 20:11:30 +02:00
Bastien Montagne was assigned by Brecht Van Lommel 2017-09-20 20:11:30 +02:00

This is new code from 9591b5f618.

Just open the .blend and it will show that backtrace already, no need to start a Cycles render:
T42475_1.blend

This is new code from 9591b5f618. Just open the .blend and it will show that backtrace already, no need to start a Cycles render: [T42475_1.blend](https://archive.blender.org/developer/F840162/T42475_1.blend)
Brecht Van Lommel changed title from [Ctest/cycles_report_test] Assert fires, test still succeeds. to Assert in looptri calculation after recent changes 2017-09-20 20:12:20 +02:00
Author
Member

While the assert might not be auto testing related I really wish that this test wasn't marked as a pass, if i hadn't been randomly paying attention to the terminal, this would have just scrolled by and marked as a 'pass'

While the assert might not be auto testing related I really wish that this test wasn't marked as a pass, if i hadn't been randomly paying attention to the terminal, this would have just scrolled by and marked as a 'pass'

Right, it will only crash when building with WITH_ASSERT_ABORT. Not sure what the best way is to solve that, perhaps a --debug-abort command line option to enable aborting at runtime?

Right, it will only crash when building with `WITH_ASSERT_ABORT`. Not sure what the best way is to solve that, perhaps a `--debug-abort` command line option to enable aborting at runtime?

Our asserts by default do not error, only print the warning, autotest has nothing to do with that… There is a switch to actually abort on failed asserts iirc, could be useful to enable it for testing (can't remember exactly how, build option, envvar, …).

Assert is just wrong here btw, fix incomming.

Our asserts by default do not error, only print the warning, autotest has nothing to do with that… There is a switch to actually abort on failed asserts iirc, could be useful to enable it for testing (can't remember exactly how, build option, envvar, …). Assert is just wrong here btw, fix incomming.

This issue was referenced by 25f28d348f

This issue was referenced by 25f28d348fe1322da97c003c79d2d0e6e4267d1d
Author
Member

There seems to be some varying behavior with asserts. This one silently failed while marking the test as succeeded, #52853 displayed a popup (abort to quit, retry to debug, ignore to carry on) which blocked further tests from running, given running ctest on a debug build took around 2 hours, not having to baby sit incase any ui shows up would be prefered. I'm not overly picky with any changes here, if WITH_ASSERT_ABORT does the trick i'll happily add that to my debug builds.

There seems to be some varying behavior with asserts. This one silently failed while marking the test as succeeded, #52853 displayed a popup (abort to quit, retry to debug, ignore to carry on) which blocked further tests from running, given running ctest on a debug build took around 2 hours, not having to baby sit incase any ui shows up would be prefered. I'm not overly picky with any changes here, if WITH_ASSERT_ABORT does the trick i'll happily add that to my debug builds.

Changed status from 'Open' to: 'Resolved'

Changed status from 'Open' to: 'Resolved'

The difference is that Cycles uses the standard assert() which will abort, while Blender uses BLI_assert() which doesn't. I guess building with WITH_ASSERT_ABORT is ok. For the popups D2850 is a solution.

The difference is that Cycles uses the standard `assert()` which will abort, while Blender uses `BLI_assert()` which doesn't. I guess building with `WITH_ASSERT_ABORT` is ok. For the popups [D2850](https://archive.blender.org/developer/D2850) is a solution.
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
4 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#52852
No description provided.