Bug 390175 - Valgrind internal assertion failure on program that runs normally
Summary: Valgrind internal assertion failure on program that runs normally
Status: RESOLVED NOT A BUG
Alias: None
Product: valgrind
Classification: Developer tools
Component: memcheck (show other bugs)
Version: 3.13.0
Platform: Compiled Sources Linux
: NOR crash
Target Milestone: ---
Assignee: Julian Seward
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-02-09 20:14 UTC by Christopher Neufeld
Modified: 2018-08-06 08:37 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments
Valgrind (memcheck) output leading to crash (4.55 KB, text/plain)
2018-02-09 20:14 UTC, Christopher Neufeld
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Christopher Neufeld 2018-02-09 20:14:14 UTC
Created attachment 110491 [details]
Valgrind (memcheck) output leading to crash

Fails in memcheck and massif.  I did a massif run, then made some changes intended to reduce memory consumption.  On the second run, massif asserted.  I ran memcheck to look for problems, and that also asserted.

Assertion is 
valgrind: m_oset.c:156 (elem_of_node): Assertion 'n->magic == OSET_MAGIC' failed.
valgrind: bad magic on node 0x111E5A8FF0 = 0 (expected 5b1f)


The program uses about 20GB RSS.

The changes I made involved some de-duping of compound structures inside larger data objects.  This results in a quite large number of allocations.

Before the crash, memcheck prints two warnings about a conditional jump depending on uninitialized values.  Then several warnings about large address ranges, then a crash report.

I'm attaching the relevant output from memcheck.
Comment 1 Julian Seward 2018-08-06 08:37:52 UTC
I've never seen the system fail at this point before now.
One possibility is a bug in your program, which causes valgrind's
internal data structures to get overwritten, leading to this failure.

I'm going to close this as invalid.  If you can still reproduce
this, please feel free to reopen.