From 73d733433a48ffac9f3ea14086a9b54c3443af38 Mon Sep 17 00:00:00 2001 From: Luc Berger-Vergiat Date: Mon, 23 Sep 2019 16:49:15 -0600 Subject: [PATCH] MueLu: tentative fix for issue #5962 There is a bad access to a Kokkos::View data in AggregationPhase2bAlgorithm_kokkos. This should be fixed with these changes. --- .../MueLu_AggregationPhase2bAlgorithm_kokkos_def.hpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/muelu/src/Graph/UncoupledAggregation/MueLu_AggregationPhase2bAlgorithm_kokkos_def.hpp b/packages/muelu/src/Graph/UncoupledAggregation/MueLu_AggregationPhase2bAlgorithm_kokkos_def.hpp index 99f59493705e..f1e3c9d9a9e1 100644 --- a/packages/muelu/src/Graph/UncoupledAggregation/MueLu_AggregationPhase2bAlgorithm_kokkos_def.hpp +++ b/packages/muelu/src/Graph/UncoupledAggregation/MueLu_AggregationPhase2bAlgorithm_kokkos_def.hpp @@ -141,7 +141,7 @@ namespace MueLu { // (aggStat[neigh] == AGGREGATED) if (graph.isLocalNeighborVertex(neigh) && aggStat(neigh) == AGGREGATED) - Kokkos::atomic_add(&aggWeight(vertex2AggId(neigh, 0), 0), + Kokkos::atomic_add(&aggWeight(vertex2AggId(neigh, 0)), connectWeight(neigh)); } @@ -169,7 +169,7 @@ namespace MueLu { } } if (bestScore >= 0) { - aggStat(i, 0) = AGGREGATED; + aggStat(i) = AGGREGATED; vertex2AggId(i, 0) = bestAggId; procWinner(i, 0) = myRank; @@ -244,7 +244,7 @@ namespace MueLu { // (aggStat[neigh] == AGGREGATED) if (graph.isLocalNeighborVertex(neigh) && aggStat(neigh) == AGGREGATED) - Kokkos::atomic_add(&aggWeight(vertex2AggId(neigh, 0), 0), + Kokkos::atomic_add(&aggWeight(vertex2AggId(neigh, 0)), connectWeight(neigh)); } });