Commit 5bf76fbb authored by Lorenz Huedepohl's avatar Lorenz Huedepohl Committed by Pavel Kus

Off by one error in autotuning

Lead to the first configuration be tested twice
parent 124fb0d9
......@@ -864,7 +864,7 @@ module elpa_impl
call self%autotune_timer%free()
endif
do while (ts_impl%i < ts_impl%N)
do while (ts_impl%i < ts_impl%N - 1)
ts_impl%i = ts_impl%i + 1
if (elpa_index_set_autotune_parameters_c(self%index, ts_impl%level, ts_impl%domain, ts_impl%i) == 1) then
unfinished = .true.
......@@ -922,7 +922,6 @@ module elpa_impl
print *, "This should not happen"
end select
print *, "set best, i = ", ts_impl%min_loc, "best time = ", ts_impl%min_val
if (elpa_index_set_autotune_parameters_c(self%index, ts_impl%level, ts_impl%domain, ts_impl%min_loc) /= 1) then
stop "This should not happen (in elpa_autotune_set_best())"
endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment