Bug 408364

Summary: Valgrind causes OOM when running a function in a deleted virtual class
Product: [Developer tools] valgrind Reporter: krzysio.kurek
Component: generalAssignee: Julian Seward <jseward>
Status: RESOLVED NOT A BUG    
Severity: normal    
Priority: NOR    
Version First Reported In: 3.15 SVN   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: Source code to replicate the issue

Description krzysio.kurek 2019-06-06 00:37:24 UTC
Created attachment 120611 [details]
Source code to replicate the issue

SUMMARY
If you try to run a virtual function on a deleted object, valgrind starts allocating massive amounts of memory before running into a system-wide OOM

STEPS TO REPRODUCE
1. Compile the attached code
2. Run under valgrind

OBSERVED RESULT
Code is ran, an error is optionally reported and valgrind exits

EXPECTED RESULT
Valgrind starts allocating massive amounts of memory, never exits.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: Linux-5.1.5-1-default OpenSUSE Tumbleweed
Comment 1 krzysio.kurek 2019-06-09 17:54:03 UTC
Turns out it was caused by thread sanitizer which I forgot was on.