]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Add instantiations 2017/head
authorMartin Kronbichler <kronbichler@lnm.mw.tum.de>
Thu, 7 Jan 2016 12:28:16 +0000 (13:28 +0100)
committerMartin Kronbichler <kronbichler@lnm.mw.tum.de>
Thu, 7 Jan 2016 12:28:16 +0000 (13:28 +0100)
source/multigrid/mg_level_global_transfer.cc
source/multigrid/mg_level_global_transfer.inst.in

index 8fec5c832c959607daf2c1d05e9ee2a6fd77d594..884630a0fab0e82174a3ec8a7fc07834f671ed7e 100644 (file)
@@ -312,11 +312,9 @@ void
 MGLevelGlobalTransfer<VectorType>::clear()
 {
   sizes.resize(0);
-  std::vector<std::vector<std::pair<types::global_dof_index, types::global_dof_index> > >
-  empty0, empty1, empty2;
-  copy_indices.swap(empty0);
-  copy_indices_global_mine.swap(empty1);
-  copy_indices_level_mine.swap(empty2);
+  copy_indices.clear();
+  copy_indices_global_mine.clear();
+  copy_indices_level_mine.clear();
   component_to_block_map.resize(0);
   mg_constrained_dofs = 0;
 }
@@ -505,11 +503,9 @@ void
 MGLevelGlobalTransfer<parallel::distributed::Vector<Number> >::clear()
 {
   sizes.resize(0);
-  std::vector<std::vector<std::pair<unsigned int, unsigned int> > >
-  empty0, empty1, empty2;
-  copy_indices.swap(empty0);
-  copy_indices_global_mine.swap(empty1);
-  copy_indices_level_mine.swap(empty2);
+  copy_indices.clear();
+  copy_indices_global_mine.clear();
+  copy_indices_level_mine.clear();
   component_to_block_map.resize(0);
   mg_constrained_dofs = 0;
   ghosted_global_vector.reinit(0);
@@ -567,5 +563,10 @@ MGLevelGlobalTransfer<parallel::distributed::Vector<Number> >::memory_consumptio
 // explicit instantiation
 #include "mg_level_global_transfer.inst"
 
+// create two additional instantiations currently not supported by the
+// automatic template instantiation scheme
+template class MGLevelGlobalTransfer<parallel::distributed::Vector<float> >;
+template class MGLevelGlobalTransfer<parallel::distributed::Vector<long double> >;
+
 
 DEAL_II_NAMESPACE_CLOSE
index 0437e9425de1e7b6bfcad7486b8110c34872f36a..8187c87da982aaf80579d1ad9d25803d2c552a72 100644 (file)
@@ -40,17 +40,27 @@ for (deal_II_dimension : DIMENSIONS; V1,V2 : DEAL_II_VEC_TEMPLATES; S1, S2 : REA
                                                         const MGLevelObject<V1<S1> >&) const;
   }
 
-for (deal_II_dimension : DIMENSIONS; S2 : REAL_SCALARS)
+for (deal_II_dimension : DIMENSIONS)
+  {
+    template
+      void MGLevelGlobalTransfer< parallel::distributed::Vector<float> >::fill_and_communicate_copy_indices<deal_II_dimension,deal_II_dimension>(
+        const DoFHandler<deal_II_dimension,deal_II_dimension> &mg_dof);
+    template
+      void MGLevelGlobalTransfer< parallel::distributed::Vector<long double> >::fill_and_communicate_copy_indices<deal_II_dimension,deal_II_dimension>(
+        const DoFHandler<deal_II_dimension,deal_II_dimension> &mg_dof);
+  }
+
+for (deal_II_dimension : DIMENSIONS; S1, S2 : REAL_SCALARS)
   {
     template void
-      MGLevelGlobalTransfer<parallel::distributed::Vector<double> >::copy_to_mg (
-        const DoFHandler<deal_II_dimension>&, MGLevelObject<parallel::distributed::Vector<double> >&, const parallel::distributed::Vector<S2>&) const;
+      MGLevelGlobalTransfer<parallel::distributed::Vector<S1> >::copy_to_mg (
+        const DoFHandler<deal_II_dimension>&, MGLevelObject<parallel::distributed::Vector<S1> >&, const parallel::distributed::Vector<S2>&) const;
     template void
-      MGLevelGlobalTransfer<parallel::distributed::Vector<double> >::copy_from_mg (const DoFHandler<deal_II_dimension>&, parallel::distributed::Vector<S2>&,
-        const MGLevelObject<parallel::distributed::Vector<double> >&) const;
+      MGLevelGlobalTransfer<parallel::distributed::Vector<S1> >::copy_from_mg (const DoFHandler<deal_II_dimension>&, parallel::distributed::Vector<S2>&,
+        const MGLevelObject<parallel::distributed::Vector<S1> >&) const;
     template void
-      MGLevelGlobalTransfer<parallel::distributed::Vector<double> >::copy_from_mg_add (const DoFHandler<deal_II_dimension>&, parallel::distributed::Vector<S2>&,
-        const MGLevelObject<parallel::distributed::Vector<double> >&) const;
+      MGLevelGlobalTransfer<parallel::distributed::Vector<S1> >::copy_from_mg_add (const DoFHandler<deal_II_dimension>&, parallel::distributed::Vector<S2>&,
+        const MGLevelObject<parallel::distributed::Vector<S1> >&) const;
   }
 
 for(deal_II_dimension : DIMENSIONS)

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.