Re: gaussian distribution pgbench

From: Fabien COELHO <coelho(at)cri(dot)ensmp(dot)fr>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: Mitsumasa KONDO <kondo(dot)mitsumasa(at)gmail(dot)com>, Andres Freund <andres(at)2ndquadrant(dot)com>, Fujii Masao <masao(dot)fujii(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: gaussian distribution pgbench
Date: 2014-07-16 04:57:46
Message-ID: alpine.DEB.2.10.1407160746040.14169@sto
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


Hello Robert,

> Well, I think the feedback has been pretty clear, honestly. Here's
> what I'm unhappy about: I can't understand what these options are
> actually doing.

We can try to improve the documentation, once more!

However, ISTM that it is not the purpose of pgbench documentation to be a
primer about what is an exponential or gaussian distribution, so the idea
would yet be to have a relatively compact explanation, and that the
interested but clueless reader would document h..self from wikipedia or a
text book or a friend or a math teacher (who could be a friend as well:-).

>> [nttcom(at)localhost postgresql]$ contrib/pgbench/pgbench --exponential=10
>> starting vacuum...end.
>> transaction type: Exponential distribution TPC-B (sort of)
>> scaling factor: 1
>> exponential threshold: 10.00000
>>
>> decile percents: 63.2% 23.3% 8.6% 3.1% 1.2% 0.4% 0.2% 0.1% 0.0% 0.0%
>> highest/lowest percent of the range: 9.5% 0.0%
>
> I don't have a clue what that means. None.

Maybe we could add in front of the decile/percent

"distribution of increasing account key values selected by pgbench:"

> Here is an example of an explanation that would make sense to me.
> This is not the actual behavior of your patch, I'm quite sure, so this
> is just an example of the *kind* of explanation that I think is
> needed:

This is more or less the approximate behavior of the patch, but for 1% of
the range, not 50%. However I'm not sure that the current documentation is
so bad.

> The --exponential option causes pgbench to select lower-numbered
> account IDs exponentially more frequently than higher-numbered account
> IDs. The argument to --exponential controls the strength of the
> preference for lower-numbered account IDs, with a smaller value
> indicating a stronger preference. Specifically, it is the percentage
> of the total number of account IDs which will receive half the total
> accesses. For example, with --exponential=10, half the accesses will
> be to the smallest 10 percent of the account IDs; half the remaining
> accesses will be to the next-smallest 10 percent of account IDs, and
> so on. --exponential=50 therefore represents a completely flat
> distribution; larger values are not allowed.

--
Fabien.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Alvaro Herrera 2014-07-16 04:58:12 Re: [COMMITTERS] pgsql: Reset master xmin when hot_standby_feedback disabled.
Previous Message Alvaro Herrera 2014-07-16 04:46:59 Re: 9.3: more problems with "Could not open file "pg_multixact/members/xxxx"