Download Reference Manual
The Developer's Library for D
About Wiki Forums Source Search Contact

Ticket #1720 (reopened defect)

Opened 15 years ago

Last modified 14 years ago

deadlock in Thread.d

Reported by: kris Assigned to: fawzi
Priority: major Milestone: 1.0
Component: Core Functionality Version: 0.99.8 Sean
Keywords: Cc:

Description

According to Downs: getAll() appears to allocate memory, and resulted in a deadlock over time ...

(gdb) bt
#0  0x00007f1e106b0e14 in __lll_lock_wait () from /lib/libpthread.so.0
#1  0x00007f1e106aca73 in _L_lock_487 () from /lib/libpthread.so.0
#2  0x00007f1e106ac841 in pthread_mutex_lock () from /lib/libpthread.so.0
#3  0x00000000004cbbe7 in _d_monitorenter ()
#4  0x00000000004c28cf in _D2rt7basicgc3gcx2GC6mallocMFmkZPv ()
#5  0x00000000004c23a2 in gc_malloc ()
#6  0x00000000004c6379 in _d_newarrayT ()
#7  0x00000000004c0a6e in _D5tango4core6Thread6Thread6getAllFZAC5tango4core6Thread6Thread ()
#8  0x0000000000415210 in _D5tools3log9getThreadFZi ()

Change History

08/10/09 12:50:41 changed by fawzi

  • status changed from new to closed.
  • resolution set to fixed.

(In [4842]) * using atomic ops to synchronize threads during collection also with linux * fixing possible deadlock with getAll (fixes #1720)

01/15/10 08:45:17 changed by kris

  • status changed from closed to reopened.
  • resolution deleted.
  • milestone changed from 0.99.9 to 1.0.

this might still be an issue?

02/01/10 21:08:51 changed by fawzi

Indeed the latest branch merge lost the changes that were fixing this. To fix it one should reintroduce the use of atomic ops into Thread (or at least that is how I had fixed it). That also depends on the new atomic ops module (that is what is present in blip, tango one is likewise outdated). Should I merge back these things?