Computer Engineering and Applications ›› 2008, Vol. 44 ›› Issue (3): 108-109.
• 学术探讨 • Previous Articles Next Articles
LIAO Ming-xue,FAN Zhi-hua
Received:
Revised:
Online:
Published:
Contact:
廖名学,范植华
通讯作者:
Abstract: The method of implementing Java Hashtable is analyzed and a model of data that can seriously worsen the performance of the Hashtable is given.A method based on prime number sequence is presented to nearly completely avoid this performance deterioration under such model.Both experiments and theory proof show that the new method not only reduces the number of hash conflicts by nearly 100% than the old one in JDK for presented data model but also can improve performance of Java Hashtable for ordinary data.
Key words: Java, Hashtable, prime number
摘要: 分析了Java哈希表的实现特点并给出了导致其性能恶化的一种数据模式。针对这种数据模式的特点,提出了基于素数序列的哈希表优化方法,从而几乎完全避免了该模式下哈希表的性能恶化。实验与理论结果表明: 对提出的模式数据,优化方法产生的Hash碰撞比JDK中的方法下降接近100%,而且对随机数据下的Java哈希表性能也有改善。
关键词: Java, 哈希表, 素数
LIAO Ming-xue,FAN Zhi-hua. Prime number sequence based performance improvement in Java Hashtable[J]. Computer Engineering and Applications, 2008, 44(3): 108-109.
廖名学,范植华. 基于素数序列的Java哈希表性能优化[J]. 计算机工程与应用, 2008, 44(3): 108-109.
0 / Recommend
Add to citation manager EndNote|Ris|BibTeX
URL: http://cea.ceaj.org/EN/
http://cea.ceaj.org/EN/Y2008/V44/I3/108