#12442 closed bug (duplicate)
Unit tests crash with segment violation in heap-management code
Reported by: | simonsouth | Owned by: | nobody |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | System | Version: | R1/Development |
Keywords: | unittests | Cc: | |
Blocked By: | #14376 | Blocking: | |
Platform: | x86-64 |
Description
Running UnitTester
on x86_64 crashes in BApplication::QuitTest4 with a segment violation. Debug report attached.
The location of the actual crash varies between (at least) insert_chunk
and hoardUnsbrk
in arch-specific.cpp but the root cause seems to always be corruption of the heap's free-chunk list, sFreeChunks
, possibly due to the (lack of) locking the unit test performs.
Note this test runs fine on x86_gcc2, so the problem is something x86_64-specific.
Attachments (1)
Change History (4)
by , 9 years ago
Attachment: | UnitTester-1852-debug-31-10-2015-16-26-51.report added |
---|
comment:1 by , 9 years ago
To debug memory allocation problems, you can use LD_PRELOAD=/system/lib/libroot_debug.so ./program
. This replaces libroot with a version using a slower version of malloc that takes care of erasing freed blocks, and other protection measures, and can detect some errors earlier and closer to the point where they happen.
comment:2 by , 6 years ago
Blocked By: | 14376 added |
---|---|
Resolution: | → duplicate |
Status: | new → closed |
#14376 is a duplicate but has more information.
comment:3 by , 5 years ago
Milestone: | Unscheduled |
---|
Remove milestone for tickets with status = closed and resolution != fixed
Debug report