This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: tree-ssa -fmudflap problems


Hi -

On Tue, Apr 01, 2003 at 08:15:03AM +1000, Eyal Lebedinsky wrote:
> >  You might try linking your program without -lpthread.
> > (lib)mudflap does not support multithreaded apps yet.
> This is a problem as my application is heavily
> multithreaded. Any way around it?

There are two separate issues.  The first issue is that the
libmudflap runtime does not protect its internal data structures
from multithreaded access.  At the least, it just needs some
mutexes here and there.  The second issue is that there is an
odd litle infinite recursion during the shared library startup
of libmudflap when -lpthreads is linked in.  (dlsym requires
calloc; calloc requires dlsym.)  Until this is fixed, static
linking may work around it.

As for the smaller test program you sent, I believe my fixes
this afternoon make it run correctly.


- FChE


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]