Return-Path: Delivered-To: apmail-db-derby-dev-archive@www.apache.org Received: (qmail 55501 invoked from network); 17 Dec 2007 10:37:04 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 17 Dec 2007 10:37:04 -0000 Received: (qmail 266 invoked by uid 500); 17 Dec 2007 10:36:53 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 237 invoked by uid 500); 17 Dec 2007 10:36:53 -0000 Mailing-List: contact derby-dev-help@db.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: Delivered-To: mailing list derby-dev@db.apache.org Received: (qmail 228 invoked by uid 99); 17 Dec 2007 10:36:53 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 17 Dec 2007 02:36:53 -0800 X-ASF-Spam-Status: No, hits=-100.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 17 Dec 2007 10:36:39 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 103A9714246 for ; Mon, 17 Dec 2007 02:36:43 -0800 (PST) Message-ID: <9954480.1197887803038.JavaMail.jira@brutus> Date: Mon, 17 Dec 2007 02:36:43 -0800 (PST) From: "Knut Anders Hatlen (JIRA)" To: derby-dev@db.apache.org Subject: [jira] Resolved: (DERBY-3280) Poor distribution of hash values from RecordId.hashCode() In-Reply-To: <17246427.1197743983117.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/DERBY-3280?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Knut Anders Hatlen resolved DERBY-3280. --------------------------------------- Resolution: Fixed Fix Version/s: 10.4.0.0 Derby Info: (was: [Patch Available]) Committed revision 604818. > Poor distribution of hash values from RecordId.hashCode() > --------------------------------------------------------- > > Key: DERBY-3280 > URL: https://issues.apache.org/jira/browse/DERBY-3280 > Project: Derby > Issue Type: Improvement > Components: Performance, Services, Store > Affects Versions: 10.4.0.0 > Reporter: Knut Anders Hatlen > Assignee: Knut Anders Hatlen > Fix For: 10.4.0.0 > > Attachments: d3280.diff, TestClient.java > > > The hash values returned by RecordId.hashCode() are constructed by performing bitwise xor on the 32 least significant bits of the record number, the page number, the container id and the segment id. Since all of these values tend to be relatively small positive integers, the hash values also tend to be clustered in a very small range. This leads to a higher frequency of hash collisions in the lock table, which makes the hash tables work less efficiently and thereby reduces the performance. > As an example, the simple join load in the test client attached to DERBY-1961 uses two tables, TENKTUP and ONEKTUP, with 10000 rows and 1000 rows, respectively. The RecordIds for these 11000 rows map to less than 900 distinct hash codes. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.