International Journal of Advanced Science and Technology Vol. 29, No. 5, (2020), pp. 9503-9510

An Optimized VLSI Based High Performance Architecture for Lossless

1*R.Umamaheswaran, 2**S.R.Santhosh kumaran, 3R.Parameshwaran, 4G. Lakshminarayanan, 5S.Thiruppathirajan, 6R. Manikandan 1Scientific Secretary, ISRO, Bengaluru, India. Mail Id: [email protected], 9496040095 2,3,4Department of ECE, National Institute of Technology-Tiruchirappalli, India Mail Id: [email protected] , 9487679810, [email protected], 8056303057 [email protected], 9486001109 5Avionics Entity, VSSC, Department of Space, Thiruvananthapuram, India Mail Id: [email protected], 9446101839 6School of Computing, SASTRA Deemed University, India [email protected], 8667872608

Abstract

Data compression is method of encoding rules, which allows substantial reduction in total number of bits to transmit or store file. To archive or transmit binary files or text, lossless data compression is utilized, which is need to keep data intact at any time. LZRW1 (Lempel Ziv Ross Williams) and LZW (Lempel Ziv Welch) was mainly used for lossless data Compression. But LZW takes more time to Compress and decompress data. LZRW refers to variants of LZ77 lossless data compression techniques with emphasis on increasing compression speed by use of hash tables and other methods. In order to provide high throughput of data, a hash table is implemented by replacing the dictionary in LZW. This method has worst case running time. It adapts quickly and neglects initialisation in making it fast as well as powerful for small blocks of data and large ones. The speed of compression has been increased by four times that of LZW.The compression ratio obtained also be relatively same as that of LZW.The proposed was implemented in system verilog, simulated by using Questa sim tool and synthesised in Xilinx Vivado. KEYWORDS: Data compression, Dictionary-Based, Decompression, Embedded Real time System, Fixed length encoding, Hash Table, Telemetry system, Throughput.

1. Introduction “To store or transmit file, data compression is method of encoding rules, which allows substantial reduction in total number of bits. At present in various areas, two basic classes of data compression are used. One is lossy data compression that is used widely to compress image files for archives are communication purposes. Another is lossless data compression, which is used commonly to archive or transmit text or binary files need to keep data intact at anytime. Storage and data transmission cost money. More costs for more data dealt with. Most digital data not stored in compact form. They stored in way which easy to use. Binary code is executed in computer, individual samples from data acquisition system, ASCII text from word processors, etc [2]. Easy to use encoding methods need data files, which is twice as actually needed to represent data. In general term to address data compression for different techniques and programs are produced [1-2]. To convert data from easy to use to

ISSN: 2005-4238 IJAST 9503 Copyright ⓒ 2020 SERSC

International Journal of Advanced Science and Technology Vol. 29, No. 5, (2020), pp. 9503-9510 optimized format for compactness, compression program is used. Similarly, uncompress ion program returns data to original form”. Lossless method mostly include Lempel and Ziv codes, most of implementation of LZ technique depends on systolic arrays, or its variant that combines systolic array by plants for information broad cast as well as reduction[1]. A popular version of LZ technique is known as word based LZ technique, which is dictionary method[12]. In this method text elements would only send index to dictionary. It needs Quite lot of time to adjust dictionary. To improve this, an algorithm which is completely based on high throughput, which is LZRW1 [6].An algorithm which is mainly focused on high throughput and data rate is proposed which increases the transmission data per second. This algorithm is better for applications where continuous transmission of data is required. In Two-stage architecture, it will provide a better scope by giving high compression and throughput. The algorithm, which we proposed, is LZRW1, which replaces LZW dictionaries with hash table. This algorithm uses a hash table using which we can attain a high throughput and high compression as that of LZW [6].Using this in telemetry system will be more advantageous. A telemetry system is utilized to calculate performance of aircraft and diagnose failures by detecting aircraft responses [7]. Highly powerful data channel transmission is required and high real time testing, which may be helped by this method.

2. Lzrw Architecture Extremely fast local adaptive technique of LZ77 class is proposed. Technique known as LZEW1 haves size of 16k memory text files. This technique runs in speed of 77k and 250k bytes/sec. It has worst case running time [2]. For small blocks of data and large one, it adapts quickly and negligible initiation overhead which makes efficient and fast. With tight throughput need these techniques are not fast enough for embedded real time systems. Generally these techniques are fast. Systems time is significant in designers and constraints of second space. Figure 1 shows LZRW1 technique with new structure, which gives better output. To process each byte, this technique has few instructions but gives useful compression. It uses copy/single pass literal mechanism. At every step few bytes of input are transferred either directly as pointer or string to already transmitted text.

Fig 1 optimized LZRW Architecture

ISSN: 2005-4238 IJAST 9504 Copyright ⓒ 2020 SERSC

International Journal of Advanced Science and Technology Vol. 29, No. 5, (2020), pp. 9503-9510

Below example shows how certain message is divided into literal items and copy items. Less length, uncompressed copy item has 3 bytes. By representing message using copy items, compression is obtained, but by resorting to literal items three or more bytes not found. For example:

