Skip to content

Conversation

@csw
Copy link

@csw csw commented Sep 12, 2019

A long-standing concurrency bug (#157) was causing get5primeUtrs() to throw ConcurrentModificationException in multithreaded mode. Running with large numbers of cores (96, for instance) exacerbated the problem.

A Transcript was being shared between threads, and they were concurrently modifying the utrs member. This change makes all methods synchronized to prevent concurrent use of any of the internals. That might be more synchronization than absolutely necessary, but it
appears to solve the problem without a dramatic performance penalty.

A long-standing concurrency bug (pcingola#157) was causing
get5primeUtrs() to throw ConcurrentModificationException in
multithreaded mode. Running with large numbers of cores (96, for
instance) exacerbated the problem.

A Transcript was being shared between threads, and they were
concurrently modifying the utrs member. This change makes all methods
synchronized to prevent concurrent use of any of the internals. That
might be more synchronization than absolutely necessary, but it
appears to solve the problem without a dramatic performance penalty.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant