Thread View: comp.std.c++
2 messages
2 total messages
Started by Thomas Hauck
Mon, 15 Apr 1996 19:06
Is STL MT-Safe?
Author: Thomas Hauck
Date: Mon, 15 Apr 1996 19:06
Date: Mon, 15 Apr 1996 19:06
14 lines
1106 bytes
1106 bytes
Hi there, I wonder if the C++ Standard Template Library (STL) is multi-thread safe? Does anybody have experience with STL in a multi-threaded environment? Thanks Thomas --- [ comp.std.c++ is moderated. To submit articles: try just posting with ] [ your news-reader. If that fails, use mailto:std-c++@ncar.ucar.edu ] [ FAQ: http://reality.sgi.com/employees/austern_mti/std-c++/faq.html ] [ Policy: http://reality.sgi.com/employees/austern_mti/std-c++/policy.html ] [ Comments? mailto:std-c++-request@ncar.ucar.edu ]
Re: Is STL MT-Safe?
Author: Jerry Coffin
Date: Wed, 17 Apr 1996 14:57
Date: Wed, 17 Apr 1996 14:57
25 lines
1753 bytes
1753 bytes
In article <4ku297$ou6@usc.edu>, Hauck@mizar.usc.edu says...
> Hi there,
>
> I wonder if the C++ Standard Template Library (STL) is multi-thread
> safe? Does anybody have experience with STL in a multi-threaded
> environment?
Hmm...that's a bit like asking whether "cars are fast". Some are, some
aren't, and of course "fast" is a bit subjective.
Likewise with STL: the classes are defined in such as way that it should be
fairly easy to make them reentrant, and they don't require the use of a lot of
global data that would have to be made thread-local.
However, that doesn't imply that every implementation of STL will be safe for
multithreaded use. The standard says nothing about threads, so it says
equally little about the classes being safe for use with threads.
Later,
Jerry.
[ comp.std.c++ is moderated. To submit articles: try just posting with ]
[ your news-reader. If that fails, use mailto:std-c++@ncar.ucar.edu ]
[ FAQ: http://reality.sgi.com/employees/austern_mti/std-c++/faq.html ]
[ Policy: http://reality.sgi.com/employees/austern_mti/std-c++/policy.html ]
[ Comments? mailto:std-c++-request@ncar.ucar.edu ]
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads