Issue Details (XML | Word | Printable)

Key: STDCXX-914
Type: Improvement Improvement
Status: Open Open
Priority: Critical Critical
Assignee: Martin Sebor
Reporter: Martin Sebor
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
C++ Standard Library

sstream ctors inefficient in reentrant modes

Created: 07/May/08 04:08 AM   Updated: 03/Dec/08 04:09 AM
Return to search
Component/s: 27. Input/Output
Affects Version/s: 4.1.2, 4.1.3, 4.1.4, 4.2.0, 4.2.1
Fix Version/s: 4.2.2

Time Tracking:
Original Estimate: 12h
Original Estimate - 12h
Remaining Estimate: 9.5h
Time Spent - 2.5h Remaining Estimate - 9.5h
Time Spent: 2.5h
Time Spent - 2.5h Remaining Estimate - 9.5h

File Attachments:
  Size
Text File Licensed for inclusion in ASF works stdcxx-914-gprof-gcc-4.1.2-12D.txt 2008-11-08 06:07 PM Martin Sebor 13 kB
Text File Licensed for inclusion in ASF works stdcxx-914-gprof-gcc-4.3.0-12S.txt 2008-11-08 06:02 PM Martin Sebor 62 kB

Severity: Inefficiency


 Description  « Hide
As discussed in this thread stream ctors in thread-safe builds are inefficient due to the initialization of the mutex data member in every stream, even in those that never use it. As soon as binary compatibility rules permit it we should remove the mutex and/or defer its initialization until it's needed. It might be possible to implement the deferred initialization as early as 4.2.2, or maybe 4.3. Complete removal will need to wait until 5.0.

 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Repository Revision Date User Message
ASF #712454 Sun Nov 09 00:45:30 UTC 2008 sebor 2008-11-08 Martin Sebor <sebor@apache.org>

STDCXX-914
* src/locale_body (__rw_locale::_C_manage): Optimized the detection
and "destruction" of the classic C locale.
(__rw_locale::_C_is_managed): Optimized the detection of the same.
Files Changed
MODIFY /stdcxx/branches/4.2.x/src/locale_body.cpp