diff --git a/.github/workflows/frontier/install.sh b/.github/workflows/frontier/install.sh new file mode 100644 index 000000000..806f5bb19 --- /dev/null +++ b/.github/workflows/frontier/install.sh @@ -0,0 +1,20 @@ +#!/bin/bash -e + +module load PrgEnv-amd + +branch=$1 +cd /lustre/orion/phy122/scratch/castia5/globus-compute/core-test + +# Core +rm build-core -rf +rm core -rf +git clone https://github.com/SCOREC/core.git +cd core && git checkout $branch && git clone https://github.com/SCOREC/pumi-meshes.git && cd - +cmake -S core -B build-core \ + -DCMAKE_C_COMPILER=cc \ + -DCMAKE_CXX_COMPILER=CC \ + -DENABLE_ZOLTAN=OFF \ + -DMPIRUN=/usr/bin/srun \ + -DMPIRUN_PROCFLAG="--ntasks" \ + -DIS_TESTING=True +cmake --build build-core -j 24 \ No newline at end of file diff --git a/.github/workflows/frontier/run.sh b/.github/workflows/frontier/run.sh new file mode 100644 index 000000000..35fe1e7a0 --- /dev/null +++ b/.github/workflows/frontier/run.sh @@ -0,0 +1,11 @@ +#!/bin/bash + +name=core + +cd /lustre/orion/phy122/scratch/castia5/globus-compute/$name-test + +module load PrgEnv-amd + +cd build-$name +salloc --account=PHY122 --time=00:20:00 -q debug --nodes=1 --ntasks=1 --cpus-per-task=1 --gpus-per-task=1 --gpus=1 ctest +cat $PWD/Testing/Temporary/LastTest.log \ No newline at end of file diff --git a/.github/workflows/globus-test.yml b/.github/workflows/globus-test.yml new file mode 100644 index 000000000..17bcd301e --- /dev/null +++ b/.github/workflows/globus-test.yml @@ -0,0 +1,19 @@ +name: Globus-Systems +on: + schedule: + # Monday 7:35 UTC or 03:35 EDT + - cron: '35 7 * * 1' + +jobs: + + perlmutter-test: + uses: SCOREC/github-actions/.github/workflows/globus-test.yml@main + secrets: inherit + with: + machine: "perlmutter" + + frontier-test: + uses: SCOREC/github-actions/.github/workflows/globus-test.yml@main + secrets: inherit + with: + machine: "frontier" \ No newline at end of file diff --git a/.github/workflows/perlmutter/install.sh b/.github/workflows/perlmutter/install.sh new file mode 100644 index 000000000..9f1c97bea --- /dev/null +++ b/.github/workflows/perlmutter/install.sh @@ -0,0 +1,19 @@ +#!/bin/bash -e + +branch=$1 + +cd $SCRATCH/globus-compute/core-test + +# core +rm build-core -rf +rm core -rf +git clone https://github.com/SCOREC/core.git +cd core && git checkout $branch && git clone https://github.com/SCOREC/pumi-meshes.git && cd - +cmake -S core -B build-core \ + -DCMAKE_C_COMPILER=cc \ + -DCMAKE_CXX_COMPILER=CC \ + -DENABLE_ZOLTAN=OFF \ + -DMPIRUN=/usr/bin/srun \ + -DMPIRUN_PROCFLAG="--ntasks" \ + -DIS_TESTING=True +cmake --build build-core -j 24 \ No newline at end of file diff --git a/.github/workflows/perlmutter/run.sh b/.github/workflows/perlmutter/run.sh new file mode 100644 index 000000000..a2b68c081 --- /dev/null +++ b/.github/workflows/perlmutter/run.sh @@ -0,0 +1,9 @@ +#!/bin/bash + +name=core + +cd $SCRATCH/globus-compute/$name-test + +cd build-$name +salloc --time 00:20:00 --constrain=gpu --qos=interactive --nodes=1 --ntasks-per-node=40 --cpus-per-task=1 --gpus=1 --account=m4564 ctest +cat $PWD/Testing/Temporary/LastTest.log \ No newline at end of file diff --git a/.github/workflows/systems.yml b/.github/workflows/systems.yml deleted file mode 100644 index 292968d9e..000000000 --- a/.github/workflows/systems.yml +++ /dev/null @@ -1,63 +0,0 @@ -name: Systems -on: - schedule: - # Monday 4:30 UTC or 00:30 EDT - - cron: '30 4 * * 1' - -concurrency: - group: systems-core - cancel-in-progress: true - -jobs: - test: - runs-on: ubuntu-latest - timeout-minutes: 30 - strategy: - matrix: - machine: ["Perlmutter", "Frontier"] - - steps: - - - name: checkout core - uses: actions/checkout@v4 - with: - path: core - - - name: setup python - uses: actions/setup-python@v5 - with: - python-version: '3.10' - - - name: install packing - run: sudo apt install python3-packaging - - - name: install globus - run: | - python -m ensurepip --upgrade --user - python -m pip install globus-compute-endpoint - - - name: use globus - working-directory: core/.github/workflows - env: - GLOBUS_ID: ${{ secrets.GLOBUS_COMPUTE_ID }} - GLOBUS_SECRET: ${{ secrets.GLOBUS_COMPUTE_SECRET }} - run: | - export GLOBUS_COMPUTE_CLIENT_ID="$GLOBUS_ID" - export GLOBUS_COMPUTE_CLIENT_SECRET="$GLOBUS_SECRET" - if [ ${{matrix.machine}} == Perlmutter ]; then TARGET_ENDPOINT=0dd4499a-8d76-4977-bae9-841e4bb2f616; fi - if [ ${{matrix.machine}} == Frontier ]; then TARGET_ENDPOINT=d625c6cf-de7a-4228-ac44-56247a642fe0; fi - python test_on_system.py ${{ github.event.repository.name }} ${{ github.sha }} $TARGET_ENDPOINT - - - name: print build log - working-directory: core/.github/workflows - run: cat core-result/Build.log - - - name: print test log - working-directory: core/.github/workflows - run: cat core-result/Test.log - - - name: check failed test - working-directory: core/.github/workflows - run: if grep "Failed" core-result/Test.log; then return 1; fi - - \ No newline at end of file diff --git a/.github/workflows/test_on_system.py b/.github/workflows/test_on_system.py deleted file mode 100644 index 1c1f6d539..000000000 --- a/.github/workflows/test_on_system.py +++ /dev/null @@ -1,38 +0,0 @@ -# How to use -# 1. Login to https://app.globus.org/settings/developers and copy a project app id and secret -# 2. Use the id and secret to create and endpoint https://funcx.readthedocs.io/en/latest/sdk.html#client-credentials-with-clients -# $ export FUNCX_SDK_CLIENT_ID="b0500dab-ebd4-430f-b962-0c85bd43bdbb" -# $ export FUNCX_SDK_CLIENT_SECRET="ABCDEFGHIJKLMNOP0123456789=" -# 3. Set up an endpoint on the computer that will run the tests, using these instructions: https://funcx.readthedocs.io/en/latest/endpoints.html -# 4. Create install-test.sh and run-test.sh on target computer - -from globus_compute_sdk import Executor -import sys -import os - -name = sys.argv[1] -branch = sys.argv[2] -endpoint = sys.argv[3] - -def run_on_endpoint(name, branch): - import subprocess - - install = subprocess.run(["./install-test.sh "+name+" "+branch], shell=True, encoding="utf_8", stdout=subprocess.PIPE, stderr=subprocess.STDOUT) - if install.returncode == 1: - return (install, None) - - result = subprocess.run(["./run-test.sh "+name], shell=True, encoding="utf_8", stdout=subprocess.PIPE, stderr=subprocess.STDOUT) - return (install, result) - -gce = Executor(endpoint_id = endpoint) -future = gce.submit(run_on_endpoint, name, branch) -result = future.result() - -os.popen("mkdir -p "+name+"-result").read() -with open(name+"-result/Build.log", "w") as text_file: - text_file.write("%s" % result[0].stdout) - text_file.close() -if result[0].returncode == 0: - with open(name+"-result/Test.log", "w") as text_file: - text_file.write("%s" % result[1].stdout) - text_file.close() diff --git a/CMakeLists.txt b/CMakeLists.txt index 105d6df1a..1e4ed553b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -6,7 +6,7 @@ endif() # This is the top level CMake file for the SCOREC build cmake_minimum_required(VERSION 3.8) -project(SCOREC VERSION 2.2.9 LANGUAGES CXX C) +project(SCOREC VERSION 2.2.10 LANGUAGES CXX C) include(cmake/bob.cmake) include(cmake/xsdk.cmake)