Fig 2 content model

LZ77 class are achieved by converting text into sequence of item. Each is either copy or literal item. Literal items contain text they represent. Copy items contain pointer and offset which points to substring already transmitted text. Literal item has single byte, which coded directly. In most recent 4095 bytes of history, copy item contains 2 bytes which specify offset [1, 4095] and length [3,16] of string appear. To preserve byte alignment, control bits shows items of copy or literal and these are clustered to groups of 16. Compression Algorithm: The algorithms data structure, which forms its source model, consists of a few scalar variables, input block, hash table of 4096 pointers [5].Fig 2 and Fig 3 represents the corresponding optimized algorithm flow for the architecture.

Input Hash tbl pointer byte addr A w 3EA 1

wa 939 2

wal 451 3

alr A53 4

lru 893 5 … … …

Table 1 parameters Algorithm

“The hash table maps any three-byte key to a single pointer which can point anywhere in the memory but is likely to point to matching key. The hash table is used to try to find a

ISSN: 2005-4238 IJAST 9505 Copyright ⓒ 2020 SERSC

International Journal of Advanced Science and Technology Vol. 29, No. 5, (2020), pp. 9503-9510 match in the table for first three bytes or more of ziv bytes (next 16 bytes are coded) with a match resulting in copy item generation”. LZRW1 updates the hash table after each byte as shown in Table 1. Compression Algorithm

1. Input first 16 bytes of string 2. if length of string >2 Copy the string to hast table 3. Store the pointing address in table of pointer. 4. if the string is redundant , The string will be compared 5. An offset value will be created 6. This offset value is passed to table of pointer 7. The value will be stored. 8. An equivalent compressed value will be obtained. 9. When string reaches end, the compression will be done 10. Compressed data will be printed. Fig 3 Compression Algorithm

Decompression Algorithm: It accepts one compressed piece of data at a time, data in valid accepts the compressed input and outputs one byte of data. Data in valid is high when the control word is high, the decompressor will go into the DECOMPRESS state. In this state, the decompressor will use the high 4 bits of the data in input to determine the length of the compressed data and the low 12 bits to get the offset. It has a 4095 Bytes offset range. It outputs a distinct byte of data on decompressed byte for each out valid cycle is 1'b1, and then returns to the IDLE state after it's done, where it can accept new data. If the above conditions are met except that control word in is 1'b0, the decompressor must simply pass through the byte when writing down the relevant space in its history memory. The detailed block diagram has been given in Fig 4, which gives the proper image of I/O ports.

Decompression Algorithm

1. Initialization 2. while controlword is high Data_in is high, decompress state 3. Out of 16 bits, first 4 bit will identify length of compress data 4. low 12 bits to get offset 5. when control word high, The compressed data in the history buffer Will be decompressed. 6. Print the decompressed result 7. repeat from step 2, until out valid is high 8. Print the complete decompressed result

ISSN: 2005-4238 IJAST 9506 Copyright ⓒ 2020 SERSC

International Journal of Advanced Science and Technology Vol. 29, No. 5, (2020), pp. 9503-9510

9. Stop

Fig 4 Decompression Algorithm

Out valid is set to go high for one cycle to allow the byte to pass. It will go back to the IDLE status after that one clock cycle.

Fig 5 Decompression Block diagram

All procedures are repeated, this part contain sufficient detail. If several methods are described, it is divided into subsections.

3. Results And Discussion In this, standard Corpus file was utilized for test [14]. Compression table gives results in kilobytes, while the speed table gives Data rate in K/sec.From the compression results we can see that, the compression is bad for text files, but it is better for objective machine code files and relatively better for program files. The speed comparison (Table 2) for RW1 gives a 4 times better compress and decompress data rate than LZW. Therefore, we get a higher data rate by using this algorithm. Even though there is small compression loss for program files (Table 3), we can get a higher data rate, which consider RW1 as better than LZW.

ISSN: 2005-4238 IJAST 9507 Copyright ⓒ 2020 SERSC

International Journal of Advanced Science and Technology Vol. 29, No. 5, (2020), pp. 9503-9510

File LZW Kb/sec LZRW Kb/sec Compress Decomp Compress Decomp Bib 58 94 213 388

Book1 46 90 186 368 Book2 49 92 215 375 Geo 48 74 167 313 News 44 87 210 392 Obj1 53 75 191 420

Obj2 41 86 225 423 Paper1 58 91 226 371 Paper2 65 94 206 382

progc 55 90 242 387 Progl 65 103 241 412 Progp 63 98 241 344 trans 61 96 241 436

Table 2 Speed results of LZW and LZRW

Original LZW LZRW1 File Kbytes Compressed compressed Kbytes Kbytes Bib 109 46 54 Book1 751 324 398 Book2 597 245 307 Geo 100 76 80 News 368 178 210 Obj1 21 14 12 Obj2 241 125 122 Paper1 52 24 25 Paper2 80 35 37 progc 39 19 21 Progl 70 26 27 Progp 48 19 20 trans 91 37 37

Table 3 Compression results of LZW and LZRW for .

