]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Must check for all (l,j) pairs for possible conflicts in scatter. 6378/head
authorMartin Kronbichler <kronbichler@lnm.mw.tum.de>
Sat, 28 Apr 2018 15:48:57 +0000 (17:48 +0200)
committerMartin Kronbichler <kronbichler@lnm.mw.tum.de>
Sat, 28 Apr 2018 15:50:10 +0000 (17:50 +0200)
include/deal.II/matrix_free/dof_info.templates.h

index 997b0a5c19dca3f07ef683e46f12bc44208f1154..401ea6c75a348ab0d506a1c13bb32aa956dd42c1 100644 (file)
@@ -700,12 +700,13 @@ no_constraint:
                   // do not use interleaved storage if two vectorized
                   // components point to the same field (scatter not possible)
                   for (unsigned int k=0; k<ndofs; ++k)
-                    for (unsigned int j=1; j<n_comp; ++j)
-                      if (dof_indices[j*ndofs+k] == dof_indices[k])
-                        {
-                          index_storage_variants[dof_access_cell][i] = IndexStorageVariants::full;
-                          break;
-                        }
+                    for (unsigned int l=0; l<n_comp; ++l)
+                      for (unsigned int j=l+1; j<n_comp; ++j)
+                        if (dof_indices[j*ndofs+k] == dof_indices[l*ndofs+k])
+                          {
+                            index_storage_variants[dof_access_cell][i] = IndexStorageVariants::full;
+                            break;
+                          }
                   if (index_storage_variants[dof_access_cell][i] != IndexStorageVariants::full)
                     {
                       unsigned int *interleaved_dof_indices =

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.