views:

29

answers:

1

I'm working with a very simple filesystem database in order to benefit from performance. Unfortunately, the trade-off is disk space. I'm thinking about compressing data everytime I write and read from the filesystem database using gzuncompress and gzcompress. How slow are those functions? Can they be used without affecting my system performance?

A: 

Most of it will depend on how much and how many times you run it. Some say gzinflate and gzdeflate are faster for certain situations, the PHP manual's comments has some good insight: http://php.net/manual/en/function.gzdeflate.php

Ergo Summary
You can also use the second argument to reduce the compression amount as a speed tradeoff
Ergo Summary
I guess there's no escape, i'll have to run some tests and count the microseconds. :P
Jamie
sorry about that :s
Ergo Summary