Skip to content

Commit 621f991

Browse files
authored
Merge fix for various warnings
Fixes -Wdelete-non-abstract-non-virtual-dtor, -Wreorder and deprecation warnings. Related PR: #1076
2 parents 664bb56 + 7320592 commit 621f991

File tree

5 files changed

+12
-8
lines changed

5 files changed

+12
-8
lines changed

include/ginkgo/core/base/executor.hpp

+4-4
Original file line numberDiff line numberDiff line change
@@ -1480,8 +1480,8 @@ class CudaExecutor : public detail::ExecutorBase<CudaExecutor>,
14801480
bool device_reset = false,
14811481
allocation_mode alloc_mode = default_cuda_alloc_mode)
14821482
: EnableDeviceReset{device_reset},
1483-
alloc_mode_{alloc_mode},
1484-
master_(master)
1483+
master_(master),
1484+
alloc_mode_{alloc_mode}
14851485
{
14861486
this->get_exec_info().device_id = device_id;
14871487
this->get_exec_info().num_computing_units = 0;
@@ -1685,8 +1685,8 @@ class HipExecutor : public detail::ExecutorBase<HipExecutor>,
16851685
bool device_reset = false,
16861686
allocation_mode alloc_mode = default_hip_alloc_mode)
16871687
: EnableDeviceReset{device_reset},
1688-
alloc_mode_(alloc_mode),
1689-
master_(master)
1688+
master_(master),
1689+
alloc_mode_(alloc_mode)
16901690
{
16911691
this->get_exec_info().device_id = device_id;
16921692
this->get_exec_info().num_computing_units = 0;

include/ginkgo/core/log/logger.hpp

+2
Original file line numberDiff line numberDiff line change
@@ -531,6 +531,8 @@ public: \
531531
static constexpr mask_type criterion_events_mask =
532532
criterion_check_started_mask | criterion_check_completed_mask;
533533

534+
virtual ~Logger() = default;
535+
534536
protected:
535537
/**
536538
* Constructor for a Logger object.

include/ginkgo/core/matrix/csr.hpp

+2
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,8 @@ class Csr : public EnableLinOp<Csr<ValueType, IndexType>>,
186186
*/
187187
strategy_type(std::string name) : name_(name) {}
188188

189+
virtual ~strategy_type() = default;
190+
189191
/**
190192
* Returns the name of strategy
191193
*

include/ginkgo/core/stop/residual_norm.hpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -98,8 +98,8 @@ class ResidualNormBase
9898
remove_complex<ValueType> reduction_factor,
9999
mode baseline)
100100
: EnablePolymorphicObject<ResidualNormBase, Criterion>(exec),
101-
device_storage_{exec, 2},
102101
reduction_factor_{reduction_factor},
102+
device_storage_{exec, 2},
103103
baseline_{baseline},
104104
system_matrix_{args.system_matrix},
105105
b_{args.b},

test/test_install/test_install.cpp

+3-3
Original file line numberDiff line numberDiff line change
@@ -328,7 +328,7 @@ int main()
328328

329329
// core/log/convergence.hpp
330330
{
331-
auto test = gko::log::Convergence<>::create(exec);
331+
auto test = gko::log::Convergence<>::create();
332332
}
333333

334334
// core/log/record.hpp
@@ -338,13 +338,13 @@ int main()
338338

339339
// core/log/stream.hpp
340340
{
341-
auto test = gko::log::Stream<>::create(exec);
341+
auto test = gko::log::Stream<>::create();
342342
}
343343

344344
#if GKO_HAVE_PAPI_SDE
345345
// core/log/papi.hpp
346346
{
347-
auto test = gko::log::Papi<>::create(exec);
347+
auto test = gko::log::Papi<>::create();
348348
}
349349
#endif // GKO_HAVE_PAPI_SDE
350350

0 commit comments

Comments
 (0)