From: David Wells Date: Mon, 29 Jan 2018 03:59:04 +0000 (-0500) Subject: Split fe_values.cc into more instantiation files. X-Git-Tag: v9.0.0-rc1~464^2~1 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=aab5546309c93abfe6bf2334de991a99a3ab6634;p=dealii.git Split fe_values.cc into more instantiation files. This is currently the most expensive file to compile: with GCC 7.2 and all libraries but adol-c installed, this file requires 4.5 GB and 170s to (just for one of two instantiation files). This commit adds four additional instantiation files to lower the memory requirements below 3 GB per translation unit. Here is some profiling information: debug, master: 165s, 4 GB 170s, 4.5 GB (335 s total) release, master: 182s, 3.6 GB 194s, 3.9 GB (376s total) debug, feature: 37s, 1.7 GB 63s, 2.6 GB 31s, 1.5 GB 87s, 2.7 GB 58s, 2.6 GB 79s, 2.7 GB (355s total) release, feature: 37s, 1.5 GB 71s, 2.4 GB 32s, 1.5 GB 103s, 2.6 GB 69s, 2.3 GB 96s, 2.6 GB (408s total) --- diff --git a/source/fe/CMakeLists.txt b/source/fe/CMakeLists.txt index 5aba7b40a0..b77b0257e4 100644 --- a/source/fe/CMakeLists.txt +++ b/source/fe/CMakeLists.txt @@ -63,6 +63,10 @@ SET(_unity_include_src SET(_separate_src fe_values.cc fe_values_inst2.cc + fe_values_inst3.cc + fe_values_inst4.cc + fe_values_inst5.cc + fe_values_inst6.cc mapping_fe_field.cc mapping_fe_field_inst2.cc fe_tools_interpolate.cc diff --git a/source/fe/fe_values.cc b/source/fe/fe_values.cc index 686d6c35c9..197967bb2a 100644 --- a/source/fe/fe_values.cc +++ b/source/fe/fe_values.cc @@ -4579,7 +4579,7 @@ void FESubfaceValues::do_reinit (const unsigned int face_no, /*------------------------------- Explicit Instantiations -------------*/ -#define SPLIT_INSTANTIATIONS_COUNT 2 +#define SPLIT_INSTANTIATIONS_COUNT 6 #ifndef SPLIT_INSTANTIATIONS_INDEX #define SPLIT_INSTANTIATIONS_INDEX 0 #endif diff --git a/source/fe/fe_values_inst3.cc b/source/fe/fe_values_inst3.cc new file mode 100644 index 0000000000..fa934d3a46 --- /dev/null +++ b/source/fe/fe_values_inst3.cc @@ -0,0 +1,17 @@ +// --------------------------------------------------------------------- +// +// Copyright (C) 2018 by the deal.II authors +// +// This file is part of the deal.II library. +// +// The deal.II library is free software; you can use it, redistribute +// it, and/or modify it under the terms of the GNU Lesser General +// Public License as published by the Free Software Foundation; either +// version 2.1 of the License, or (at your option) any later version. +// The full text of the license can be found in the file LICENSE at +// the top level of the deal.II distribution. +// +// --------------------------------------------------------------------- + +#define SPLIT_INSTANTIATIONS_INDEX 2 +#include "fe_values.cc" diff --git a/source/fe/fe_values_inst4.cc b/source/fe/fe_values_inst4.cc new file mode 100644 index 0000000000..27dac84c83 --- /dev/null +++ b/source/fe/fe_values_inst4.cc @@ -0,0 +1,17 @@ +// --------------------------------------------------------------------- +// +// Copyright (C) 2018 by the deal.II authors +// +// This file is part of the deal.II library. +// +// The deal.II library is free software; you can use it, redistribute +// it, and/or modify it under the terms of the GNU Lesser General +// Public License as published by the Free Software Foundation; either +// version 2.1 of the License, or (at your option) any later version. +// The full text of the license can be found in the file LICENSE at +// the top level of the deal.II distribution. +// +// --------------------------------------------------------------------- + +#define SPLIT_INSTANTIATIONS_INDEX 3 +#include "fe_values.cc" diff --git a/source/fe/fe_values_inst5.cc b/source/fe/fe_values_inst5.cc new file mode 100644 index 0000000000..a6f595ba1c --- /dev/null +++ b/source/fe/fe_values_inst5.cc @@ -0,0 +1,17 @@ +// --------------------------------------------------------------------- +// +// Copyright (C) 2018 by the deal.II authors +// +// This file is part of the deal.II library. +// +// The deal.II library is free software; you can use it, redistribute +// it, and/or modify it under the terms of the GNU Lesser General +// Public License as published by the Free Software Foundation; either +// version 2.1 of the License, or (at your option) any later version. +// The full text of the license can be found in the file LICENSE at +// the top level of the deal.II distribution. +// +// --------------------------------------------------------------------- + +#define SPLIT_INSTANTIATIONS_INDEX 4 +#include "fe_values.cc" diff --git a/source/fe/fe_values_inst6.cc b/source/fe/fe_values_inst6.cc new file mode 100644 index 0000000000..f6158ff2c0 --- /dev/null +++ b/source/fe/fe_values_inst6.cc @@ -0,0 +1,17 @@ +// --------------------------------------------------------------------- +// +// Copyright (C) 2018 by the deal.II authors +// +// This file is part of the deal.II library. +// +// The deal.II library is free software; you can use it, redistribute +// it, and/or modify it under the terms of the GNU Lesser General +// Public License as published by the Free Software Foundation; either +// version 2.1 of the License, or (at your option) any later version. +// The full text of the license can be found in the file LICENSE at +// the top level of the deal.II distribution. +// +// --------------------------------------------------------------------- + +#define SPLIT_INSTANTIATIONS_INDEX 5 +#include "fe_values.cc"