Skip to content

Commit b86a6ab

Browse files
authored
Merge pull request mfem#1485 from mfem/x86-updates
Some updates to the SIMD intrinsics branch
2 parents 6173cb7 + 1be972b commit b86a6ab

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

42 files changed

+742
-1039
lines changed

.travis.yml

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@
1111

1212
language: cpp
1313

14-
sudo: false
15-
1614
stages:
1715
- checks
1816
- tests
@@ -370,8 +368,10 @@ script:
370368
# Compiler
371369
- if [ $MPI == "YES" ]; then
372370
export MYCXX=mpic++;
371+
export MAKE_CXX_FLAG=MPICXX=$MYCXX;
373372
else
374373
export MYCXX="$CXX";
374+
export MAKE_CXX_FLAG=CXX=$MYCXX;
375375
fi
376376

377377
# Print the compiler version
@@ -384,12 +384,9 @@ script:
384384
if [ "$CODECOV" == "YES" ]; then
385385
CPPFLAGS="--coverage -g";
386386
fi;
387-
if [ "$CXX" == "clang++" ]; then
388-
export MFEM_PERF_SW=clang;
389-
fi
390387

391388
# Configure the library
392-
- make config MFEM_USE_MPI=$MPI MFEM_DEBUG=$DEBUG MFEM_CXX="$MYCXX"
389+
- make config MFEM_USE_MPI=$MPI MFEM_DEBUG=$DEBUG $MAKE_CXX_FLAG
393390
MFEM_MPI_NP=$NPROCS CPPFLAGS="$CPPFLAGS"
394391
# Show the configuration
395392
- make info

INSTALL

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -396,9 +396,11 @@ MFEM_USE_SIDRE = YES/NO
396396
blueprint specification. When enabled, this option requires installation of
397397
HDF5 (see also MFEM_USE_NETCDF), Conduit and LLNL's axom project.
398398

399-
MFEM_USE_SIMD = YES/NO
400-
Enables the high performance templated classes to use specific intrinsics
401-
instead of the AutoSIMD (config/simd/auto.hpp) classe.
399+
MFEM_USE_SIMD = YES/NO
400+
Enables the high performance templated classes to use architecture dependent
401+
SIMD intrinsics instead of the generic implementation of class AutoSIMD in
402+
linalg/simd/auto.hpp. This option should be combined with suitable
403+
compiler options, such as -march=native, to enable optimal vectorization.
402404

403405
MFEM_USE_CONDUIT = YES/NO
404406
Enables support for converting MFEM Mesh and Grid Function objects to and

config/cmake/MFEMConfig.cmake.in

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ set(MFEM_USE_OCCA @MFEM_USE_OCCA@)
4747
set(MFEM_USE_RAJA @MFEM_USE_RAJA@)
4848
set(MFEM_USE_CEED @MFEM_USE_CEED@)
4949
set(MFEM_USE_UMPIRE @MFEM_USE_UMPIRE@)
50+
set(MFEM_USE_SIMD @MFEM_USE_SIMD@)
5051
set(MFEM_USE_ADIOS2 @MFEM_USE_ADIOS2@)
5152

5253
set(MFEM_CXX_COMPILER "@CMAKE_CXX_COMPILER@")

config/cmake/config.hpp.in

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,9 @@
107107
// Enable MFEM functionality based on the Sidre library
108108
#cmakedefine MFEM_USE_SIDRE
109109

110+
// Enable the high performance templated classes to use SIMD
111+
#cmakedefine MFEM_USE_SIMD
112+
110113
// Enable MFEM functionality based on Conduit
111114
#cmakedefine MFEM_USE_CONDUIT
112115

config/cmake/modules/MfemCmakeUtilities.cmake

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -733,7 +733,7 @@ function(mfem_export_mk_files)
733733
MFEM_USE_SUPERLU MFEM_USE_STRUMPACK MFEM_USE_GNUTLS
734734
MFEM_USE_GSLIB MFEM_USE_NETCDF MFEM_USE_PETSC MFEM_USE_MPFR MFEM_USE_SIDRE
735735
MFEM_USE_CONDUIT MFEM_USE_PUMI MFEM_USE_CUDA MFEM_USE_OCCA MFEM_USE_RAJA
736-
MFEM_USE_UMPIRE)
736+
MFEM_USE_UMPIRE MFEM_USE_SIMD MFEM_USE_ADIOS2)
737737
foreach(var ${CONFIG_MK_BOOL_VARS})
738738
if (${var})
739739
set(${var} YES)
@@ -743,6 +743,7 @@ function(mfem_export_mk_files)
743743
endforeach()
744744
# TODO: Add support for MFEM_USE_CUDA=YES
745745
set(MFEM_CXX ${CMAKE_CXX_COMPILER})
746+
set(MFEM_HOST_CXX ${MFEM_CXX})
746747
set(MFEM_CPPFLAGS "")
747748
string(STRIP "${CMAKE_CXX_FLAGS_${BUILD_TYPE}} ${CMAKE_CXX_FLAGS}"
748749
MFEM_CXXFLAGS)

config/config.mk.in

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ MFEM_USE_ADIOS2 = @MFEM_USE_ADIOS2@
5454

5555
# Compiler, compile options, and link options
5656
MFEM_CXX = @MFEM_CXX@
57+
MFEM_HOST_CXX = @MFEM_HOST_CXX@
5758
MFEM_CPPFLAGS = @MFEM_CPPFLAGS@
5859
MFEM_CXXFLAGS = @MFEM_CXXFLAGS@
5960
MFEM_TPLFLAGS = @MFEM_TPLFLAGS@

config/defaults.cmake

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@ option(MFEM_USE_OCCA "Enable OCCA" OFF)
4949
option(MFEM_USE_RAJA "Enable RAJA" OFF)
5050
option(MFEM_USE_CEED "Enable CEED" OFF)
5151
option(MFEM_USE_UMPIRE "Enable Umpire" OFF)
52+
option(MFEM_USE_SIMD "Enable use of SIMD intrinsics" ON)
5253
option(MFEM_USE_ADIOS2 "Enable ADIOS2" OFF)
5354

5455
set(MFEM_MPI_NP 4 CACHE STRING "Number of processes used for MPI tests")

config/simd/m64.hpp

Lines changed: 0 additions & 230 deletions
This file was deleted.

config/simd/qpx.hpp

Lines changed: 0 additions & 23 deletions
This file was deleted.

0 commit comments

Comments
 (0)