Compression of Partially Ordered Strings
We introduce the problem of compressing partially ordered strings: given string σεΣ* and a binary independence relation I over Σ, how can we compactly represent an input if the decompressor is allowed to reconstruct any string that can be obtained from σ by repeatedly swapping adjacent independent symbols? Such partially ordered strings are also known as Mazurkiewicz traces, and naturally model executions of concurrent programs. Compression techniques have been applied with much success to sequential program traces not only to store them compactly but to discover important profiling patterns within them. For compression to achieve similar aims for concurrent program traces we should exploit the extra freedom provided by the independence relation.
Many popular string compression schemes are grammar-based schemes that produce a small context-free grammar generating uniquely the given string. We consider three classes of strategies for compression of partially-ordered strings: (i) we adapt grammar-based schemes by rewriting the input string σ into an “equivalent” one before applying grammar-based string compression, (ii) we represent the input by a collection of projections before applying (i) to each projection, and (iii) we combine (i) and (ii) with relabeling of symbols. We present some natural algorithms for each of these strategies, and present some experimental evidence that the extra freedom does enable extra compression. We also prove that a strategy of projecting the string onto each pair of dependent symbols can indeed lead to exponentially more succinct representations compared with only rewriting, and is within a factor of |Σ|2 of the optimal strategy for combining projections with rewriting.
KeywordsPartial Order Compression Algorithm Concurrent Program Input String Graph Grammar
Unable to display preview. Download preview PDF.
- [BJR97]Booch, G., Jacobson, I., Rumbaugh, J.: Unified Modeling Language User Guide. Addison Wesley, Reading (1997)Google Scholar
- [BL00]Ball, T., Larus, J.: Using paths to measure, explain, and enhance program behavior. IEEE Computer 33(7), 57–65 (2000)Google Scholar
- [CLL+02]Charikar, M., Lehman, E., Liu, D., Panigrahy, R., Prabhakaran, M., Rasala, A., Sahai, A., Shelat, A.: Approximating the smallest grammar: Kolmogorov complexity in natural models. In: Proceedings of the 34th ACM Symposium on Theory of Computing, pp. 792–801 (2002)Google Scholar
- [DM97]Diekert, V., Metivier, Y.: Partial commutation and traces. In: Handbook of Formal Languages: Beyond Words, pp. 457–534. Springer, Heidelberg (1997)Google Scholar
- [Eng97]Engelfriet, J.: Context-free graph grammars. In: Rozenberg, G., Salomaa, A. (eds.) Handbook of Formal Languages, vol. 3. Springer, Heidelberg (1997)Google Scholar
- [GRM03]Goel, A., Roychoudhury, A., Mitra, T.: Compactly representing parallel program executions. In: Proceedings of the ACM Symposium on Principles and Practice of Parallel Programming (2003)Google Scholar
- [Lar99]Larus, J.: Whole program paths. In: Proceedings of the ACM Conference on Programming Languages Design and Implementation, pp. 259–269 (1999)Google Scholar
- [LS02]Lehman, E., Shelat, A.: Approximation algorithms for grammar-based compression. In: Proceedings of the 13th ACM-SIAM Symposium on Discrete Algorithms, pp. 205–212 (2002)Google Scholar
- [Maz87]Mazurkiewicz, A.: Trace theory. In: Brauer, W., Reisig, W., Rozenberg, G. (eds.) APN 1986. LNCS, vol. 255, pp. 279–324. Springer, Heidelberg (1987)Google Scholar
- [Pra86]Pratt, V.R.: Modeling concurrency with partial orders. International Journal of Parallel Programming 15(1) (1986)Google Scholar
- [Sav03a]Savari, S.: Concurrent processes and interchange entropy. In: IEEE Int. Symp. on Information Theory (2003) (to appear)Google Scholar
- [Sav03b]Savari, S.: On compressing interchange classes of events in a concurrent system. In: IEEE Data Compression Conference (2003)Google Scholar