Uploaded image for project: 'Commons RNG'
  1. Commons RNG
  2. RNG-108

Update the SeedFactory to improve performance

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Implemented
    • 1.3
    • 1.3
    • simple
    • None

    Description

      The SeedFactory uses Well44497b mixed with a hashCode as the underlying generator. This has output that does not pass BigCrush. Generation of numbers uses a synchronized block around the generator on each call to the generator.

      Analysis has shown that:

      • Speed of seed array generation can be improved by outputting multiple values per synchronisation
      • Use of a XorShift1024SPhi generator which natively passes BigCrush will provide enough output for seed generation before the period expires
      • Synchronisation with a ReentrantLock provides more stable performance during concurrent access

      Update the SeedFactory to:

      • Output arrays using blocks of numbers per synchronisation event
      • Use XorShift1024SPhi
      • Use a ReentrantLock

      Attachments

        Issue Links

          Activity

            People

              aherbert Alex Herbert
              aherbert Alex Herbert
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 50m
                  50m