ASortedListDataStructurefor32BitKeys.ppt_第1页
ASortedListDataStructurefor32BitKeys.ppt_第2页
ASortedListDataStructurefor32BitKeys.ppt_第3页
ASortedListDataStructurefor32BitKeys.ppt_第4页
ASortedListDataStructurefor32BitKeys.ppt_第5页
已阅读5页,还剩9页未读 继续免费阅读

下载本文档

版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领

文档简介

1、Engineering a Sorted List Data Structure for 32 Bit Keys,Roman Dementiev Lutz Kettner Jens Mehnert Peter Sanders MPI fr Informatik, Saarbrcken,R. Dementiev et al.: A Sorted List Data Structure for 32 Bit Keys (ALENEX04),Introduction,The power of integer keys helps in Sorting (radix MSB,LSB) Priority

2、 queues (radix heaps) Static search trees Dictionaries (hash tables) Faster both in theory and practice What about dynamic search data structures?,R. Dementiev et al.: A Sorted List Data Structure for 32 Bit Keys (ALENEX04),Motivation,van Emde Boas (vEB) search trees van Emde Boas77,MehlhornNaeher90

3、: Small K, large n vEB are faster ? NO, their direct implementations are 2-8 times slower than comp. based trees Wenzel92,here Here: a tuned vEB data structure that outperforms comp. based implementations,n number of elements K bit width of keys c size of the output,R. Dementiev et al.: A Sorted Lis

4、t Data Structure for 32 Bit Keys (ALENEX04),Direct vEB Implementation,vEB tree maintains set Recursive definition: |M|=1 or K=1: store directly, otherwise let K = K/2: store minM,maxM, top: store (top recursion) boti: store (bottom recursion) use hash table,K bit vEB top,hash table,K bit vEB boti,R.

5、 Dementiev et al.: A Sorted List Data Structure for 32 Bit Keys (ALENEX04),Improvement 1,Replace top data structure with a bit pattern hierarchy,K bit vEB top,hash table,K bit vEB boti,R. Dementiev et al.: A Sorted List Data Structure for 32 Bit Keys (ALENEX04),Improvement 2,Break recursion when K=8

6、 3 levels max.,hash table,R. Dementiev et al.: A Sorted List Data Structure for 32 Bit Keys (ALENEX04),Improvement 3,Replace root hash table with an array,63,0,0,31,0,31,32,32,63,63,4095,65535,R. Dementiev et al.: A Sorted List Data Structure for 32 Bit Keys (ALENEX04),Range Query Support,Link eleme

7、nts,63,0,0,31,0,31,32,32,63,63,4095,Level 1 root Bits 31-16,Level 2 Bits 15-8,Level 2 Bits 15-8,Level 3 Bits 7-0,65535,R. Dementiev et al.: A Sorted List Data Structure for 32 Bit Keys (ALENEX04),Example: Locate Operation,return handle of Function locate(y:N):ElementHandle if y maxM then return / no

8、 larger element i := y16.31/ index into root table top if topi=null or ymaxMi then return minMtop.locate(i)/ look in the next L2 table if Mi=x then return x/ single element case j := y8.15/ key for L2 table at Mi if rij=null or y maxMij then return minMi,top(i).locate(j)/ look in the next L3 table i

9、f Mij=x then return x/ single element case return rijtopij.locate(y0.7)/ L3 table access At most 9 comparisons for any input sizes,R. Dementiev et al.: A Sorted List Data Structure for 32 Bit Keys (ALENEX04),Locate Performance,R. Dementiev et al.: A Sorted List Data Structure for 32 Bit Keys (ALENEX

10、04),Construction,R. Dementiev et al.: A Sorted List Data Structure for 32 Bit Keys (ALENEX04),Deletion,R. Dementiev et al.: A Sorted List Data Structure for 32 Bit Keys (ALENEX04),Hard Inputs,R. Dementiev et al.: A Sorted List Data Structure for 32 Bit Keys (ALENEX04),Conclusions and Future Work,Integer search trees can outperform comp. based search da

温馨提示

  • 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
  • 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
  • 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
  • 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
  • 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
  • 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
  • 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

评论

0/150

提交评论