Re: [Valgrind-users] novice drd user. Errors in std streams

2010-05-11 Thread Konstantin Serebryany
> > > Have you already found a workaround that allows to avoid triggering > the race report on std::locale::locale() ? If not, it would help if > you could post a small example that allows to reproduce this behavior. > You may like the test NegativeTests.EmptyRepTest from http://code.google.com/p/

Re: [Valgrind-users] novice drd user. Errors in std streams

2010-05-08 Thread Bart Van Assche
On Wed, Apr 21, 2010 at 3:40 AM, Jorge Moraleda wrote: >>> Hello Jorge, >>> >>> Unfortunately not all libraries have been designed with data-race >>> detection tools in mind. Several libraries contain code that triggers >>> benign data races. Examples are the I/O code in libstdc++ and in libc. >>>

Re: [Valgrind-users] novice drd user. Errors in std streams

2010-04-20 Thread Konstantin Serebryany
On Wed, Apr 21, 2010 at 5:40 AM, Jorge Moraleda wrote: > >> Hello Jorge, > >> > >> Unfortunately not all libraries have been designed with data-race > >> detection tools in mind. Several libraries contain code that triggers > >> benign data races. Examples are the I/O code in libstdc++ and in libc

Re: [Valgrind-users] novice drd user. Errors in std streams

2010-04-20 Thread Jorge Moraleda
>> Hello Jorge, >> >> Unfortunately not all libraries have been designed with data-race >> detection tools in mind. Several libraries contain code that triggers >> benign data races. Examples are the I/O code in libstdc++ and in libc. >> >> You can either create a suppression pattern to suppress th

Re: [Valgrind-users] novice drd user. Errors in std streams

2010-04-07 Thread Jorge Moraleda
> > > > I found the following bug-report against gcc: > > http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40518 > > It seems that the problem is fixed in gcc 4.5. Until it is released, I > > added code to my application to not clear empty strings, and it seems > > to solve all the these problems. Thank

Re: [Valgrind-users] novice drd user. Errors in std streams

2010-04-07 Thread Bart Van Assche
On Wed, Apr 7, 2010 at 3:32 AM, Jorge Moraleda wrote: > > > > > #include > > #include > > #include > > > > void *threadEntry(void *threadid) > > { > >   long tid; > >   tid = (long)threadid; > >         std::string myString; > >         for (int i = 0; i<5; i++) { > >                 myString.c

Re: [Valgrind-users] novice drd user. Errors in std streams

2010-04-06 Thread Konstantin Serebryany
The race on _M_mutate is (most likely) the one discussed at http://permalink.gmane.org/gmane.comp.debugging.valgrind/10043 --kcc On Tue, Apr 6, 2010 at 4:14 PM, Jorge Moraleda wrote: > On Tue, Apr 6, 2010 at 3:30 AM, Bart Van Assche

Re: [Valgrind-users] novice drd user. Errors in std streams

2010-04-06 Thread Jorge Moraleda
> > #include > #include > #include > > void *threadEntry(void *threadid) > { >   long tid; >   tid = (long)threadid; >         std::string myString; >         for (int i = 0; i<5; i++) { >                 myString.clear(); >                 pthread_yield(); >         } >         pthread_exit(NUL

Re: [Valgrind-users] novice drd user. Errors in std streams

2010-04-06 Thread Jorge Moraleda
On Tue, Apr 6, 2010 at 3:30 AM, Bart Van Assche wrote: > On Tue, Apr 6, 2010 at 12:25 PM, Konstantin Serebryany > wrote: >> >> >> On Tue, Apr 6, 2010 at 2:17 PM, Bart Van Assche wrote: >>> >>> On Tue, Apr 6, 2010 at 7:53 AM, Jorge Moraleda >>> wrote: >>> > >>> > Dear all, >>> > >>> > When I com

Re: [Valgrind-users] novice drd user. Errors in std streams

2010-04-06 Thread Bart Van Assche
On Tue, Apr 6, 2010 at 12:25 PM, Konstantin Serebryany wrote: > > > On Tue, Apr 6, 2010 at 2:17 PM, Bart Van Assche wrote: >> >> On Tue, Apr 6, 2010 at 7:53 AM, Jorge Moraleda >> wrote: >> > >> > Dear all, >> > >> > When I compile the following program with: >> > $ g++ -g -pthread threads.cpp >>

Re: [Valgrind-users] novice drd user. Errors in std streams

2010-04-06 Thread Konstantin Serebryany
On Tue, Apr 6, 2010 at 2:17 PM, Bart Van Assche wrote: > On Tue, Apr 6, 2010 at 7:53 AM, Jorge Moraleda > wrote: > > > > Dear all, > > > > When I compile the following program with: > > $ g++ -g -pthread threads.cpp > > > > // begin program / > > // fi

Re: [Valgrind-users] novice drd user. Errors in std streams

2010-04-06 Thread Bart Van Assche
On Tue, Apr 6, 2010 at 7:53 AM, Jorge Moraleda wrote: > > Dear all, > > When I compile the following program with: > $ g++ -g -pthread threads.cpp > > // begin program / > // file: threads.cpp > #include > #include > #include > > void *threadEntry(voi

Re: [Valgrind-users] novice drd user. Errors in std streams

2010-04-05 Thread Konstantin Serebryany
This could be the same issue as discussed in http://permalink.gmane.org/gmane.comp.debugging.valgrind/10043 --kcc On Tue, Apr 6, 2010 at 9:53 AM, Jorge Moraleda wrote: > Dear all, > > When I compile the following program with: > $ g

[Valgrind-users] novice drd user. Errors in std streams

2010-04-05 Thread Jorge Moraleda
Dear all, When I compile the following program with: $ g++ -g -pthread threads.cpp // begin program / // file: threads.cpp #include #include #include void *threadEntry(void *threadid) {   long tid;   tid = (long)threadid;         for (int i = 0; i<5