Skip to content

Commit

Permalink
Make checksum scale factor a class member.
Browse files Browse the repository at this point in the history
I don't know how this code compiled.
  • Loading branch information
rhornung67 committed Oct 4, 2024
1 parent 70f8c16 commit 537db6f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/apps/EDGE3D.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ EDGE3D::EDGE3D(const RunParams& params)

setFLOPsPerRep(number_of_elements * flops_per_element);

checksum_scale_factor = 0.001 *
m_checksum_scale_factor = 0.001 *
( static_cast<Checksum_type>(getDefaultProblemSize()) /
getActualProblemSize() );

Expand Down Expand Up @@ -116,7 +116,7 @@ void EDGE3D::setUp(VariantID vid, size_t RAJAPERF_UNUSED_ARG(tune_idx))

void EDGE3D::updateChecksum(VariantID vid, size_t tune_idx)
{
checksum[vid][tune_idx] += calcChecksum(m_sum, m_array_length, checksum_scale_factor, vid );
checksum[vid][tune_idx] += calcChecksum(m_sum, m_array_length, m_checksum_scale_factor, vid );
}

void EDGE3D::tearDown(VariantID vid, size_t RAJAPERF_UNUSED_ARG(tune_idx))
Expand Down
2 changes: 2 additions & 0 deletions src/apps/EDGE3D.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -441,6 +441,8 @@ class EDGE3D : public KernelBase

ADomain* m_domain;
Index_type m_array_length;

Real_type m_checksum_scale_factor;
};

} // end namespace apps
Expand Down

0 comments on commit 537db6f

Please sign in to comment.