File tree Expand file tree Collapse file tree 5 files changed +20
-9
lines changed
algorithms/tests/performance Expand file tree Collapse file tree 5 files changed +20
-9
lines changed Original file line number Diff line number Diff line change @@ -16,13 +16,13 @@ hpx_targets=(
16
16
hpx_test_options=(
17
17
" --hpx:ini=hpx.thread_queue.init_threads_count=100 \
18
18
--hpx:threads=4 --vector_size=104857 --work_delay=1 \
19
- --chunk_size=0 --test_count=200"
19
+ --chunk_size=0 --test_count=200 --detailed_bench "
20
20
" --hpx:ini=hpx.thread_queue.init_threads_count=100 \
21
21
--hpx:queuing=local-priority --hpx:threads=4 --test-all \
22
- --repetitions=40 --futures=207270"
22
+ --repetitions=40 --futures=207270 --detailed_bench "
23
23
" --hpx:ini=hpx.thread_queue.init_threads_count=100 \
24
24
--vector_size=518176 --hpx:threads=4 --iterations=200 \
25
- --warmup_iterations=20" )
25
+ --warmup_iterations=20 --detailed_bench " )
26
26
27
27
# Build binaries for performance tests
28
28
${perftests_dir} /driver.py -v -l $logfile build -b release -o build \
Original file line number Diff line number Diff line change @@ -41,6 +41,8 @@ int hpx_main(hpx::program_options::variables_map& vm)
41
41
disable_stealing = vm.count (" disable_stealing" );
42
42
fast_idle_mode = vm.count (" fast_idle_mode" );
43
43
44
+ hpx::util::perftests_init (vm);
45
+
44
46
// verify that input is within domain of program
45
47
if (test_count == 0 || test_count < 0 )
46
48
{
@@ -122,6 +124,7 @@ int main(int argc, char* argv[])
122
124
;
123
125
// clang-format on
124
126
127
+ hpx::util::perftests_cfg (cmdline);
125
128
hpx::local::init_params init_args;
126
129
init_args.desc_cmdline = cmdline;
127
130
init_args.cfg = {" hpx.os_threads=all" };
Original file line number Diff line number Diff line change @@ -120,14 +120,15 @@ average: {{average(elapsed)}}{{^-last}}
120
120
int outputs = 0 ;
121
121
for (auto && item : obj.m_map )
122
122
{
123
+ long double average = static_cast <long double >(0.0 );
123
124
if (outputs)
124
125
strm << " ," ;
125
126
strm << " \n {\n " ;
126
- strm << R"( "name" : ")" << std::get<0 >(item.first )
127
+ strm << R"( "name": ")" << std::get<0 >(item.first )
127
128
<< " \" ,\n " ;
128
- strm << R"( "executor" : ")" << std::get<1 >(item.first )
129
+ strm << R"( "executor": ")" << std::get<1 >(item.first )
129
130
<< " \" ,\n " ;
130
- strm << R"( "series" : [)"
131
+ strm << R"( "series": [)"
131
132
<< " \n " ;
132
133
int series = 0 ;
133
134
strm.precision (
@@ -140,10 +141,11 @@ average: {{average(elapsed)}}{{^-last}}
140
141
}
141
142
strm << R"( )" << std::scientific << val;
142
143
++series;
144
+ average += val;
143
145
}
144
-
145
- strm << " \n ] \n " ;
146
-
146
+ strm << " \n ], \n " ;
147
+ strm << std::scientific << R"( "average": )" << average / series
148
+ << " \n " ;
147
149
strm << " }" ;
148
150
++outputs;
149
151
}
Original file line number Diff line number Diff line change @@ -165,6 +165,9 @@ int hpx_main(variables_map& vm)
165
165
num_iterations = vm[" delay-iterations" ].as <std::uint64_t >();
166
166
167
167
const std::uint64_t count = vm[" futures" ].as <std::uint64_t >();
168
+
169
+ hpx::util::perftests_init (vm);
170
+
168
171
if (HPX_UNLIKELY (0 == count))
169
172
throw std::logic_error (" error: count of 0 futures specified\n " );
170
173
@@ -201,6 +204,7 @@ int main(int argc, char* argv[])
201
204
// clang-format on
202
205
203
206
// Initialize and run HPX.
207
+ hpx::util::perftests_cfg (cmdline);
204
208
hpx::local::init_params init_args;
205
209
init_args.desc_cmdline = cmdline;
206
210
Original file line number Diff line number Diff line change @@ -442,6 +442,7 @@ int hpx_main(hpx::program_options::variables_map& vm)
442
442
std::size_t iterations = vm[" iterations" ].as <std::size_t >();
443
443
std::size_t warmup_iterations = vm[" warmup_iterations" ].as <std::size_t >();
444
444
std::size_t chunk_size = vm[" chunk_size" ].as <std::size_t >();
445
+ hpx::util::perftests_init (vm);
445
446
std::size_t executor;
446
447
header = vm.count (" header" ) > 0 ;
447
448
@@ -548,6 +549,7 @@ int main(int argc, char* argv[])
548
549
" hpx.numa_sensitive=2" // no-cross NUMA stealing
549
550
};
550
551
552
+ hpx::util::perftests_cfg (cmdline);
551
553
hpx::init_params init_args;
552
554
init_args.desc_cmdline = cmdline;
553
555
init_args.cfg = cfg;
You can’t perform that action at this time.
0 commit comments