Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion .github/workflows/Linux.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,14 @@ jobs:
matrix:
#os: [ubuntu-18.04, ubuntu-latest]
os: [ubuntu-latest]
build_type: [serial, openmp]
build_type: [serial, openmp, debug]
include:
- build_type: serial
cmake_flags: -DCMAKE_INSTALL_PREFIX=`pwd` -DCMAKE_BUILD_TYPE=Release -DELEMENTS_ENABLE_SERIAL=ON -DELEMENTS_ENABLE_OPENMP=OFF
- build_type: openmp
cmake_flags: -DCMAKE_INSTALL_PREFIX=`pwd` -DCMAKE_BUILD_TYPE=Release -DELEMENTS_ENABLE_SERIAL=ON -DELEMENTS_ENABLE_OPENMP=ON
- build_type: debug
cmake_flags: -DCMAKE_INSTALL_PREFIX=`pwd` -DCMAKE_BUILD_TYPE=Debug -DELEMENTS_ENABLE_SERIAL=ON -DELEMENTS_ENABLE_OPENMP=OFF
runs-on: ${{matrix.os}}

steps:
Expand Down
12 changes: 10 additions & 2 deletions .github/workflows/MacOS.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,14 @@ jobs:
fail-fast: false
matrix:
os: [macos-11, macos-latest]
build_type: [serial, openmp]
build_type: [serial, openmp, debug]
include:
- build_type: serial
extra_flags: "-DELEMENTS_ENABLE_SERIAL=ON -DELEMENTS_ENABLE_OPENMP=OFF"
- build_type: openmp
extra_flags: "-DELEMENTS_ENABLE_SERIAL=ON -DELEMENTS_ENABLE_OPENMP=ON"
- build_type: debug
extra_flags: "-DELEMENTS_ENABLE_SERIAL=ON -DELEMENTS_ENABLE_OPENMP=OFF"
runs-on: ${{matrix.os}}

steps:
Expand All @@ -44,10 +46,16 @@ jobs:
# Explicitly hint Bison to CMake just in case
BISON_PATH=$(brew --prefix bison)/bin/bison
FLEX_PATH=$(brew --prefix flex)/bin/flex
# Determine build type
BUILD_TYPE="Release"
if [[ "${{ matrix.build_type }}" == "debug" ]]; then
BUILD_TYPE="Debug"
fi

# Initialize flags array
CMAKE_OPTS=(
"-DCMAKE_INSTALL_PREFIX=${{github.workspace}}/install"
"-DCMAKE_BUILD_TYPE=Release"
"-DCMAKE_BUILD_TYPE=$BUILD_TYPE"
"-DBISON_EXECUTABLE=$BISON_PATH"
"-DFLEX_EXECUTABLE=$FLEX_PATH"
)
Expand Down
10 changes: 5 additions & 5 deletions src/geometry/shapes.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ class Plane

Plane(const ViewCArrayKokkos<double>& position_inp, const ViewCArrayKokkos<double>& normal_inp){

assert(position_inp.order() = 1 && "Plane constructor requires a 1D ViewCArrayKokkos<double> for position");
assert(normal_inp.order() = 1 && "Plane constructor requires a 1D ViewCArrayKokkos<double> for normal");
assert(position_inp.order() == 1 && "Plane constructor requires a 1D ViewCArrayKokkos<double> for position");
assert(normal_inp.order() == 1 && "Plane constructor requires a 1D ViewCArrayKokkos<double> for normal");
assert(position_inp.extent() == normal_inp.extent() && "Plane constructor requires the position and normal vectors to have the same number of dimensions");
assert(position_inp.extent() >= 2 && "Plane constructor requires at least 2 dimensions");

Expand Down Expand Up @@ -83,8 +83,8 @@ class Circle

Circle(const ViewCArrayKokkos<double>& position_inp, const ViewCArrayKokkos<double>& normal_inp, const double radius_inp){

assert(position_inp.order() = 1 && "Circle constructor requires a 1D ViewCArrayKokkos<double> for position");
assert(normal_inp.order() = 1 && "Circle constructor requires a 1D ViewCArrayKokkos<double> for normal");
assert(position_inp.order() == 1 && "Circle constructor requires a 1D ViewCArrayKokkos<double> for position");
assert(normal_inp.order() == 1 && "Circle constructor requires a 1D ViewCArrayKokkos<double> for normal");
assert(position_inp.extent() == normal_inp.extent() && "Circle constructor requires the position and normal vectors to have the same number of dimensions");
assert(radius_inp > 0.0 && "Circle constructor requires a positive radius");
assert(position_inp.extent() >= 2 && "Circle constructor requires at least 2 dimensions");
Expand Down Expand Up @@ -152,7 +152,7 @@ class Sphere

Sphere(const ViewCArrayKokkos<double>& position_inp, const double radius_inp){

assert(position_inp.order() = 1 && "Sphere constructor requires a 1D ViewCArrayKokkos<double> for position");
assert(position_inp.order() == 1 && "Sphere constructor requires a 1D ViewCArrayKokkos<double> for position");
assert(radius_inp > 0.0 && "Sphere constructor requires a positive radius");
assert(position_inp.extent() == 3 && "Sphere constructor requires a 3D ViewCArrayKokkos<double> for position");

Expand Down
Loading