From abb6d2e5b56a97b2464933de6becdf04c09ece81 Mon Sep 17 00:00:00 2001 From: Leonardo Carreras Date: Tue, 11 Jun 2024 00:05:38 +0200 Subject: [PATCH] Fix rocky workflow due to changes in the profiling Signed-off-by: Leonardo Carreras --- .github/workflows/build_test_linux_rocky.yaml | 50 +---------------- .../build_test_linux_rocky_profiling.yaml | 54 +++++++++++++++++++ .../workflows/run_and_profile_example.yaml | 2 +- 3 files changed, 56 insertions(+), 50 deletions(-) create mode 100644 .github/workflows/build_test_linux_rocky_profiling.yaml diff --git a/.github/workflows/build_test_linux_rocky.yaml b/.github/workflows/build_test_linux_rocky.yaml index 8de5bd0df7..7223e87e00 100644 --- a/.github/workflows/build_test_linux_rocky.yaml +++ b/.github/workflows/build_test_linux_rocky.yaml @@ -62,52 +62,4 @@ jobs: - name: Build every target shell: bash working-directory: ${{ github.workspace }}/build - run: cmake --build . --parallel $(nproc) - - - profiling: - name: Build with Profiling options - runs-on: ubuntu-latest - container: sogno/dpsim:dev-rocky - steps: - - name: Checkout - uses: actions/checkout@v4 - with: - submodules: recursive - - - name: Create Build Environment - run: mkdir build - - - name: Cache build directory - uses: actions/cache@v4 - with: - path: ${{ github.workspace }}/build - key: build-cache-rocky-profiling-${{ github.ref }} - - - name: Configure CMake - shell: bash - working-directory: ${{ github.workspace }}/build - run: cmake $GITHUB_WORKSPACE -DWITH_PROFILING=ON -DWITH_ASAN=ON -DWITH_CUDA=OFF -DFETCH_SPDLOG=ON - - - name: Build every target - shell: bash - working-directory: ${{ github.workspace }}/build - run: cmake --build . --parallel $(nproc) - - -## Tests ## - test-examples-1: - name: Test Examples 1/2 - needs: [profiling] - uses: sogno-platform/dpsim/.github/workflows/run_and_profile_example.yaml@master - with: - path: ./build/dpsim/examples/cxx/WSCC_9bus_mult_decoupled - name: WSCC_9bus_mult_decoupled - - test-examples-2: - name: Test Examples 2/2 - needs: [profiling] - uses: sogno-platform/dpsim/.github/workflows/run_and_profile_example.yaml@master - with: - path: ./build/dpsim/examples/cxx/WSCC_9bus_mult_coupled - name: WSCC_9bus_mult_coupled + run: cmake --build . --parallel $(nproc) \ No newline at end of file diff --git a/.github/workflows/build_test_linux_rocky_profiling.yaml b/.github/workflows/build_test_linux_rocky_profiling.yaml new file mode 100644 index 0000000000..1f8c02a374 --- /dev/null +++ b/.github/workflows/build_test_linux_rocky_profiling.yaml @@ -0,0 +1,54 @@ +name: Build & Test RockyLinux + +on: + workflow_dispatch: + +## Build ## + +jobs: + profiling: + name: Build with Profiling options + runs-on: ubuntu-latest + container: sogno/dpsim:dev-rocky + steps: + - name: Checkout + uses: actions/checkout@v4 + with: + submodules: recursive + + - name: Create Build Environment + run: mkdir build + + - name: Cache build directory + uses: actions/cache@v4 + with: + path: ${{ github.workspace }}/build + key: build-cache-rocky-profiling-${{ github.ref }} + + - name: Configure CMake + shell: bash + working-directory: ${{ github.workspace }}/build + run: cmake $GITHUB_WORKSPACE -DWITH_PROFILING=ON -DWITH_ASAN=ON -DWITH_CUDA=OFF -DFETCH_SPDLOG=ON + + - name: Build every target + shell: bash + working-directory: ${{ github.workspace }}/build + run: cmake --build . --parallel $(nproc) + + +## Tests ## + test-examples-1: + name: Test Examples 1/2 + needs: [profiling] + uses: sogno-platform/dpsim/.github/workflows/run_and_profile_example.yaml@${{ github.ref }} + with: + path: ./build/dpsim/examples/cxx/WSCC_9bus_mult_decoupled + name: WSCC_9bus_mult_decoupled + + test-examples-2: + name: Test Examples 2/2 + needs: [profiling] + uses: sogno-platform/dpsim/.github/workflows/run_and_profile_example.yaml@${{ github.ref }} + with: + path: ./build/dpsim/examples/cxx/WSCC_9bus_mult_coupled + name: WSCC_9bus_mult_coupled diff --git a/.github/workflows/run_and_profile_example.yaml b/.github/workflows/run_and_profile_example.yaml index aa7cd7327c..d4058ce444 100644 --- a/.github/workflows/run_and_profile_example.yaml +++ b/.github/workflows/run_and_profile_example.yaml @@ -1,7 +1,7 @@ name: Run the profiler for an example on: - workflow_dispatch: + workflow_call: inputs: path: description: 'Path to the example to be run'