Search code examples
compressionexecutableupx

Use UPX (executable compresser) on release builds?


I was wondering if it's normal/acceptable to use UPX (or any other executable compressor for that matter) on a release build for a project.

For example, I have this executable which normally is 1.7MB when shipped, but when packed it's 426KB. Not that I care about 1.2MB of storage, but 426KB looks much nicer when downloading and in general.

Also, I have heard - not tested - that some programs perform better on startup when compressed because reading from the harddisk is more expensive than decompressing.

So is it recommended to compress your executables on a release build?


Solution

  • I have heard - not tested - that some programs perform better on startup when compressed because reading from the harddisk is more expensive than decompressing.

    Sometimes the opposite is true because the program only needs to load code pages on demand. But it can't do this is the exe is compressed.

    If you have multiple instances of your executable running, then the memory will be shared between each instance. But if you compress them this is no longer the case.

    As for downloading, surely what is downloaded is an install package which is compressed.

    In short, I really don't think executable compressors are worthwhile.