Author: Pat King
Date: 06:23:36 08/12/01
Go up one level in this thread
I had thought that a map ensured unique entries. Apparently not when multithreading in windows with mingw. Things worked again normally when I guarded the access to the STL code to prevent simul access. Slower of course, but you expect that in profiling. On August 11, 2001 at 21:02:47, Pat King wrote: >Apologies if this is more or less a repeat, I had trouble posting. > >I'm using a windows port of gnu c++, no profiling tools. I have a helper class >which I use to generate function counts. This class, and the reporting >functions, use an STL map to hold function names and counts. When I implemented >ppondering, and thus introduced threads to my program, suddenly my profiling >report showed repeats of functions, with different counts. > >a) Different counts for different threads? > >b) Is the gnu STL really thread safe? Can these counts be trusted at all? > >c) What does "thread safe" mean anyway? It doesn't crash, but is it right? > >inquiring minds want to know. > >TIA > >Pat
This page took 0 seconds to execute
Last modified: Thu, 15 Apr 21 08:11:13 -0700
Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.