Bitstream compression

I'm studying the idea of compressing a Virtex 2 bitstream for storage in non-Xilinx FLASH as well as microprocessor-based FPGA loading. I wonder if anyone knows of statistics on what compression ratios can be attained for designs of various degrees of complexity. The design I am looking at will compress to about 100K from 500K (using WinZIP as a benchmarking tool). Utilization is moderate and it does not have lots of ROM initializations in the bitstream.

Thanks,

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Martin Euredjian eCinema Systems, Inc.

To send private email: x@y where x = "martineu" y = "pacbell.net"

Reply to
Martin
Loading thread data ...

I see you are following my lead:

formatting link

My latest baby: XC2VP50, about half FFs (& 2/3 slices) used.

gzip -9 reduces the file size from 2.322M to 498k. I think that amount of compression is typical for most designs. I haven't seen anything much worse than that.

I recommend avoiding Windows compression utilities (such as WinZip) because sometimes the decompression will need to take place on a small microcontroller. Something like gzip has the added benefit of being open source.

Regards, Allan

Reply to
allanherriman

Agreed. I just started looking into this and using WinZIP is a lazy first step to get a sense of proportion. My gut feeling is that it would be perfectly safe to allocate space equivalent to 50% of the uncompressed bitstream. If less is used, fine. The problem I have is that the design is likely to change after the product is released...so, I can't nail down the configuration file at this stage of the game.

I'm tempted to start with RLE. It would be easy to implement a decompressor with a small uC and limited register/ram resources.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Martin Euredjian eCinema Systems, Inc.

To send private email: x@y where x = "martineu" y = "pacbell.net"

Reply to
Martin

Did bitstream compression in my last project. Used LZW. RLE didn't improve so much vs. "internal" xilinx compression.

For many reasons we had to reconfigure FPGA very quickly; with some care to code, was blazingly fast.

Here are some compression ratios on that design: CAMERA_COMP.BIN 97944 uncompressed

After LZW compression:

BIT SIZE

10 73475 11 65442 12 62865 13 58795 14 57687

Google Groups around with "compressing Xilinx bitstreams some test data"

or retrieve the thread clicking here:

formatting link

Reply to
Antonio Pasini

Thank you for the various links and recommendations on this subject.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Martin Euredjian eCinema Systems, Inc.

To send private email: x@y where x = "martineu" y = "pacbell.net"

Reply to
Martin

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.