From: Martin Kronbichler Date: Sat, 5 Apr 2025 11:46:49 +0000 (+0200) Subject: Portable FEEvaluation: Only go into constraints function if constrained X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2d23341c596fc045c1adf6c9215799bb6135c6cc;p=dealii.git Portable FEEvaluation: Only go into constraints function if constrained --- diff --git a/include/deal.II/matrix_free/portable_fe_evaluation.h b/include/deal.II/matrix_free/portable_fe_evaluation.h index 3b20bd5fbe..0db768b51b 100644 --- a/include/deal.II/matrix_free/portable_fe_evaluation.h +++ b/include/deal.II/matrix_free/portable_fe_evaluation.h @@ -327,11 +327,14 @@ namespace Portable for (unsigned int c = 0; c < n_components_; ++c) { - internal::resolve_hanging_nodes( - data->team_member, - precomputed_data->constraint_weights, - precomputed_data->constraint_mask(cell_id * n_components + c), - Kokkos::subview(shared_data->values, Kokkos::ALL, c)); + if (precomputed_data->constraint_mask(cell_id * n_components + c) != + dealii::internal::MatrixFreeFunctions::ConstraintKinds:: + unconstrained) + internal::resolve_hanging_nodes( + data->team_member, + precomputed_data->constraint_weights, + precomputed_data->constraint_mask(cell_id * n_components + c), + Kokkos::subview(shared_data->values, Kokkos::ALL, c)); } } @@ -348,11 +351,14 @@ namespace Portable { for (unsigned int c = 0; c < n_components_; ++c) { - internal::resolve_hanging_nodes( - data->team_member, - precomputed_data->constraint_weights, - precomputed_data->constraint_mask(cell_id * n_components + c), - Kokkos::subview(shared_data->values, Kokkos::ALL, c)); + if (precomputed_data->constraint_mask(cell_id * n_components + c) != + dealii::internal::MatrixFreeFunctions::ConstraintKinds:: + unconstrained) + internal::resolve_hanging_nodes( + data->team_member, + precomputed_data->constraint_weights, + precomputed_data->constraint_mask(cell_id * n_components + c), + Kokkos::subview(shared_data->values, Kokkos::ALL, c)); } if (precomputed_data->use_coloring)