On Sat, 2014-01-25 at 16:05 +0000, Fraser Adams wrote:
> Qpid has now deprecated the automake build process and moved to CMake,
> but I've got a nagging feeling.........
>
> I've not *actually* got round to doing any benchmark/performance test
> type things since I moved to using CMake myself and I'm wondering to
> myself whether as part of Qpid/Proton release cycle anyone is has been
> doing regression tests and in particular systematic performance tests?
>
> One of my colleagues mentioned to me that he reckons that there was a
> performance drop off between (I think) 0.12 and 0.18 but I've got no
> evidence other than anecdotal from him and certainly no reproducer.
>
> It did get me thinking about CMake though (though my colleague insists
> he was using automake so there might still be an issue).
>
> Am I correct in thinking that with CMake there are different "build
> types" and that in "idiomatic" CMake usage it's "generally" via the use
> of different build types that compiler optimisation flags get set?
>
> In the automake build system I think that things were set to "-O3", but
> I'm less convinced for CMake, indeed I *think* when at one point I made
> Proton using make VERBOSE=1 I made a mental note that I didn't see any
> optimisation flags.
>
> The install instructions tend to say things along the lines of
>
> mkdir build
> cd build
> cmake ..
> make all
> make install
>
> CMAKE_BUILD_TYPE=Release
> But I'm wondering if the third step really should be:
> cmake CMAKE_BUILD_TYPE=Release ..
>
> or somesuch.
>
> I'm not much of a CMake expert (barely beyond a N00b) but if we do need
> something like that to build with optimisation flags then I reckon we
> *really* need to make sure that the Qpid and Proton build/install guides
> get updated to reflect this otherwise users might be seeing
> unrepresentative performance figures.
>
> This might be second nature to CMake experts, but possibly/probably
> isn't for everyone.
>
> Thoughts?
>
I am easily confused and often switch between debug and release builds
for debugging vs. profiling work so I always put my builds in
directories called debug*, release* or reldbg* and I have my run-cmake
script like this:
case $(basename $PWD) in
debug*) BUILD_TYPE=Debug;;
release*) BUILD_TYPE=Release;;
reldbg*) BUILD_TYPE=RelWithDebInfo;;
esac
BUILD_TYPE=${1:-$BUILD_TYPE}
test -n "$BUILD_TYPE" || { echo "Specify build type."; exit 1; }
# And later...
cmake ... -DCMAKE_BUILD_TYPE:STRING=$BUILD_TYPE
This has saved me many hours (days) of trying to figure out why my
performance results are suddenly in the toilet because I forgot which
build flags I set.
Cheers,
Alan.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]