Moved cpp implementation with pruning to cpppruned.cpp.