07.08.06 - 12:31pm
I love organization, especially in regards to my hard drives. I also maintain a digital library of every program I need to quickly get my desktop operational in case I decide to destroy Windows over 10 times in a week. However I like having all these files easily accessible so I stashed them on my server, but since it would be a pain to remember 25 file names and extensions, I conveniently RAR all of them and then have a rar.exe installer, so I just have memorize two files. Now what I am getting at here is the importance of archiving programs and the space they can save. Lately I have heard reports of 7-Zip actually being better than my trusted favorite WinRAR so I decided to put these two to the test and see who came out on top.
Back in the day, WinZip was the dominate archiving and compression program available to Windows users. I myself was a big fan of compression programs as it made it easier for me to send files to friends while on a 56k modem. In those times I would rather download a file in a day and then spend 15 minutes decompressing a file rather than spend a week downloading the same file, so the file compression abilities were very crucial. In the late 90’s a new format was beginning to emerge and take the world by storm, WinRAR. It was faster, more efficient, just better in every sense compared to WinZip. The interface for WinRAR was also much better than WinZip and there were so many options that one could implement with WinRAR such as data encryption, compression factors, and compression formats. This has been the dominate compression program of the technology inclined for the last few years, but recently a new program named 7-Zip has hit the scene.
New Uses for Archiving
The torrent community has embraced archiving programs with open arms for good reason. Besides cutting down on the file size in general, it is much easier to manage torrents when you are downloading a single file or a split file in equal pieces. This second ability is crucial for torrents as it will permit you to download chunks of the file at a time while still giving you the benefit of file compression. Another common use for this file splitting is fitting very large files onto size limited mediums. It is possible to break up a 20 gigabyte file and store it on 30 CDs and then reassemble the file later when you need it. I personally have archived my entire data drive and then put it on DVDs when I perform risky overclocks on my desktop. Other uses for compression and archiving are always popping up, for example HTTP, the protocol that delivers web pages supports the gzip algorithm, helping websites cut down on bandwidth by compressing the data before sending it out.
I downloaded and installed both 7-Zip and WinRAR onto my OS hard drive and then defragmented the drive three times just to ensure that the compression programs had a clean drive to tear up. Once the drive was prepared, I created a new folder and loaded onto it the new Thunderbird.exe (6 megabytes), my Mint database (17 megabytes), the current NForce4 Drivers (36 megabytes), and a 720 megabyte MP4. My processor was an AMD Athlon64 running at 2.4 GHz with a gigabyte of ram operating in dual channel mode. The hard drive was a Seagate ATA100 drive with an 8 megabyte cache. Once all the files were in place, I loaded up WinRAR and RARed the first file, then switched to 7-Zip and 7-zipped the same file. Once all four files were compressed, I performed the same action with decompression, alternating between programs as I switched through the files. In both programs I set the compression quality to the highest setting so as to achieve the highest compression with no regard to processor utilization.
Text documents compress very well due to the large amount of whitespace within the documents. All those extraneous spaces and line breaks make for very large documents. To start the Mint Database was a whopping 17 megabytes of text. WinRAR cut the file down to 1006 Kilobytes while 7-Zip compressed the file to 908 kilobytes. WinRAR took 6 seconds and used 100% of the processor and 43MB of ram. 7-Zip took 8 seconds and used 100% of the processor however memory consumption skyrocketed up to around 160MB. Since 7-Zip and WinRAR use different algorithms I would wager that 7-Zips algorithm will consume as much memory as possible to quickly compress the files while WinRAR has a more conservative approach.
In general professional programs have been optimized so heavily that there is very little room for compression to improve upon. This became very obvious when I tried to compress the ThunderBird executable. WinRAR compressed the 6.02 megabyte file down to 6.01 megabytes in 3 seconds but 7-Zip actually increased the file size to 6.09 megabytes, also in 3 seconds. What happened was all the overhead code used in compression was larger than the amount of space saved with compression so the overhead code increased the file size. There is a minor amount of compression going on here but the overhead in both cases makes it nearly useless. I believe with most programs on the market you won’t be able to gain anything with compression. Once again WinRAR used just 43 megabytes of ram while 7-Zip used an excessive amount of ram, however it was a bit lower at around 120 megabytes.
Since the driver files were about 7 times larger than the executable I figured there would be enough compression available that there wouldn’t be a repeat of the previous example and this was indeed true. The drivers were 35.6 megabytes and WinRAR compressed them down to 35.1 megabytes in 27 seconds and 7-Zip compressed them down to 35.3 megabytes in 21 seconds. During this test I began to really notice 7-Zips voracious hunger for ram. In the 27 seconds it climbed quickly from under 100 megabytes to a peak of 728 megabytes. With only 40 megabytes remaining I think Windows simply stopped feeding the program to keep the system from stalling. WinRAR once again stayed at its custom 43 megabytes which I began to appreciate.
MP4 encoded with H.264
Typically MP4 files are heavily compressed when the stream is encoded which explains why it takes so long to encode files. This was definitely the case when I compressed my MP4 test file. Starting at 703 megabytes, WinRAR actually made headway by compressing it to 702 megabytes however 7-Zip once again increased the file size up to 708 megabytes. WinRAR took only 9 minutes 40 seconds however 7-Zip took up 11 minutes and 40 seconds. Once again WinRAR memory usage stayed at 43 megabytes but 7-Zip ate through an all time high of 742 megabytes. I felt like I was using a Pentium 1 with 16 megabytes of ram it was so horrendously slow.
Decompression simply reverses the actions of compression and makes the files useable again. When decompressing a split file you simply put all the pieces in one folder and your compression utility will decompress and assemble the file for you. Generally this process is much quicker since the processor is following a simple algorithm and it isn’t trying to find room for improvement. Both programs took under a second to decompress the first two files however with the Drivers 7-Zip took 4 seconds while WinRAR took less than a second. Now what was interesting about this was that for the first second or two 7-Zip slowly spooled up processor usage. This became even more obvious with the MP4 file. WinRAR took a snappy 38 seconds while 7-Zip took up 1 minute 29 seconds. When looking over the CPU usage, 7-zip would continuously dip from 100% usage down to around 40% and then climb up again. I am not sure what was causing this but running the test 4 times while defragmenting the drive in between still caused this. To rule out the file I tried decompressing my compressed Vista DVD ISO image which was over 4 gigabytes. The same spiking and dipping occurred so I believe there must be something within the software that causes it to freak when a certain file size is reached. Perhaps it ran out of memory to eat, I will never know.
It looks like I will be sticking with my favorite, WinRAR. I have always heard people say that 7-Zip is so much better than WinRAR but I guess those people must have 16 gigs of ram and a quad-core Opteron server. I really fell for WinRAR when I noticed 7-Zip eating through my entire gig of ram, that is simply not allowed. Now there is one minor incontinence for WinRAR, the fact that it is only a 30 day trial. I am not sure what 30 days means exactly though as I have had it installed for over 30 days and I still have 19 days left, maybe it is measured in Venetian days or something. This is in no way a complete review of these products features, I simply tested a specific setting that is most applicable to me, if you change up the compression settings there is a good chance your results will vary from mine. I hope I shed some light on this topic, if anything it proved that my Athlon64 is way to slow, time to upgrade.
In light of all the informative remarks I will be re-performing these tests while performing a more thorough test. I plan on testing all the compression features, 3 to 5 un-compressed files, a single compressed file, and then use some graphs to display the data. I will be rather busy for the next day or so however once I have free time then I wil go about performing these tests. This will be a bit time intensive but I feel that it will be worth the time to make up for this terrible test. I apologize for how uncomplete these tests were, they weren’t meant to be thorough. Should be some cool things coming this way over the next month though so stick around.