Fig 6 Compression result for 1kb input

ISSN: 2005-4238 IJAST 9508 Copyright ⓒ 2020 SERSC

International Journal of Advanced Science and Technology Vol. 29, No. 5, (2020), pp. 9503-9510

Fig 7 Decompression simulation waveform output

Fig 8 Implementation of LZRW on Xilinx ISE

Different test results for different data set are shown in Table 2, 3. Here the simulation result for compression (Fig.5) and decompression (Fig.6) 1kb input has shown below in Fig.5,6. Synthesizable Implementation is shown in Fig.7. Abbreviations: LZW, Lempel Ziv Welch; LZRW, Lempel Ziv Ross Williams; FPGA, Field programmable Gate Array; AH, Adaptive Huffman algorithm; AHDB, Adaptive Huffman technique with Dynamic Block exchange.

4. Conclusion In this work, an algorithm of LZ77 family named LZRW1 for Lossless Data Compression which works based on Hash table is implemented. This algorithm has given a high data throughput and better speed compared to LZW.This algorithm work best in places where priority is given for high data rate transmission. We can get higher compression for machine code and program files which are mainly used in launch vehicles makes this algorithm a better consideration. Applications which requires high data rate transmission like, launch

ISSN: 2005-4238 IJAST 9509 Copyright ⓒ 2020 SERSC

International Journal of Advanced Science and Technology Vol. 29, No. 5, (2020), pp. 9503-9510

vehicles, telemetry system, and app packages etc. can have better results by using this algorithm.

5. Future Scope In this we propose 2 phase architecture using this algorithm which may provide a better compression. FPGA implementation of this algorithm has to be done to verify its implementation level performance analysis. Acknowledgements

“The authors thank DST-FIST for funding lab facility for this research under Grant number DST/ETI-324/2012.”

Conflict of Interest: Nil References [1] Safieh, M., & Freudenberger, J. (2019). Efficient VLSI architecture for the parallel dictionary LZW data compression algorithm. IET Circuits, Devices & Systems, 13(5), 576-583. doi: 10.1049/iet- cds.2018.5017. [2] Ming-Bo Lin, Jang-Feng Lee, & Jan, G. (2006). A Lossless Data Compression and Decompression Algorithm and Its Hardware Architecture. IEEE Transactions On Very Large Scale Integration (VLSI) Systems, 14(9), 925-936. doi: 10.1109/tvlsi.2006.884045. [3] Ranganathan, N., & Henriques, S. (1993). High-speed VLSI designs for Lempel-Ziv-based data compression. IEEE Transactions On Circuits And Systems II: Analog And Digital Signal Processing, 40(2), 96-106. doi: 10.1109/82.219839. [4] Santos, L., Gomez, A., & Sarmiento, R. (2019). Implementation of CCSDS Standards for Lossless Multispectral and Hyperspectral Satellite . IEEE Transactions on Aerospace and Electronic Systems, 1-1. doi: 10.1109/taes.2019.2929971. [5] Zhai, X., & Vladimirova, T. (2016). Efficient Data-Processing Algorithms for Wireless-Sensor- Networks-Based Planetary Exploration. Journal of Aerospace Information Systems, 13(1), 46-66. doi: 10.2514/1.i010373. [6] Avramenko, S., Sonza Reorda, M., Violante, M., & Fey, G. (2017). A High-Level Approach to Analyze the Effects of Soft Errors on Algorithms. Journal Of Electronic Testing, 33(1), 53-64. doi: 10.1007/s10836-016-5637-6. [7] Avramenko, S., Sonza Reorda, M., Violante, M., & Fey, G. (2017). A High-Level Approach to Analyze the Effects of Soft Errors on Lossless Compression Algorithms. Journal Of Electronic Testing, 33(1), 53-64. doi: 10.1007/s10836-016-5637-6. [8] Gonzalez, R., Woods, R., & Masters, B. (2009). Digital Image Processing, Third Edition. Journal Of Biomedical Optics, 14(2), 029901. doi: 10.1117/1.3115362. [9] Hanho Lee. (2003). High-speed VLSI architecture for parallel Reed-Solomon decoder. IEEE Transactions On Very Large Scale Integration (VLSI) Systems, 11(2), 288-294. doi: 10.1109/tvlsi.2003.810782. [10] Zhang, Y., & Zheng, S. (2000). An Efficient Parallel VLSI Sorting Architecture. VLSI Design, 11(2), 137-147. doi: 10.1155/2000/14617. [11] Ziv, J., & Lempel, A. (1977). A universal algorithm for sequential data compression. IEEE Transactions On , 23(3), 337-343. doi: 10.1109/tit.1977.1055714. [12] Bell, T.C., Cleary, J.G., and Witten, I.H. 1990. Text Compression, Prentice Hall, Englewood Cliffs, NJ. [13] Cormen.T.H.,Leiserson.C.E.,Rivest.R.L., and Stein.C.,(2001).Introduction to Algorithms, 2nd ed.,Boston MIT Press and New York: McGraw-Hill.

ISSN: 2005-4238 IJAST 9510 Copyright ⓒ 2020 SERSC