author : chia-hung lin, chia-yin hsu, and sun-yuan hsieh publisher : ieee transactions on parallel...
TRANSCRIPT
![Page 1: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/1.jpg)
A MULTI-INDEX HYBRID TRIE FOR IP LOOKUP ANDUPDATESAuthor : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh
Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS
![Page 2: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/2.jpg)
To reduce the time required by router table operations, this study developed a novel data structure, the multi-index hybrid trie (MIHT), which combines the best features of the B +tree and priority trie to design dynamic router tables. The proposed data structure preserves the advantages of the B + tree and the trie-based data structure and avoids the mentioned shortcomings.
![Page 3: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/3.jpg)
基本架構
![Page 4: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/4.jpg)
主要架構以 B+ tree 為主 在配上 priority tries
下面是這邊用到的 B+ tree 的特性 Each node has at most m children. Each node, except the root, has at least m/2 children. The root has at least 2 children. All leaves occur on the same level. For a B + tree, stores all the satellite information in the leaves and stores only
keys and child pointers in the internal nodes.
這邊的 key 寄上一頁的
![Page 5: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/5.jpg)
PRIORITY TRIES
在他的架構裡面長度不到 k的prefix都放在另外的 priority trie : PT[-1]
![Page 6: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/6.jpg)
MULTI-INDEX HYBRID TRIES(MIHT) 一個 (k,m)MIHT 表示 key 值為 k 且其 b+ tree order 為 m
分為三種 node : root, i-node(index node), d-node(data node)
![Page 7: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/7.jpg)
ROOT The root is a pointer array with a size of two, root[0] points to the root of
PT[−1] and root[1] points to the root of Tb.
![Page 8: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/8.jpg)
I-NODE 又分為兩種 : internal i-node 與 external i-node
包含以下欄位 Leaf(u) : indicating whether u is a leaf. For the internal i-node u, leaf(u) is set as
FALSE. t(u): 裡面有幾個 index t(u) 個 index :I1 (u), I2 (u), . . . , It(u) (u) t(u)+ 個 child-pointers
![Page 9: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/9.jpg)
N-NODE Each d-node w had the following fields:
priority(w) recorded the boolean value, indicating whether w is a priority node. s(w) is the suffix stored in w. 所以如果有 match output port 就是找
prefix Ii (v) · s(w). left(w) right(w)
![Page 10: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/10.jpg)
![Page 11: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/11.jpg)
CONSTRUCTION
![Page 12: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/12.jpg)
INSERT
![Page 13: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/13.jpg)
![Page 14: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/14.jpg)
![Page 15: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/15.jpg)
SEARCH
![Page 16: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/16.jpg)
DELETION 若 len < k 去 PT[-1] delete 掉 若 len=>k 則 trace 到 d-node 中的該 prefix delete 掉他
若 delete 後 該 priority trie 不為空 , 做 priority trie 的調整 若為空 delete 掉 external i-node 的對應 index 與 pointer 並依照 b+ tree 的條件去做調
整
![Page 17: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/17.jpg)
![Page 18: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/18.jpg)
![Page 19: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/19.jpg)
PARTITIONING THE MULTI-INDEX HYBRIDTRIE 對 prefix 先取 a bit 依照這個 key 分成多個 MIHT
注意 a 值不可小魚最短的 prefix lenth 否則會有 duplicate
For example, assuming that p =101000* and α = 8 (the first eight bits of a prefix represent the index value), because 101000* contains (10100000) 2 = 160, (10100001) 2 = 161, (10100010) 2 = 162, and (10100011) 2 = 163, p must be inserted into the (k, m)-MIHTs, as indicated by P[160], P[161], P[162], and P[163]
![Page 20: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/20.jpg)
The experiments were performed using C language for four benchmark IPv4 and two benchmark IPv6 prefix databases obtained from [1],
. The codes were run on a 3.40GHz Pentium 4 PC that had 1.99GB of memory.
![Page 21: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/21.jpg)
![Page 22: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/22.jpg)
![Page 23: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/23.jpg)
![Page 24: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/24.jpg)
![Page 25: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/25.jpg)
![Page 26: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/26.jpg)
![Page 27: Author : Chia-Hung Lin, Chia-Yin Hsu, and Sun-Yuan Hsieh Publisher : IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS](https://reader036.vdocuments.net/reader036/viewer/2022062515/56649c745503460f94927366/html5/thumbnails/27.jpg)