Re: Script which shows performance of ByteA: ascii vs binary

Поиск
Список
Период
Сортировка
От Thomas Güttler
Тема Re: Script which shows performance of ByteA: ascii vs binary
Дата
Msg-id f3d5b062-d0e2-3d28-b12d-7b216b47b7b3@thomas-guettler.de
обсуждение исходный текст
Ответ на Re: Script which shows performance of ByteA: ascii vs binary  (Francisco Olarte <folarte@peoplecall.com>)
Ответы Re: Script which shows performance of ByteA: ascii vs binary  (Adrian Klaver <adrian.klaver@aklaver.com>)
Re: Script which shows performance of ByteA: ascii vs binary  (Francisco Olarte <folarte@peoplecall.com>)
Список pgsql-general

Am 22.03.19 um 13:40 schrieb Francisco Olarte:
> Thomas:
> 
> On Fri, Mar 22, 2019 at 11:22 AM Thomas Güttler
> <guettliml@thomas-guettler.de> wrote:
>> Thank you for asking several times for a benchmark.
>> I wrote it now and it is visible: inserting random bytes into bytea is much slower,
>> if you use the psycopg2 defaults.
>> Here is the chart:
>>     https://github.com/guettli/misc/blob/master/bench-bytea-inserts-postrgres.png
>> And here is the script which creates the chart:
>>     https://github.com/guettli/misc/blob/master/bench-bytea-inserts-postrgres.py
> 
> I'm not too sure, but I read ( in the code ) you are measuring a
> nearly not compressible urandom data againtst a highly compressible (
> 'x'*i ) data,
> are you sure the difference is not due to data being compressed and
> generating much less disk usage in toast-tables/wal?

+1

for this case toast-tables/wal is a detail of the implementation.
This tests does not care about the "why it takes longer". It just generates
a performance chart.

Yes, it does exactly what you say: it compares
nearly not compressible urandom data against a highly compressible data.

In my case, will get nearly random data (binary PDF, JPG, ...). And that's why
I wanted to benchmark it.

Regards,
   Thomas


-- 
Thomas Guettler http://www.thomas-guettler.de/
I am looking for feedback: https://github.com/guettli/programming-guidelines


В списке pgsql-general по дате отправления:

Предыдущее
От: Kenneth Marshall
Дата:
Сообщение: Re: Script which shows performance of ByteA: ascii vs binary
Следующее
От: Tom Lane
Дата:
Сообщение: Re: How to check is connection encrypted