Re: Review Request : 7071826 : Avoid benign race condition in initialization of UUID

2012-05-12 Thread Brian Goetz
Oops, forgot to actually review the patch: approved. On 5/10/2012 7:11 PM, Mike Duigou wrote: Hello all; A benign but potentially expensive race condition was discovered in java.util.UUID. The initialization of numberGenerator may cause the creation of a number of SecureRandom instances if mu

Re: Review Request : 7071826 : Avoid benign race condition in initialization of UUID

2012-05-12 Thread Brian Goetz
Farther afield: the "Holder" idiom for thread-safe lazy initialization is one that we could now replace with invokedynamic (since a ConstantCallSize acts as a lazily initialize cache), if there were only a way to actually express the indy code from Java. This would let us replace a class with