Commit 7fdf5ec2 authored by Robert Maynard's avatar Robert Maynard Committed by Kitware Robot

Merge topic 'gcc_485_fixes'

41b8236a For GCC 4.8.4 'half' shadows a global variable with that name
770912f9 Correct compiler issues found with GCC 4.8.5 + CUDA 9.2 on summit
b248b2c9 Correct unused-parameter warnings from defaulted methods.
Acked-by: Kitware Robot's avatarKitware Robot <kwrobot@kitware.com>
Acked-by: Allison Vacanti's avatarAllison Vacanti <allison.vacanti@kitware.com>
Merge-request: !1666
parents af0460ba 41b8236a
......@@ -82,10 +82,10 @@ public:
explicit VTKM_CONT Storage(vtkm::cont::BitField&& data) noexcept : Data{ std::move(data) } {}
VTKM_CONT Storage() = default;
VTKM_CONT Storage(const Storage& src) = default;
VTKM_CONT Storage(Storage&& src) noexcept = default;
VTKM_CONT Storage& operator=(const Storage& src) = default;
VTKM_CONT Storage& operator=(Storage&& src) noexcept = default;
VTKM_CONT Storage(const Storage&) = default;
VTKM_CONT Storage(Storage&&) noexcept = default;
VTKM_CONT Storage& operator=(const Storage&) = default;
VTKM_CONT Storage& operator=(Storage&&) noexcept = default;
VTKM_CONT
PortalType GetPortal() { return PortalType{ this->Data.GetPortalControl() }; }
......
......@@ -145,10 +145,10 @@ protected:
public:
BitPortalBase() noexcept = default;
BitPortalBase(const BitPortalBase& src) noexcept = default;
BitPortalBase(BitPortalBase&& src) noexcept = default;
BitPortalBase& operator=(const BitPortalBase& src) noexcept = default;
BitPortalBase& operator=(BitPortalBase&& src) noexcept = default;
BitPortalBase(const BitPortalBase&) noexcept = default;
BitPortalBase(BitPortalBase&&) noexcept = default;
BitPortalBase& operator=(const BitPortalBase&) noexcept = default;
BitPortalBase& operator=(BitPortalBase&&) noexcept = default;
/// Returns the number of bits in the BitField.
VTKM_EXEC_CONT
......@@ -528,11 +528,11 @@ public:
: Internals{ std::make_shared<InternalStruct>() }
{
}
VTKM_CONT BitField(const BitField& src) = default;
VTKM_CONT BitField(BitField&& src) noexcept = default;
VTKM_CONT BitField(const BitField&) = default;
VTKM_CONT BitField(BitField&&) noexcept = default;
VTKM_CONT ~BitField() = default;
VTKM_CONT BitField& operator=(const BitField& src) = default;
VTKM_CONT BitField& operator=(BitField&& src) noexcept = default;
VTKM_CONT BitField& operator=(const BitField&) = default;
VTKM_CONT BitField& operator=(BitField&&) noexcept = default;
VTKM_CONT
bool operator==(const BitField& rhs) const { return this->Internals == rhs.Internals; }
......
......@@ -113,7 +113,7 @@ struct VTKM_CONT_EXPORT ScheduleParameterBuilder
}
auto preset = this->Presets.find(static_cast<GPU_STRATA>(strataAsInt));
ScheduleParameters params{ preset->second };
ScheduleParameters params = preset->second;
params.one_d_blocks = params.one_d_blocks * numSMs;
params.two_d_blocks = params.two_d_blocks * numSMs;
params.three_d_blocks = params.three_d_blocks * numSMs;
......
......@@ -241,7 +241,10 @@ private:
std::is_same<GlobalPopCountType, vtkm::UInt64>::value),
"Unsupported GlobalPopCountType. Must support CUDA atomicAdd.");
using Word = typename BitsPortal::WordTypePreferred;
//Using typename BitsPortal::WordTypePreferred causes dependent type errors using GCC 4.8.5
//which is the GCC required compiler for CUDA 9.2 on summit/power9
using Word = typename vtkm::cont::internal::AtomicInterfaceExecution<
DeviceAdapterTagCuda>::WordTypePreferred;
VTKM_STATIC_ASSERT(
VTKM_PASS_COMMAS(std::is_same<typename IndicesPortal::ValueType, vtkm::Id>::value));
......
......@@ -189,17 +189,17 @@ struct ConnIdxToCellIdCalc
while (length > 0)
{
vtkm::Id half = length / 2;
vtkm::Id pos = first + half;
vtkm::Id halfway = length / 2;
vtkm::Id pos = first + halfway;
vtkm::Id val = this->Offsets.Get(pos);
if (val <= inIdx)
{
first = pos + 1;
length -= half + 1;
length -= halfway + 1;
}
else
{
length = half;
length = halfway;
}
}
......
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