280 likes | 412 Views
Parallel Recursive State Compression for Free. Alfons Laarman Joint work with : Michael Weber Jaco Van de Pol 12/7/2011. SPIN 2011. Motivation Previous work Problem Description Background Tree Compression Contribution Concurrent Tree Compression
E N D
Parallel Recursive State Compression for Free Alfons Laarman Joint workwith: Michael Weber Jaco Van de Pol 12/7/2011 SPIN 2011
Motivation • Previous work • Problem Description Background • Tree Compression Contribution • Concurrent Tree Compression • An Incremental Algorithm Analysis of Compression Ratios Experiments Conclusion / Future Work Overview Parallel Recursive State Compression for Free
(Enumerative) reachability as a basis for many verification problems S: open set (stack or queue) DB: closed set Motivation Previous work Parallel Recursive State Compression for Free
Previous work Motivation Worker 1 Worker 2 S2: post() S1: DB Synchronous Random Polling Lockless hash table request Worker 4 Worker 3 S4: S3: [FMCAD 2010] Parallel Recursive State Compression for Free
Properties of the Lockless hash table Motivation Monotonically growing (no remove()operation) find_or_put(vector) : boolean Without resizing Avoid scalability problem Stable indices: find_or_put(vector) : (index, boolean) Fixed-sized integer vectors (limitation of LTSmin) Parallel Recursive State Compression for Free
Memory becomes the problem (again) Motivation The hash set has to store up to 10^9 state vectors of length up to 1 kbyte With 16 cores: 1GB/sec of new state vectors In asynchronous systems, transitions are typically local: States are very similar Solution: Compress the DB Cf. collapse in spin Exploit locality with incremental algorithms ++++++------+------ ---++-------+------ ------------+-+---- ++++++------+------ ---------------++-- +++------------++-- ---------------++-- ------+--------++-- ---------+-----++-- ------------+--++-- ---------------+-+- ------+--------+-++ ---------+-----+-++ ------------+--+-++ ---+-----------+-+- Parallel Recursive State Compression for Free
Motivation • Previous work • Problem Description Background • Tree Compression Contribution • Concurrent Tree Compression • An Incremental Algorithm Analysis of Compression Ratios Experiments Conclusion / Future Work Overview Parallel Recursive State Compression for Free
Memory-Efficient storage Background Parallel Recursive State Compression for Free
Tree Compression Background Store a table of vectors as a fixed-shaped tree of tables with tuples Parallel Recursive State Compression for Free
Tree Compression Background Parallel Recursive State Compression for Free
Tree Compression algorithm Background Used before in distributed model checking – Blom et al. returns (index, bool) Parallel Recursive State Compression for Free
Conflicting requirements Problem Description • Goal: scalable concurrent tree database • Unknown table sizes requires resizing breaks stable indices Parallel Recursive State Compression for Free
Motivation • Previous work • Problem Description Background • Tree Compression Contribution • Concurrent Tree Compression • An Incremental Algorithm Analysis of Compression Ratios Experiments Conclusion / Future Work Overview Parallel Recursive State Compression for Free
Introduce Maximal sharing Concurrent Tree compression • Idea: Merge all hash tables into a single non-resizing hash table. T6(3,5,5,4,1,3) = 7 T3(4,1,3) = 4 T2(4,1) = 1 • This maintains an injection Tk : Natk Nat Parallel Recursive State Compression for Free
Introduce Maximal sharing Concurrent Tree compression • Idea: Merge all hash tables into a single non-resizing hash table. Problem: T6 (….) = T2 (3,5) Parallel Recursive State Compression for Free
Introduce Maximal sharing Concurrent Tree compression Solution: add an isRoottag to nodes For correct booleanresult Parallel Recursive State Compression for Free
The Algorithm Concurrent Tree Compression Parallel Recursive State Compression for Free
Incremental tree insertion Concurrent Tree compression Next problem: • Hash table vs Tree • 1 (random) memory access of k integers (k-1) (random) accesses of two integers Parallel Recursive State Compression for Free
Incremental tree insertion Concurrent Tree compression Exploits locality (log2(k) accesses in many cases) post( ) = Parallel Recursive State Compression for Free
Motivation • Previous work • Problem Description Background • Tree Compression Contribution • Concurrent Tree Compression • An Incremental Algorithm Analysis of Compression Ratios Experiments Conclusion / Future Work Overview Parallel Recursive State Compression for Free
Worst and best case inputs Analysis of compression ratios Tuples in tree nodes Ratio Inputs Best case: n k Worst case: Parallel Recursive State Compression for Free
Memory usage Experiments [BEEM database] Parallel Recursive State Compression for Free
Memory usage Experiments Always compression with tree In most cases, compression is close to optimal (see median) Always higher ratios than COLLAPSE Parallel Recursive State Compression for Free
Runtimes Compared to Hash table Experiments Performance close to HT Due to incremental algorithm Parallel Recursive State Compression for Free
Scalability experiments (aggregate speedups) Experiments Parallel Recursive State Compression for Free
With paying careful attention to data layout, we designed a parallel on-the-fly compression method, that features: Impressive compression ratios Good performance/scalability For the full BEEM benchmark database Conclusion Parallel Recursive State Compression for Free
Future work • Support dynamic-sized vectors • Overcome hardware limitations (2 billion vectors due to CAS) • use compact hash table (Cleary) • Static reordering of vector slots to improve compression ratios • Also Multi-Core LTL Model Checking (ATVA 2011 / PDMC 14:00) • Implemented inLTSmin (open source): http://fmt.cs.utwente.nl/tools/ltsmin/ Parallel Recursive State Compression for Free
An intuition Analysis of compression ratios Parallel Recursive State Compression for Free