Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1a9qdz-0005wZ-Vj for pgsql-hackers@arkaria.postgresql.org; Fri, 18 Dec 2015 08:44:08 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84) (envelope-from ) id 1a9qdz-0005pA-Aj for pgsql-hackers@arkaria.postgresql.org; Fri, 18 Dec 2015 08:44:07 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84) (envelope-from ) id 1a9qcf-0004Md-Mp for pgsql-hackers@postgresql.org; Fri, 18 Dec 2015 08:42:45 +0000 Received: from newmail.postgrespro.ru ([93.174.131.138] helo=mail.postgrespro.ru) by magus.postgresql.org with esmtp (Exim 4.84) (envelope-from ) id 1a9qcc-0001mK-Li for pgsql-hackers@postgresql.org; Fri, 18 Dec 2015 08:42:45 +0000 Received: from localhost (localhost [127.0.0.1]) by mail.postgrespro.ru (Postfix) with ESMTP id 09D5A21C5059; Fri, 18 Dec 2015 11:42:41 +0300 (MSK) Received: from mail.postgrespro.ru ([127.0.0.1]) by localhost (mail.postgrespro.ru [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id tcZ3hyUbjHWn; Fri, 18 Dec 2015 11:42:40 +0300 (MSK) Received: from fujitsu (unknown [192.168.27.1]) by mail.postgrespro.ru (Postfix) with ESMTPSA id 9FFED21C5049; Fri, 18 Dec 2015 11:42:40 +0300 (MSK) Date: Fri, 18 Dec 2015 11:40:58 +0300 From: Aleksander Alekseev To: Robert Haas Cc: Andres Freund , "pgsql-hackers@postgresql.org" Subject: Re: Patch: fix lock contention for HASHHDR.mutex Message-ID: <20151218114058.66dc4c90@fujitsu> In-Reply-To: <20151218081009.34ea4c04@fujitsu> References: <20151211170001.78ded9d7@fujitsu> <20151215122513.GC17724@alap3.anarazel.de> <20151217151418.GB2224@awork2.anarazel.de> <20151217190342.07e4533a@fujitsu> <20151218081009.34ea4c04@fujitsu> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Pg-Spam-Score: -1.9 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org > Oops, 3.5-4 _times_ more TPS, i.e. 2206 TPS vs 546 TPS. In fact these numbers are for similar but a little bit different benchmark (same schema without checks on child tables). Here are exact numbers for a benchmark described above. Before: $ pgbench -j 64 -c 64 -f pgbench.sql -T 30 my_database transaction type: Custom query scaling factor: 1 query mode: simple number of clients: 64 number of threads: 64 duration: 30 s number of transactions actually processed: 20433 latency average: 93.966 ms tps = 679.698439 (including connections establishing) tps = 680.353897 (excluding connections establishing) $ pgbench -j 64 -c 64 -f pgbench.sql -T 30 my_database transaction type: Custom query scaling factor: 1 query mode: simple number of clients: 64 number of threads: 64 duration: 30 s number of transactions actually processed: 19111 latency average: 100.466 ms tps = 635.763523 (including connections establishing) tps = 636.112682 (excluding connections establishing) $ pgbench -j 64 -c 64 -f pgbench.sql -T 30 my_database transaction type: Custom query scaling factor: 1 query mode: simple number of clients: 64 number of threads: 64 duration: 30 s number of transactions actually processed: 19218 latency average: 99.906 ms tps = 639.506848 (including connections establishing) tps = 639.838757 (excluding connections establishing) After: $ pgbench -j 64 -c 64 -f pgbench.sql -T 30 my_database transaction type: Custom query scaling factor: 1 query mode: simple number of clients: 64 number of threads: 64 duration: 30 s number of transactions actually processed: 95900 latency average: 20.021 ms tps = 3194.142762 (including connections establishing) tps = 3196.091843 (excluding connections establishing) $ pgbench -j 64 -c 64 -f pgbench.sql -T 30 my_database transaction type: Custom query scaling factor: 1 query mode: simple number of clients: 64 number of threads: 64 duration: 30 s number of transactions actually processed: 96837 latency average: 19.827 ms tps = 3225.822355 (including connections establishing) tps = 3227.762847 (excluding connections establishing) $ pgbench -j 64 -c 64 -f pgbench.sql -T 30 my_database transaction type: Custom query scaling factor: 1 query mode: simple number of clients: 64 number of threads: 64 duration: 30 s number of transactions actually processed: 96143 latency average: 19.970 ms tps = 3202.637126 (including connections establishing) tps = 3204.070466 (excluding connections establishing) Ratio: $ python min(3194.0, 3225.0, 3202.0) / max(679.0, 635.0, 639.0) 4.703976435935199 -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers