classpath-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [cp-patches] StringBuilder and Appendable for CVS HEAD


From: Tom Tromey
Subject: Re: [cp-patches] StringBuilder and Appendable for CVS HEAD
Date: 16 Dec 2004 12:38:57 -0700
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50

>>>>> "Jeroen" == Jeroen Frijters <address@hidden> writes:

>> Anyway, I'd prefer we find a way to make it possible not to reallocate
>> the characters when constructing the String.  It seems to me that
>> sharing is optimizing for the common case.

Jeroen> I'd prefer it too, but it simply isn't possible (without
Jeroen> synchronization).

What if we mark the "shared" field volatile?

It would be exceedingly lame if this class, whose motivation must just
be improved performance, simply represents a tradeoff of
synchronization versus GC.

Tom




reply via email to

[Prev in Thread] Current Thread [Next in Thread]