Below is a patch I sent to Richard but I think he must be on holiday or something because there has been no response yet. I wonder if other openSSL developers would care to try this out.
-Andrew ------------ Hello Richard, Attached is a tarfile with some minor changes to c_rle.c and c_zlib.c for a performance improvement in compression. Please consider it and let me know what you think. Basically there were some repeated allocations going on which could be done just once per context. At first I put this information in the context but then I put it in the COMP_METHOD structure (hence comp.h was changed and r_rle.c was affected to initialise it to NULL). Saving repeated heap allocates when compressing lots of relatively small packets really seems to make a dramatic difference. Regards, Andrew M.
ossl.tgz
Description: Binary data