Clean up main.cpp
Make QueryTransformationEngine clean up after itself
Add proper cleanup for hwloc helper
Merge pull request #233 from bastih/master

Some extra cleanups that make valgrind output more readable