- Make sure testsuite passes with "exception-handling=off". Requires using a custom mini-timer since Boost.Timer depends on Boost.Chrono, and Boost.Chrono's dll does not compile without exceptions.

This commit is contained in:
Ion Gaztañaga committed 2020-10-22 23:12:51 +02:00
1 parent ac4d3feed1
commit 75eb880a56
7 files changed
+235 -23

No files matched your search

+6 -13
View File
@@ -18,16 +18,16 @@
#include <boost/container/vector.hpp> //boost::container::vector
#include <boost/config.hpp>
#include <cstdlib>
#include <boost/move/unique_ptr.hpp>
#include <boost/timer/timer.hpp>
#include <boost/move/detail/nsec_clock.hpp>
#include "order_type.hpp"
#include "random_shuffle.hpp"
using boost::timer::cpu_timer;
using boost::timer::cpu_times;
using boost::timer::nanosecond_type;
using boost::move_detail::cpu_timer;
using boost::move_detail::nanosecond_type;
void print_stats(const char *str, boost::ulong_long_type element_count)
{
@@ -255,9 +255,8 @@ bool measure_all(std::size_t L, std::size_t NK)
elements = original_elements;
res = res && measure_algo(elements.data(), L, split_pos,StdInplaceMerge, prev_clock);
//
if(!res)
throw int(0);
if (!res)
std::abort();
return res;
}
@@ -267,7 +266,6 @@ bool measure_all(std::size_t L, std::size_t NK)
int main()
{
try{
#ifndef BENCH_SORT_UNIQUE_VALUES
measure_all<order_perf_type>(101,1);
measure_all<order_perf_type>(101,5);
@@ -324,11 +322,6 @@ int main()
measure_all<order_perf_type>(10000001,0);
#endif //#ifndef BENCH_MERGE_SHORT
#endif //#ifdef NDEBUG
}
catch(...)
{
return 1;
}
return 0;
}