pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Fabien COELHO <coelho@cri.ensmp.fr>
Cc: Tomas Vondra <tomas.vondra@2ndquadrant.com>
Cc: Georgios Kokolatos <gkokolatos@pm.me>
Cc: PostgreSQL Developers <pgsql-hackers@lists.postgresql.org>
Subject: Re: CPU costs of random_zipfian in pgbench
Date: Mon, 01 Apr 2019 17:39:05 -0400
Message-ID: <19055.1554154745@sss.pgh.pa.us> (raw)
In-Reply-To: <alpine.DEB.2.21.1903242006310.9939@lancre>
References: <b5e172e9-ad22-48a3-86a3-589afa20e8f7@2ndquadrant.com>
	<alpine.DEB.2.21.1902221716430.4182@lancre>
	<155246731010.16480.15850913449923768119.pgcf@coridan.postgresql.org>
	<alpine.DEB.2.21.1903131048290.4059@lancre>
	<3703.1553360483@sss.pgh.pa.us>
	<alpine.DEB.2.21.1903231802440.18811@lancre>
	<010a884f-8ffc-4cb7-9773-fd05f32ef4cc@2ndquadrant.com>
	<alpine.DEB.2.21.1903241513570.9939@lancre>
	<alpine.DEB.2.21.1903241823070.9939@lancre>
	<29040.1553452066@sss.pgh.pa.us>
	<alpine.DEB.2.21.1903242006310.9939@lancre>

Fabien COELHO <coelho@cri.ensmp.fr> writes:
>> I was wondering about that too.  It seems like it'd be a wise idea to
>> further constrain s and/or n to ensure that the s > 1 code path doesn't do
>> anything too awful ...

> Yep. The attached version enforces s >= 1.001, which avoids the worse cost
> of iterating, according to my small tests.

Seems reasonable.  Pushed with minor documentation editing.

			regards, tom lane





view thread (33+ messages)  latest in thread

Message-ID: <19055.1554154745@sss.pgh.pa.us>
Permalink:  ../19055.1554154745@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/19055.1554154745@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-hackers@postgresql.org
  Cc: tgl@sss.pgh.pa.us, coelho@cri.ensmp.fr, tomas.vondra@2ndquadrant.com, gkokolatos@pm.me, pgsql-hackers@lists.postgresql.org
  Subject: Re: CPU costs of random_zipfian in pgbench
  In-Reply-To: <19055.1554154745@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox