Re: [PERFORM] 10x faster sort performance on Skylake CPU vs Ivy Bridge - Mailing list pgsql-performance

From Tom Lane
Subject Re: [PERFORM] 10x faster sort performance on Skylake CPU vs Ivy Bridge
Date
Msg-id 793.1503673641@sss.pgh.pa.us
Whole thread Raw
In response to [PERFORM] 10x faster sort performance on Skylake CPU vs Ivy Bridge  (Felix Geisendörfer <felix@felixge.de>)
Responses Re: [PERFORM] 10x faster sort performance on Skylake CPU vs Ivy Bridge
Re: [PERFORM] 10x faster sort performance on Skylake CPU vs IvyBridge
List pgsql-performance
=?utf-8?Q?Felix_Geisend=C3=B6rfer?= <felix@felixge.de> writes:
> I recently came across a performance difference between two machines that surprised me:
> ...
> As you can see, Machine A spends 5889ms on the Sort Node vs 609ms on Machine B when looking at the "Exclusive" time
withexplain.depesz.com [3][4]. I.e. Machine B is ~10x faster at sorting than Machine B (for this particular query). 

I doubt this is a hardware issue, it's more likely that you're comparing
apples and oranges.  The first theory that springs to mind is that the
sort keys are strings and you're using C locale on the faster machine but
some non-C locale on the slower.  strcoll() is pretty darn expensive
compared to strcmp() :-(

            regards, tom lane


pgsql-performance by date:

Previous
From: "David G. Johnston"
Date:
Subject: Re: [PERFORM] Hi
Next
From: Tomas Vondra
Date:
Subject: Re: [PERFORM] Execution plan analysis