Domen Štangar (2010) Sparse (LR) table compression. EngD thesis.
This diploma thesis deals with algorithms for compressing sparse tables. Sparse table represents a table in which we have many items whose value is irrelevant, but it nevertheless take up space. The problem of sparse tables occurs in LR tables, tables of large dimensions and high order matrices in which we have high number of values 0. The LR table is used for syntactic analysis and can take up lot of memory, while the contents of the table is almost empty, so we need algorithms that compress those tables. At any execution or translation of a program we need access to the table. If these tables would not be compressed, we would need more memory just to check the syntax. In the first part of the paper we describe practical examples of sparse tables and we describe in detail the algorithms of each method. We describe methods like graph coloring, line elimination, row displacement and row column scheme. In second part we present the use of compressed LR tables and implement a syntactic analyzer using LR tables generated by the Bison. We also implement a patent which is also published in compressing LR table. In the annexes you can find the source code for all methods that we have discussed in this paper and the implementation of the syntactical analyzer.
Actions (login required)