* testsuite/performance/20_util/allocator_thread.cc (do_loop):
Don't use clear, but instead assign. Use insert.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@76979
138bc75d-0d04-0410-961f-
82ee72b054a4
+2004-01-30 Felix Yen <fwy@alumni.brown.edu>
+
+ * testsuite/performance/20_util/allocator_thread.cc (do_loop):
+ Don't use clear, but instead assign. Use insert.
+
2004-01-30 Benjamin Kosnik <bkoz@redhat.com>
* src/demangle.cc: Add instantiations.
while (test_iterations < iterations)
{
for (int j = 0; j < insert_values; ++j)
- obj.push_back(test_iterations);
+ obj.insert(obj.begin(), test_iterations);
++test_iterations;
}
- obj.clear();
+ // NB: Don't use clear() here, instead force deallocation.
+ obj = Container();
test_iterations = 0;
while (test_iterations < iterations)
{
for (int j = 0; j < insert_values; ++j)
- obj.push_back(test_iterations);
+ obj.insert(obj.begin(), test_iterations);
++test_iterations;
}
}