Re: gaussian distribution pgbench

From: Fabien COELHO <coelho(at)cri(dot)ensmp(dot)fr>
To: KONDO Mitsumasa <kondo(dot)mitsumasa(at)lab(dot)ntt(dot)co(dot)jp>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: gaussian distribution pgbench
Date: 2014-02-23 10:52:06
Message-ID: alpine.DEB.2.10.1402231148250.24063@sto
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


Gaussian Pgbench v8 patch by Mitsumasa KONDO review & patch v9.

* The purpose of the patch is to allow a pgbench script to draw from normally
distributed or exponentially distributed integer values instead of uniformly
distributed.

This is a valuable contribution to enable pgbench to generate more realistic
loads, which is seldom uniform in practice.

* Very minor change

I have updated the patch (v9) based on Mitsumasa latest v8:
- remove one spurious space in the help message.

* Compilation

The patch applies cleanly and compiles against current head.

* Check

I have checked that the aid values are skewed depending on the
parameters by looking at the "aid" distribution in the "pgbench_history"
table after a run.

* Mathematical soundness

I've checked the mathematical soundness of the methods involved.

I'm fine with casting doubles to integers for having the expected
distribution on integers.

Although there is a retry loop for finding a suitable, the looping
probability is low thanks to the minimum threshold parameter required.

* Conclusion

I suggest to apply this patch which provide a useful and more realistic
testing capability to pgbench.

--
Fabien.

Attachment Content-Type Size
gaussian_and_exponential_pgbench_v9.patch text/x-diff 22.1 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Kohei KaiGai 2014-02-23 13:24:14 Re: Custom Scan APIs (Re: Custom Plan node)
Previous Message Amit Kapila 2014-02-23 05:44:18 Re: Patch: show relation and tuple infos of a lock to acquire