DynamoRIO / DynamoRIO/drmemory

ASSERT and APP ASSERT (unit_tests winheap ServiceProcessStateTest)

Open
#322 0 comments 0 reactions 0 assignees View on GitHub
Bug-Assert Migrated Priority-Medium
Dominant language
C
Stars
2.7k
Forks
290
PR merge metrics
No merged PRs in 30d

Description

_From [bruen...@google.com](https://code.google.com/u/109494838902877177630/) on March 03, 2011 15:16:19_

unit_tests with winheap and -prefer_msize:

child process hits assert. cmd output has:
[----------] 1 test from URLFetcherBadHTTPSTest
[ RUN ] URLFetcherBadHTTPSTest.BadHTTPSTest
:::Dr.Memory::: Dr. Memory version 1.4.195
:::Dr.Memory::: options are "-prefer_msize -no_syscall_sentinels -pause_at_assert -logdir `C:\src\drmemory\git\build_drmemory/logs` -resfile_out "
:::Dr.Memory::: log dir is C:\src\drmemory\git\build_drmemory/logs/DrMemory-python.exe.135380.000
.\common\service_process_util_unittest.cc(220): error: Value of: g_good_shutdown
Actual: false
Expected: true
:::Dr.Memory::: ASSERT FAILURE (thread 9856): ..\src\common\alloc.c:1770: is_entirely_in_heap_region(start, end) (heap data struct inconsistency)[ OK ] URLFetcherBadHTTPSTest.BadHTTPSTest (29290 ms)
[----------] 1 test from URLFetcherBadHTTPSTest (29291 ms total)

but that's multi-process-interleaved

grepping:
logs/DrMemory-unit_tests.exe.134852.000/global.134852.log:ASSERT FAILURE (thread 9856): ..\src\common\alloc.c:1770: is_entirely_in_heap_region(start, end) (heap data struct inconsistency)

=> the assert is from here:
[ RUN ] ServiceProcessStateTest.ForceShutdown
:::Dr.Memory::: Dr. Memory version 1.4.195
:::Dr.Memory::: options are "-prefer_msize -no_syscall_sentinels -pause_at_assert -logdir `C:\src\drmemory\git\build_drmemory/logs` -resfile_out "
:::Dr.Memory::: log dir is C:\src\drmemory\git\build_drmemory/logs/DrMemory-unit_tests.exe.134852.000
.\common\service_process_util_unittest.cc(177): error: Value of: CheckServiceProcessReady()
Actual: false
Expected: true
[ FAILED ] ServiceProcessStateTest.ForceShutdown (1234 ms)

the app crash is there too: vstudio popup says 134852

0:000> U @@(routine.pc)
msvcrt!malloc:
start = 0x00d1d850 "???"
end = 0x00d1d858 "???"
real_end = 0x00d1d858 "???"
0:000> ?? *drmemorylib!heap_tree->root->right->left
struct _rb_node_t
+0x000 parent : 0x184c937c
+0x004 right : 0x184c9334
+0x008 left : 0x101a1c18
+0x00c color : 1 ( BLACK )
+0x010 base : 0x00930000 "???"
+0x014 size : 0x100000
+0x018 max : (null)
+0x01c client : 0x18d7a228
0:000> ?? *drmemorylib!heap_tree->root->right->left->right
struct _rb_node_t
+0x000 parent : 0x184c93c4
+0x004 right : 0x101a1c18
+0x008 left : 0x101a1c18
+0x00c color : 0 ( RED )
+0x010 base : 0x00f10000 "???"
+0x014 size : 0x40000
+0x018 max : (null)
+0x01c client : 0x18d83ec0
0:000> ?? *drmemorylib!heap_tree->root->right->left->right->left
struct _rb_node_t
+0x000 parent : 0x1a7aa790
+0x004 right : 0x101a1c18
+0x008 left : 0x101a1c18
+0x00c color : 1 ( BLACK )
+0x010 base : (null)
+0x014 size : 0
+0x018 max : (null)
+0x01c client : (null)

I can repro the app popup on ServiceProcessStateTest.ForceShutdown but not the drmem assert

but can't repro the drmem assert even w/ ServiceProcessStateTest.*
plus I'm not seeing any addtional processes being launched: could this have originally been some earlier test still launching children? but the app popup was in same pid and definitely matches.

I can repro the app popup natively on ServiceProcessStateTest.ForceShutdown => should add the test to the default exclude list -- and investigate whether it happens w/ tcmalloc or the regular test setup or on other machines first

_Original issue: http://code.google.com/p/drmemory/issues/detail?id=322_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.