Hi Amos,
Interesting trace. Can you check if the following patch fixes this race
condition for you?
-----------------------------------------------------------------------------
--- dot.cpp.org 2013-01-20 13:54:23.000000000 +0100
+++ dot.cpp 2013-01-24 22:28:37.000000000 +0100
@@ -1142,7 +1142,7 @@
{
QMutexLocker locker(&m_mutex);
m_queue.enqueue(runner);
- m_bufferNotEmpty.wakeAll();
+ m_bufferNotEmpty.wakeOne();
}
DotRunner *DotRunnerQueue::dequeue()
-----------------------------------------------------------------------------
Regards,
Dimitri
On Jan 24, 2013, at 22:02 , Amos Anderson <[email protected]> wrote:
> Hello --
>
> Doxygen 1.8.3.1 is segfaulting on me. The exact same version works on my
> other Linux machine and on OSX, and previous versions of doxygen work on this
> particular machine too.
>
> The segfault goes away if I make this config file change:
>
>
> -DOT_NUM_THREADS = 0
> +DOT_NUM_THREADS = 1
>
>
>
> The output immediately preceding the segfault:
> Generating annotated compound index...
> Generating alphabetical compound index...
> Generating hierarchical class index...
> Generating graphical class hierarchy...
> Generating member index...
> Generating file index...
> Generating file member index...
> Generating example index...
> finalizing index lists...
> Generating dot graphs using 9 parallel threads...
>
>
> The version of dot I'm using:
>
>> dot -v
> dot - graphviz version 2.30.0 (20130124.0007)
>
>
>
> The gdb output:
>
> [yoda]/home/amosa/src/doxygen-1.8.3.1> gdb --pid=29784
> GNU gdb (GDB) Red Hat Enterprise Linux (7.0.1-37.el5)
> Copyright (C) 2009 Free Software Foundation, Inc.
> License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
> This is free software: you are free to change and redistribute it.
> There is NO WARRANTY, to the extent permitted by law. Type "show copying"
> and "show warranty" for details.
> This GDB was configured as "x86_64-redhat-linux-gnu".
> For bug reporting instructions, please see:
> <http://www.gnu.org/software/gdb/bugs/>.
> Attaching to process 29784
> Reading symbols from /home/amosa/bin/doxygen...done.
> Reading symbols from /opt/mpi/openmpi/1.5.4/gcc/lib64/libmpi.so...done.
> Loaded symbols for /opt/mpi/openmpi/1.5.4/gcc/lib64/libmpi.so
> Reading symbols from /lib64/libpthread.so.0...(no debugging symbols
> found)...done.
> [Thread debugging using libthread_db enabled]
> Loaded symbols for /lib64/libpthread.so.0
> Reading symbols from /usr/lib64/libstdc++.so.6...(no debugging symbols
> found)...done.
> Loaded symbols for /usr/lib64/libstdc++.so.6
> Reading symbols from /lib64/libm.so.6...(no debugging symbols found)...done.
> Loaded symbols for /lib64/libm.so.6
> Reading symbols from /lib64/libgcc_s.so.1...(no debugging symbols
> found)...done.
> Loaded symbols for /lib64/libgcc_s.so.1
> Reading symbols from /lib64/libc.so.6...(no debugging symbols found)...done.
> Loaded symbols for /lib64/libc.so.6
> Reading symbols from /lib64/libdl.so.2...(no debugging symbols found)...done.
> Loaded symbols for /lib64/libdl.so.2
> Reading symbols from /lib64/libnsl.so.1...(no debugging symbols found)...done.
> Loaded symbols for /lib64/libnsl.so.1
> Reading symbols from /lib64/libutil.so.1...(no debugging symbols
> found)...done.
> Loaded symbols for /lib64/libutil.so.1
> Reading symbols from /lib64/ld-linux-x86-64.so.2...(no debugging symbols
> found)...done.
> Loaded symbols for /lib64/ld-linux-x86-64.so.2
>
> warning: no loadable sections found in added symbol-file system-supplied DSO
> at 0x7fff97b89000
> opal_memory_ptmalloc2_int_malloc (av=0x2b1fc09393c0, bytes=24) at
> malloc.c:3938
> 3938 malloc.c: No such file or directory.
> in malloc.c
> (gdb) where
> #0 opal_memory_ptmalloc2_int_malloc (av=0x2b1fc09393c0, bytes=24) at
> malloc.c:3938
> #1 0x00002b1fc06be967 in opal_memory_ptmalloc2_malloc (bytes=24) at
> malloc.c:3432
> #2 0x000000359f4bd1dd in operator new(unsigned long) () from
> /usr/lib64/libstdc++.so.6
> #3 0x00000000007120a2 in QGList::append (this=0x1c7815c0, d=0x7fff97b4e1c0)
> at qglist.cpp:366
> #4 0x000000000071233b in QGListIterator::QGListIterator
> (this=0x7fff97b4e1c0, l=...) at qglist.cpp:1063
> #5 0x000000000048d059 in QListIterator<BaseClassDef>::QListIterator
> (this=0x7fff97b4e1c0, l=...)
> at ../qtools/qlist.h:111
> #6 0x000000000048d079 in BaseClassListIterator::BaseClassListIterator
> (this=0x7fff97b4e1c0, bcl=...) at classdef.h:519
> #7 0x000000000062938a in ClassDef::isBaseClass (this=0x1c82fa10,
> bcd=0x1c841940, followInstances=true, level=0)
> at classdef.cpp:2584
> #8 0x0000000000629493 in ClassDef::isAccessibleMember (this=0x1c82fa10,
> md=0x1c969670) at classdef.cpp:3787
> #9 0x00000000005e93dd in isAccessibleFrom (scope=0x1c82fa10,
> fileScope=0x1c6a8a30, item=0x1c969670) at util.cpp:966
> #10 0x00000000005e9721 in isAccessibleFromWithExpScope (scope=0x1c82fa10,
> fileScope=0x1c6a8a30, item=0x1c969670,
> explicitScopePart=...) at util.cpp:1054
> #11 0x00000000005eb3e3 in substTypedef (scope=0x1c82fa10,
> fileScope=0x1c6a8a30, name=..., pTypeDef=0x7fff97b4e4d0)
> at util.cpp:690
> #12 0x00000000005e8dfd in followPath (start=0x1c60c3f0, fileScope=0x1c6a8a30,
> path=...) at util.cpp:761
> #13 0x00000000005e97f9 in isAccessibleFromWithExpScope (scope=0x1c60c3f0,
> fileScope=0x1c6a8a30, item=0x1d0db1e0,
> explicitScopePart=...) at util.cpp:1069
> #14 0x00000000005e9be5 in isAccessibleFromWithExpScope (scope=0x1c892100,
> fileScope=0x1c6a8a30, item=0x1d0db1e0,
> explicitScopePart=...) at util.cpp:1187
> #15 0x00000000005e9be5 in isAccessibleFromWithExpScope (scope=0x1c82fa10,
> fileScope=0x1c6a8a30, item=0x1d0db1e0,
> explicitScopePart=...) at util.cpp:1187
> #16 0x00000000005ea076 in getResolvedSymbol (scope=0x1c82fa10,
> fileScope=0x1c6a8a30, d=0x1d0db1e0,
> explicitScopePart=..., actTemplParams=0x7fff97b4e930,
> minDistance=@0x7fff97b4e99c, bestMatch=@0x7fff97b4e9c8,
> bestTypedef=@0x7fff97b4e9c0, bestTemplSpec=..., bestResolvedType=...) at
> util.cpp:1230
> #17 0x00000000005eab76 in getResolvedClassRec (scope=0x1c82fa10,
> fileScope=0x1c6a8a30,
> n=0x1d6bd9f0 "ads::NotEqualToByHandle::Base::result_type", pTypeDef=0x0,
> pTemplSpec=0x0, pResolvedType=0x0)
> at util.cpp:1509
> #18 0x00000000005eaf07 in getResolvedClass (scope=0x1c82fa10,
> fileScope=0x1c6a8a30,
> n=0x1d6bd9f0 "ads::NotEqualToByHandle::Base::result_type", pTypeDef=0x0,
> pTemplSpec=0x0, mayBeUnlinkable=false,
> mayBeHidden=false, pResolvedType=0x0) at util.cpp:1586
> #19 0x0000000000638e83 in stripClassName (s=0x1d8beee0 "Base::result_type",
> d=0x1c82fa10) at code.l:686
> #20 0x0000000000639f7d in generateClassMemberLink (ol=..., xmd=0x1c941ca0,
> memName=0x2b1fc47a366d "result_type")
> at code.l:1145
> #21 0x000000000063d0fb in generateFunctionLink (ol=...,
> funcName=0x2b1fc47a366d "result_type") at code.l:1321
> #22 0x000000000064218c in codeYYlex () at code.l:2533
> #23 0x0000000000647d32 in parseCCode (od=..., className=0x0, s=...,
> exBlock=false, exName=0x0, fd=0x1c6a8a30,
> startLine=-1, endLine=-1, inlineFragment=false, memberDef=0x0,
> showLineNumbers=true, searchCtx=0x0) at code.l:3631
> #24 0x00000000005956dd in CLanguageScanner::parseCode (this=0x1c5d8590,
> codeOutIntf=..., scopeName=0x0, input=...,
> isExampleBlock=false, exampleName=0x0, fileDef=0x1c6a8a30, startLine=-1,
> endLine=-1, inlineFragment=false,
> memberDef=0x0, showLineNumbers=true, searchCtx=0x0) at scanner.l:6471
> #25 0x000000000043e7f3 in FileDef::writeSource (this=0x1c6a8a30, ol=...) at
> filedef.cpp:852
> #26 0x000000000040429d in generateFileSources () at doxygen.cpp:7460
> #27 0x000000000042662c in generateOutput () at doxygen.cpp:10690
> #28 0x00000000004030bc in main (argc=2, argv=0x7fff97b4fab8) at main.cpp:38
> (gdb) continue
> Continuing.
> [New Thread 0x41ec8940 (LWP 29806)]
> [New Thread 0x428c9940 (LWP 29807)]
> [New Thread 0x432ca940 (LWP 29808)]
> [New Thread 0x43ccb940 (LWP 29809)]
> [New Thread 0x446cc940 (LWP 29810)]
> [New Thread 0x450cd940 (LWP 29811)]
> [New Thread 0x45ace940 (LWP 29812)]
> [New Thread 0x464cf940 (LWP 29813)]
> [New Thread 0x46ed0940 (LWP 29814)]
> Detaching after fork from child process 29858.
> Detaching after fork from child process 29859.
> Detaching after fork from child process 29860.
> Detaching after fork from child process 29861.
>
> Program received signal SIGSEGV, Segmentation fault.
> [Switching to Thread 0x432ca940 (LWP 29808)]
> 0x000000358c671e0a in _int_free () from /lib64/libc.so.6
> (gdb) backtrace
> #0 0x000000358c671e0a in _int_free () from /lib64/libc.so.6
> #1 0x000000358c676192 in free_atfork () from /lib64/libc.so.6
> #2 0x000000358c672941 in free () from /lib64/libc.so.6
> #3 0x0000000000712ccf in QGList::takeFirst (this=0x1e5d95f8) at
> qglist.cpp:628
> #4 0x00000000006c84bd in QQueue<DotRunner>::dequeue (this=0x1e5d95f8) at
> ../qtools/qqueue.h:59
> #5 0x00000000006c368b in DotRunnerQueue::dequeue (this=0x1e5d95f0) at
> dot.cpp:1156
> #6 0x00000000006c5ebc in DotWorkerThread::run (this=0x1e5d7700) at
> dot.cpp:1177
> #7 0x00000000007420ec in QThreadPrivate::start (arg=0x1e5d7700) at
> qthread_unix.cpp:87
> #8 0x000000358d20673d in start_thread () from /lib64/libpthread.so.0
> #9 0x000000358c6d44bd in clone () from /lib64/libc.so.6
> (gdb) info frame
> Stack level 0, frame at 0x432c9f70:
> rip = 0x358c671e0a in _int_free; saved rip 0x358c676192
> called by frame at 0x432c9fb0
> Arglist at 0x432c9ed8, args:
> Locals at 0x432c9ed8, Previous frame's sp is 0x432c9f70
> Saved registers:
> rbx at 0x432c9f38, rbp at 0x432c9f40, r12 at 0x432c9f48, r13 at 0x432c9f50,
> r14 at 0x432c9f58, r15 at 0x432c9f60,
> rip at 0x432c9f68
> (gdb) up
> #1 0x000000358c676192 in free_atfork () from /lib64/libc.so.6
> (gdb) up
> #2 0x000000358c672941 in free () from /lib64/libc.so.6
> (gdb) up
> #3 0x0000000000712ccf in QGList::takeFirst (this=0x1e5d95f8) at
> qglist.cpp:628
> 628 delete n;
> (gdb) info frame
> Stack level 3, frame at 0x432ca020:
> rip = 0x712ccf in QGList::takeFirst (qglist.cpp:628); saved rip 0x6c84bd
> called by frame at 0x432ca040, caller of frame at 0x432c9ff0
> source language c++.
> Arglist at 0x432ca010, args: this=0x1e5d95f8
> Locals at 0x432ca010, Previous frame's sp is 0x432ca020
> Saved registers:
> rbp at 0x432ca010, rip at 0x432ca018
> (gdb) info locals
> n = 0x1e8e9c10
> d = 0x1e5e13f0
> (gdb)
>
>
>
>
> ------------------------------------------------------------------------------
> Master Visual Studio, SharePoint, SQL, ASP.NET, C# 2012, HTML5, CSS,
> MVC, Windows 8 Apps, JavaScript and much more. Keep your skills current
> with LearnDevNow - 3,200 step-by-step video tutorials by Microsoft
> MVPs and experts. ON SALE this month only -- learn more at:
> http://p.sf.net/sfu/learnnow-d2d
> _______________________________________________
> Doxygen-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/doxygen-users
------------------------------------------------------------------------------
Master Visual Studio, SharePoint, SQL, ASP.NET, C# 2012, HTML5, CSS,
MVC, Windows 8 Apps, JavaScript and much more. Keep your skills current
with LearnDevNow - 3,200 step-by-step video tutorials by Microsoft
MVPs and experts. ON SALE this month only -- learn more at:
http://p.sf.net/sfu/learnnow-d2d
_______________________________________________
Doxygen-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/doxygen-users