[ 
https://issues.apache.org/jira/browse/RNG-75?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16854632#comment-16854632
 ] 

Alex D Herbert commented on RNG-75:
-----------------------------------

{quote}Performance is a non-goal for this class.
{quote}
That was the impression I was working under. It was not clear from my post that 
I was pointing out that the main cost of constructing a SplitMix generator is 
the SeedFactory creating a new long. I agree that the output from the 
SeedFactory is good. 

I am currently running a Well44497b generator xor'd with the output of System 
getIdentityHashCode through the stress test application. A quick checks shows 
it passes SmallCrush (there was 1 fail from 5 runs for a plain Well44497b) and 
is about 33% slower to run the test. This shows that the Java-to-C bridge is 
the main bottle neck in the stress test application. Anyway it should be done 
by tomorrow and I expect the output to pass. I do not suggest altering the 
SeedFactory. The performance test was to gauge how to add new *create...Fast* 
methods to the SeedFactory.

I have another table that shows the relative performance of using the 
RandomSource.create method against using the *new* keyword to create the 
generator, with a seed dynamically created by the SeedFactory and with a 
pre-built seed. The pre-built seed case shows that reflection is a lot slower 
when the seeding routine is simple. However I would assign the later as a 
minority case. Building a generator in the majority case would require building 
a new seed. I'll post this table later (as I do not have it on my current 
workstation).

 

> Improve the speed of the RandomSource create method.
> ----------------------------------------------------
>
>                 Key: RNG-75
>                 URL: https://issues.apache.org/jira/browse/RNG-75
>             Project: Commons RNG
>          Issue Type: Improvement
>          Components: simple
>    Affects Versions: 1.3
>            Reporter: Alex D Herbert
>            Assignee: Alex D Herbert
>            Priority: Minor
>             Fix For: 1.3
>
>         Attachments: large.jpg, long.jpg, small.jpg
>
>
> Update the {{o.a.c.rng.simple.internal}} package to improve the construction 
> speed of random generators.
> Areas identified by the construction benchmark 
> [RNG-72|https://issues.apache.org/jira/projects/RNG/issues/RNG-72] include:
> * Update the {{RandomSourceInternal}} to know the desired size for the native 
> seed
> * Update the {{SeedFactory}} for faster {{byte[]}} conversions
> * Remove the use of reflection for fast seeding generators
> It is intended that all changes made are non-destructive to the quality of 
> any generated seed.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to