testing C++ optimizaiton techniques