Big performance difference: BUILD_TYPE "Debug" vs "Release" #193

Closed
opened 2026-01-29 20:39:36 +00:00 by claunia · 1 comment
Owner

Originally created by @jschleus on GitHub (Sep 21, 2017).

I just compiled brotli-1.0.0 on a Linux system (openSUSE Leap 42.3) according the build instructions within the README.md file.

As a first test I compressed an arbitrary log file and I got an output file slightly smaller than the xz-variant (not a benchmark, no special optimizations). Just for curiosity I downloaded also the file brotli-linux-v1.0.0.zip and repeated the compression with the precompiled brotli binary and surprisingly the compression was now done nearly three times (!) faster (with the same resulting output). After some testing I found out that setting BUILD_TYPE="Release" instead of the default BUILD_TYPE="Debug" in the configure-cmake script leads also to the shorter compression time. This setting may be also achieved by the option "--disable-debug".

So I recommend to add an according information into the build instructions to let the brotli performance appear in the right light. But I am a layman in this area and maybe I have overseen something.

Originally created by @jschleus on GitHub (Sep 21, 2017). I just compiled brotli-1.0.0 on a Linux system (openSUSE Leap 42.3) according the build instructions within the README.md file. As a first test I compressed an arbitrary log file and I got an output file slightly smaller than the xz-variant (not a benchmark, no special optimizations). Just for curiosity I downloaded also the file brotli-linux-v1.0.0.zip and repeated the compression with the precompiled brotli binary and surprisingly the compression was now done nearly three times (!) faster (with the same resulting output). After some testing I found out that setting BUILD_TYPE="Release" instead of the default BUILD_TYPE="Debug" in the configure-cmake script leads also to the shorter compression time. This setting may be also achieved by the option "--disable-debug". So I recommend to add an according information into the build instructions to let the brotli performance appear in the right light. But I am a layman in this area and maybe I have overseen something.
Author
Owner

@eustas commented on GitHub (Sep 21, 2017):

Surely. I'll update README.md to reflect that default build with configure-cmake is "Debug".
It is mentioned inside configure-cmake, that this is done to reflect default automake behaviour...

@eustas commented on GitHub (Sep 21, 2017): Surely. I'll update README.md to reflect that default build with configure-cmake is "Debug". It is mentioned inside configure-cmake, that this is done to reflect default automake behaviour...
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/brotli#193