Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
43 commits
Select commit Hold shift + click to select a range
3a8cfe9
refac: rename face_centered_vals -> cell_centered
rouson Oct 3, 2025
c8f1cd8
fix(gfortran): work around gfortran issues
rouson Oct 3, 2025
c1ee121
test(gradient): add 2nd line differentiation case
rouson Oct 5, 2025
14ef8f5
fix(matvec): use size() to set loop limits
rouson Oct 7, 2025
f602339
refac(test): mv code, rename function
rouson Oct 7, 2025
2ed78fc
fix(grid): rm extra multiplicative factor of dx
rouson Oct 7, 2025
fdca554
test(grad): add passing test differentiataing line
rouson Oct 7, 2025
88e3b4b
refac(cell_centers_ex): domain(:) -> x_{min,max}
rouson Oct 7, 2025
2c09eb8
feat(cell_centers_ex): add cells_ component
rouson Oct 7, 2025
478f8b1
refac(cell_centers_extended): rm grid_ component
rouson Oct 7, 2025
a5b551f
test(gradient): unit test of d(parabola)/dx passes
rouson Oct 8, 2025
bd0bb76
refac(initializers): rm abstract initializer type
rouson Oct 8, 2025
6653b8b
fix(cell_centers_extended_s): rm dead code
rouson Oct 8, 2025
aa036a8
refac(gradient_t): mv to separate module/submodule
rouson Oct 9, 2025
cbb2785
refac(cell_centers_extended_t): rename scalar_1D_t
rouson Oct 9, 2025
95054b4
refac(gradient_{t,m,s}):rename gradient_1D_{t,m,s}
rouson Oct 9, 2025
80451cf
refac(gradient_operator):name gradient_operator_1D
rouson Oct 9, 2025
46e074d
refac(mimetic_matrix}: append "_1D"
rouson Oct 9, 2025
1726150
fix(scalar_1D_s): import operators
rouson Oct 9, 2025
b9c69d6
fix(mimetic_matrix_s): count upper/lower rows
rouson Oct 9, 2025
ac815c2
refac(mimetic_matrix_s): simpler loop bound
rouson Oct 9, 2025
33bcfb8
fix(4th-order): flip some coefficient signs
rouson Oct 9, 2025
6233429
feat(mimetic_matrix_1D): add file_t constructor
rouson Oct 10, 2025
c5ad428
fix(mimetic_matrix_t): reshape upper block (A)
rouson Oct 10, 2025
ac62a7f
refac(vector): rename matrix-vector RHS scalar_1D
rouson Oct 10, 2025
79f42ba
doc(gradient_operator_1D): clarify statement label
rouson Oct 10, 2025
88e8c5e
test(order): 2nd-/4th-order accuracy tests pass
rouson Oct 10, 2025
bf84505
build(gfortran): work around concurrent type-spec
rouson Oct 11, 2025
1e0baaf
build(gfortran-14): add locality specifier macro
rouson Oct 12, 2025
9abbde7
build(gfortran): use GCC ver to define local spec
rouson Oct 12, 2025
3cc1e81
test(CI): build/test gradient-operator branch
rouson Oct 13, 2025
5a6020b
test(CI): reduce test matrix
rouson Oct 13, 2025
04a1307
Remove hard-coded checkout branch, expand version status step
bonachea Oct 16, 2025
80429ae
Expand set of OS and flang/gfortran
bonachea Oct 16, 2025
4eec9b2
Misc cleanups
bonachea Oct 17, 2025
bca8622
Add Intel Fortran coverage
bonachea Oct 17, 2025
9e8f844
Merge pull request #1 from bonachea/ci-updates
rouson Oct 20, 2025
04d4672
Merge pull request #2 from rouson/gradient-operator
rouson Nov 14, 2025
d732f34
CI: Fix FPM failures on macos-15-intel
bonachea Nov 14, 2025
4940165
CI: Use Homebrew to install gfortran 15 on Ubuntu
bonachea Nov 14, 2025
96f3ef1
CI: Fix eigen3 dependency on macOS that was breaking build-MOLE-macOSX
bonachea Nov 15, 2025
9889292
CI: Incorporate recent platform changes
bonachea Nov 19, 2025
c96dfee
Merge pull request #3 from bonachea/ci-fix-macos15
rouson Nov 22, 2025
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
215 changes: 215 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,215 @@
name: Build

on: [push, pull_request]

defaults:
run:
shell: bash

jobs:
build:
name: ${{ matrix.compiler }}-${{ matrix.version }} (${{ matrix.os }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ macos-14, macos-15, macos-15-intel, macos-26, ubuntu-24.04 ]
compiler: [ gfortran ]
version: [ 13, 14, 15 ] # Julienne supports GFortran 13+
extra_flags: [ -g -O3 ]

include:

# --- LLVM flang coverage ---

- os: macos-14
compiler: flang
version: 21
- os: macos-15
compiler: flang
version: 21

# https://hub.docker.com/r/snowstep/llvm/tags
- os: ubuntu-24.04
compiler: flang
version: latest
container: snowstep/llvm:noble
- os: ubuntu-22.04
compiler: flang
version: latest
container: snowstep/llvm:jammy

# https://hub.docker.com/r/phhargrove/llvm-flang/tags
- os: ubuntu-24.04
compiler: flang
version: 21
network: smp
container: phhargrove/llvm-flang:21.1.0-latest
- os: ubuntu-24.04
compiler: flang
version: 20
container: phhargrove/llvm-flang:20.1.0-latest
- os: ubuntu-24.04
compiler: flang
version: 19
extra_flags: -g -mmlir -allow-assumed-rank -O3
container: phhargrove/llvm-flang:19.1.1-latest

# --- Intel coverage ---

# Intel provides two docker packages with Intel Fortran.
# The first is very compact, but lacks Intel C++:
# https://hub.docker.com/r/intel/fortran-essentials/tags
# This can be used with GNU C/C++
# The second includes Intel C++ and tons of other stuff,
# hence is much larger and can lead to slower container load:
# https://hub.docker.com/r/intel/oneapi-hpckit/tags

# Julienne requires 2025.2.0 or later
- os: ubuntu-24.04
compiler: ifx-gcc
version: latest
container: intel/fortran-essentials:latest

- os: ubuntu-24.04
compiler: ifx
version: 2025.2.2
container: intel/oneapi-hpckit:2025.2.2-0-devel-ubuntu24.04

- os: ubuntu-24.04
compiler: ifx-gcc
version: 2025.2.0
container: intel/fortran-essentials:2025.2.0-0-devel-ubuntu24.04

container:
image: ${{ matrix.container }}

env:
COMPILER_VERSION: ${{ matrix.version }}
FC: ${{ matrix.compiler }}
FFLAGS: ${{ matrix.extra_flags }}
FPM_FLAGS: --profile release --verbose

steps:
- name: Checkout code
uses: actions/checkout@v5

- name: Install Ubuntu Native Dependencies
if: ${{ contains(matrix.os, 'ubuntu') && matrix.container == '' && matrix.compiler == 'gfortran' }}
run: |
set -x
sudo apt-get update
sudo apt list -a 'gfortran-*'
sudo apt install -y build-essential
if [[ ${COMPILER_VERSION} < 15 ]] ; then \
sudo apt install -y gfortran-${COMPILER_VERSION} ; \
else \
curl -L https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh -o install-homebrew.sh ; \
chmod +x install-homebrew.sh ; \
env CI=1 ./install-homebrew.sh ; \
HOMEBREW_PREFIX="/home/linuxbrew/.linuxbrew" ; \
${HOMEBREW_PREFIX}/bin/brew install -v gcc@${COMPILER_VERSION} binutils ; \
ls -al ${HOMEBREW_PREFIX}/bin ; \
echo "PATH=${HOMEBREW_PREFIX}/bin:${PATH}" >> "$GITHUB_ENV" ; \
: Homebrew GCC@15 needs binutils 2.44+ ; \
HOMEBREW_BINUTILS=$(ls -d ${HOMEBREW_PREFIX}/Cellar/binutils/2.*/bin ) ; \
ls -al ${HOMEBREW_BINUTILS} ; \
echo "FFLAGS=$FFLAGS -B ${HOMEBREW_BINUTILS}" >> "$GITHUB_ENV" ; \
echo "CFLAGS=$CFLAGS -B ${HOMEBREW_BINUTILS}" >> "$GITHUB_ENV" ; \
echo "CXXFLAGS=$CXXFLAGS -B ${HOMEBREW_BINUTILS}" >> "$GITHUB_ENV" ; \
fi

- name: Install Ubuntu Container Dependencies
if: ${{ contains(matrix.os, 'ubuntu') && matrix.container != '' && !contains(matrix.container, 'phhargrove') }}
run: |
set -x
apt update
apt install -y build-essential pkg-config make git curl

- name: Install macOS Dependencies
if: contains(matrix.os, 'macos')
run: |
set -x
brew update
# fpm binary distribution for macOS requires gfortran shared libraries from gcc@12
brew install gcc@12

- name: Install LLVM flang on macOS
if: contains(matrix.os, 'macos') && matrix.compiler == 'flang'
run: |
set -x
brew install llvm@${COMPILER_VERSION} flang
# workaround issue #228: clang cannot find homebrew flang's C header
for p in /opt/homebrew /usr/local $(brew --prefix) ; do find $p/Cellar/flang -name ISO_Fortran_binding.h 2>/dev/null || true ; done
echo "CFLAGS=-I$(dirname $(find $(brew --prefix)/Cellar/flang -name ISO_Fortran_binding.h | head -1)) ${CFLAGS}" >> "$GITHUB_ENV"
# Prepend homebrew clang to PATH:
echo "PATH=$(brew --prefix)/opt/llvm/bin:${PATH}" >> "$GITHUB_ENV"

- name: Setup Compilers
run: |
set -x
if test "$FC" = "flang" ; then \
echo "FPM_FC=flang-new" >> "$GITHUB_ENV" ; \
elif [[ "$FC" =~ "ifx" ]] ; then \
echo "FPM_FC=ifx" >> "$GITHUB_ENV" ; \
echo "FFLAGS=-fpp -coarray $FFLAGS" >> "$GITHUB_ENV" ; \
: ls -al /opt/intel/oneapi/compiler/2025.*/bin/ ; \
if type -p icpx ; then \
echo "FPM_CC=icx" >> "$GITHUB_ENV" ; \
echo "FPM_CXX=icpx" >> "$GITHUB_ENV" ; \
else \
echo "FPM_CC=gcc" >> "$GITHUB_ENV" ; \
echo "FPM_CXX=g++" >> "$GITHUB_ENV" ; \
fi ; \
elif test "$FC" = "lfortran" ; then \
echo "FPM_FC=lfortran" >> "$GITHUB_ENV" ; \
echo "FFLAGS=--cpp $FFLAGS" >> "$GITHUB_ENV" ; \
else \
echo "FPM_FC=gfortran-${COMPILER_VERSION}" >> "$GITHUB_ENV" ; \
echo "FFLAGS=-ffree-line-length-0 $FFLAGS" >> "$GITHUB_ENV" ; \
echo "FPM_CXXFLAGS=-std=c++14" >> "$GITHUB_ENV" ; : needed for Armadillo on macos-14 ; \
fi
if [[ "${{ matrix.container }}" =~ "snowstep/llvm" ]] ; then \
echo "LD_LIBRARY_PATH=/usr/lib/llvm-22/lib:$LD_LIBRARY_PATH" >> "$GITHUB_ENV" ; \
fi

- name: Setup FPM
uses: fortran-lang/setup-fpm@main
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
fpm-version: latest

- name: Build FPM
if: false
run: |
set -x
curl --retry 5 -LOsS https://github.com/fortran-lang/fpm/releases/download/v0.11.0/fpm-0.11.0.F90
mkdir fpm-temp
gfortran-14 -o fpm-temp/fpm fpm-0.11.0.F90
echo "PATH=`pwd`/fpm-temp:${PATH}" >> "$GITHUB_ENV"

- name: Version info
run: |
if test -d .git && type -p git > /dev/null ; then \
git config --global --add safe.directory `pwd` ; \
echo == Commit Info == ; \
git log -n 1 ; echo ; echo ; \
fi
echo == Platform version info ==
uname -a
if test -r /etc/os-release ; then grep -e NAME -e VERSION /etc/os-release ; fi
if test -x /usr/bin/sw_vers ; then /usr/bin/sw_vers ; fi
echo
echo PATH="$PATH"
for tool in ${FPM_FC} ${FPM_CC} ${FPM_CXX} fpm ; do
( echo ; set -x ; w=$(which $tool) ; ls -al $w ; ls -alhL $w ; $tool --version )
done


- name: Build and Test
run: |
set -x
echo "FPM_FLAGS=${FPM_FLAGS}"
echo "FFLAGS=$FFLAGS"
ls -lt
fpm test ${FPM_FLAGS} --flag "$FFLAGS"
4 changes: 3 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ jobs:
- name: Install dependencies
run: |
brew update && (brew list cmake || brew install cmake)
brew install openblas eigen libomp lapack
brew install openblas eigen@3 libomp lapack
sudo ln -sf /opt/homebrew/bin/gfortran-14 /opt/homebrew/bin/gfortran

- name: Export Environment Variables
Expand All @@ -94,6 +94,8 @@ jobs:
export CPPFLAGS+=" -I/opt/homebrew/opt/lapack/include"
export PKG_CONFIG_PATH+=" /opt/homebrew/opt/lapack/lib/pkgconfig"

echo "Eigen3_DIR=/opt/homebrew/opt/eigen@3/share/eigen3/cmake" >> "$GITHUB_ENV"

- name: Create build directory
run: mkdir -p build

Expand Down
13 changes: 8 additions & 5 deletions include/mole-language-support.F90
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,12 @@
#ifndef MOLE_LANGUAGE_SUPPORT
#define MOLE_LANGUAGE_SUPPORT


#ifdef __GNUC__
# define GCC_VERSION (__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__)
#else
# define GCC_VERSION 0
#endif

#if __GNUC__ && ( __GNUC__ < 14 || (__GNUC__ == 14 && __GNUC_MINOR__ < 3) )
#define GCC_GE_MINIMUM
#endif

#ifndef HAVE_DO_CONCURRENT_TYPE_SPEC_SUPPORT
# if defined(_CRAYFTN) || defined(__INTEL_COMPILER) || defined(NAGFOR) || defined(__flang__)
# define HAVE_DO_CONCURRENT_TYPE_SPEC_SUPPORT 1
Expand All @@ -23,4 +18,12 @@
# endif
#endif

#ifndef HAVE_LOCALITY_SPECIFIER_SUPPORT
# if defined(NAGFOR) || defined(__flang__) || defined(__INTEL_COMPILER) || defined(_CRAYFTN) || (GCC_VERSION >= 150100)
# define HAVE_LOCALITY_SPECIFIER_SUPPORT 1
# else
# define HAVE_LOCALITY_SPECIFIER_SUPPORT 0
# endif
#endif

#endif
114 changes: 0 additions & 114 deletions src/fortran/face_values_m.f90

This file was deleted.

15 changes: 0 additions & 15 deletions src/fortran/face_values_s.F90

This file was deleted.

Loading