Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id 3C5EF1337B54 for ; Tue, 12 Apr 2011 04:31:44 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.251]) (amavisd-maia, port 10024) with ESMTP id 07312-07 for ; Tue, 12 Apr 2011 07:31:25 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from adonis.tweakers.net (adonis.tweakers.net [213.239.154.11]) by mail.postgresql.org (Postfix) with ESMTP id 48C9B133616B for ; Tue, 12 Apr 2011 04:31:24 -0300 (ADT) Received: from [192.168.0.13] (f110172.upc-f.chello.nl [80.56.110.172]) by adonis.tweakers.net (Postfix) with ESMTPSA id 80A9820B4B for ; Tue, 12 Apr 2011 09:31:22 +0200 (CEST) Message-ID: <4DA3FFC8.206@tweakers.net> Date: Tue, 12 Apr 2011 09:31:20 +0200 From: Arjen van der Meijden User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.9.2.15) Gecko/20110303 Lightning/1.0b2 Thunderbird/3.1.9 MIME-Version: 1.0 To: pgsql-performance@postgresql.org Subject: Re: Linux: more cores = less concurrency. References: <860299.67368.qm@web26003.mail.ukl.yahoo.com> <4DA2FD7B020000250003C678@gw.wicourts.gov> <8b76c51ad6db2e458431ef73bcdd2759@commandprompt.com> <4DA35BD3.5040206@netwolves.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.91 tagged_above=-10 required=5 tests=BAYES_00=-1.9, T_RP_MATCHES_RCVD=-0.01 X-Spam-Level: X-Archive-Number: 201104/143 X-Sequence-Number: 43205 On 11-4-2011 22:04 david@lang.hm wrote: > in your case, try your new servers without hyperthreading. you will end > up with a 4x4 core system, which should handily outperform the 2x4 core > system you are replacing. > > the limit isn't 8 cores, it's that the hyperthreaded cores don't work > well with the postgres access patterns. It would be really weird if disabling HT would turn these 8-core cpu's in 4-core cpu's ;) They have 8 physical cores and 16 threads each. So he basically has a 32-core machine with 64 threads in total (if HT were enabled). Still, HT may or may not improve things, back when we had time to benchmark new systems we had one of the first HT-Xeon's (a dual 5080, with two cores + HT each) available: http://ic.tweakimg.net/ext/i/1155958729.png The blue lines are all slightly above the orange/red lines. So back then HT slightly improved our read-mostly Postgresql benchmark score. We also did benchmarks with Sun's UltraSparc T2 back then: http://ic.tweakimg.net/ext/i/1214930814.png Adding full cores (including threads) made things much better, but we also tested full cores with more threads each: http://ic.tweakimg.net/ext/i/1214930816.png As you can see, with that benchmark, it was better to have 4 cores with 8 threads each, than 8 cores with 2 threads each. The T2-threads where much heavier duty than the HT-threads back then, but afaik Intel has improved its technology with this re-introduction of them quite a bit. So I wouldn't dismiss hyper threading for a read-mostly Postgresql workload too easily. Then again, keeping 32 cores busy, without them contending for every resource will already be quite hard. So adding 32 additional "threads" may indeed make matters much worse. Best regards, Arjen