[erlang-questions] Ets read concurrency tweak
Viacheslav V. Kovalev
kovyl2404@REDACTED
Fri May 15 13:00:26 CEST 2015
I've added writer process to my test. It perfoms random write per each
100 ms. Implementation is here:
https://gist.github.com/kovyl2404/622a9908c4e8a2abc214
There is example of run on 8-core machine.
29> ets_read_concurrency:analyze(WithoutWriter).
[{{procs,1},{percent,-8.998057178933019}},
{{procs,2},{percent,1.474232611754453}},
{{procs,4},{percent,-0.4318193657099243}},
{{procs,8},{percent,4.796912026714365}},
{{procs,16},{percent,4.926194326111598}},
{{procs,32},{percent,7.4091491628647805}},
{{procs,64},{percent,6.7226404897426315}},
{{procs,128},{percent,7.129140726319386}},
{{procs,256},{percent,-28.200373148451757}},
{{procs,512},{percent,10.229583687247757}},
{{procs,1024},{percent,25.824989572270635}}]
30> ets_read_concurrency:analyze(WithWriter).
[{{procs,1},{percent,-9.233383915316411}},
{{procs,2},{percent,1.3554058972355476}},
{{procs,4},{percent,-1.3437122387165232}},
{{procs,8},{percent,0.3944371727018411}},
{{procs,16},{percent,21.719493229803017}},
{{procs,32},{percent,-26.32711009412866}},
{{procs,64},{percent,11.577461884371825}},
{{procs,128},{percent,19.608517106505893}},
{{procs,256},{percent,11.362311552960543}},
{{procs,512},{percent,20.935963863004808}},
{{procs,1024},{percent,22.512472513575506}}]
Where percent calculated as `(NonTweakedTime - TweakedTime)/NonTweaked*100`
Tweaked table shows stable performance advantage either with or
without writer process. I think I was wrong when interpreted former
results, but frankly I expected to see more drastic changes. Again, I
don't know how to interpret this artifacts:
{{procs,256},{percent,-28.200373148451757}}. %% WithoutWriter
{{procs,32},{percent,-26.32711009412866}}. %% WithWriter
Is this just statistical error or something else?
More information about the erlang-questions
mailing list