#5314: "internal error: heapCencus, unknown object: 0" with retainer profiling -------------------------------+-------------------------------------------- Reporter: akio | Owner: simonmar Type: bug | Status: new Priority: high | Milestone: 7.2.1 Component: Runtime System | Version: 7.0.4 Keywords: | Testcase: Blockedby: | Difficulty: Os: Linux | Blocking: Architecture: x86_64 (amd64) | Failure: Runtime crash -------------------------------+-------------------------------------------- Changes (by igloo):
* owner: igloo => simonmar Comment: {{{ Breakpoint 3, heapCensusChain (census=0xcb3210, bd=0x7ffff6903e00) at rts/ProfHeap.c:934 934 info = get_itbl((StgClosure *)p); (gdb) n 935 prim = rtsFalse; (gdb) p *info $23 = {prof = {closure_type_off = 1090616, __pad_closure_type_off = 0, closure_desc_off = 1090624, __pad_closure_desc_off = 0}, layout = { payload = {ptrs = 1, nptrs = 0}, bitmap = 1, large_bitmap_offset = 1, __pad_large_bitmap_offset = 1, selector_offset = 1}, type = 28, srt_bitmap = 0, code = 0x8eefa0 "H\213[\030H\203\343\370\377#f\017\037D"} (gdb) p p $24 = (StgPtr) 0x7ffff69f8000 (gdb) pmem p 64 [...] 0x7ffff69f8088: 0xaaaaaaaaaaaaaaaa 0x7ffff69f8080: 0xaaaaaaaaaaaaaaaa 0x7ffff69f8078: 0xaaaaaaaaaaaaaaaa 0x7ffff69f8070: 0xaaaaaaaaaaaaaaaa 0x7ffff69f8068: 0x0 0x7ffff69f8060: 0xc15b28 <Main_CAFs_cc_ccs> 0x7ffff69f8058: 0x404618 <frame_dummy+1672> 0x7ffff69f8050: 0xc8bdc8 <stg_END_TSO_QUEUE_closure> 0x7ffff69f8048: 0xc8bdc8 <stg_END_TSO_QUEUE_closure> 0x7ffff69f8040: 0xc8bdc8 <stg_END_TSO_QUEUE_closure> 0x7ffff69f8038: 0x0 0x7ffff69f8030: 0xc15b28 <Main_CAFs_cc_ccs> 0x7ffff69f8028: 0x8ef628 <stg_MVAR_CLEAN_info> 0x7ffff69f8020: 0x7ffff69f93e0 0x7ffff69f8018: 0xc8bdc8 <stg_END_TSO_QUEUE_closure> 0x7ffff69f8010: 0x0 0x7ffff69f8008: 0xc8b500 <CCS_SYSTEM> 0x7ffff69f8000: 0x8eefa0 <stg_IND_info> (gdb) p *bd $25 = {start = 0x7ffff69f8000, free = 0x7ffff69f8078, link = 0x0, u = { back = 0x7ffff69f8078, bitmap = 0x7ffff69f8078, scan = 0x7ffff69f8078}, gen = 0xc9e1a0, gen_no = 0, dest_no = 1, _pad1 = 0, flags = 1, blocks = 1, _padding = {0, 0, 0}} (gdb) n 937 switch (info->type) { (gdb) 981 size = BLACKHOLE_sizeW(); (gdb) 982 break; (gdb) p size $26 = 4 (gdb) n 1066 heapProfObject(census,(StgClosure*)p,size,prim); (gdb) p sizeof(StgInd) $27 = 32 (gdb) n 1068 p += size; (gdb) 933 while (p < bd->free) { (gdb) p p $28 = (StgPtr) 0x7ffff69f8020 }}} To my untrained eye, it looks like p should probably actually have been increased by 5. We went through this case; is the comment right?: {{{ case IND: // Special case/Delicate Hack: INDs don't normally // appear, since we're doing this heap census right // after GC. However, GarbageCollect() also does // resurrectThreads(), which can update some // blackholes when it calls raiseAsync() on the // resurrected threads. So we know that any IND will // be the size of a BLACKHOLE. size = BLACKHOLE_sizeW(); break; }}} -- Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/5314#comment:4> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler _______________________________________________ Glasgow-haskell-bugs mailing list Glasgow-haskell-bugs@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs