Fix verification of dot kernel
This commit is contained in:
parent
28c2660b52
commit
1e94870859
2
main.cpp
2
main.cpp
@ -249,7 +249,7 @@ void check_solution(const unsigned int ntimes, std::vector<T>& a, std::vector<T>
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Do the reduction
|
// Do the reduction
|
||||||
goldSum = goldA * goldB * ntimes;
|
goldSum = goldA * goldB * ARRAY_SIZE;
|
||||||
|
|
||||||
// Calculate the average error
|
// Calculate the average error
|
||||||
double errA = std::accumulate(a.begin(), a.end(), 0.0, [&](double sum, const T val){ return sum + fabs(val - goldA); });
|
double errA = std::accumulate(a.begin(), a.end(), 0.0, [&](double sum, const T val){ return sum + fabs(val - goldA); });
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user