Use DoNotOptimize to prevent new/delete elision.

The new/delete tests, in particular those which test replacement
functions, often fail when the optimizer is enabled because the
calls to new/delete may be optimized away, regardless of their side-effects.

This patch converts the tests to use DoNotOptimize in order to prevent
the elision.

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@328245 91177308-0d34-0410-b5e6-96231b3b80d8
17 files changed