From d76bd030595e3d83e2134ce2a9c57276a39d3df0 Mon Sep 17 00:00:00 2001 From: silverqx Date: Fri, 12 Apr 2024 16:40:07 +0200 Subject: [PATCH] t --- .github/workflows/analyzers.yml | 25 +++++++++++++---- .github/workflows/linux-qt6-drivers.yml | 37 +++++++++++++++++-------- .github/workflows/vcpkg-linux.yml | 24 ++++++++++++---- 3 files changed, 62 insertions(+), 24 deletions(-) diff --git a/.github/workflows/analyzers.yml b/.github/workflows/analyzers.yml index 3825befd5..53e3d3a45 100644 --- a/.github/workflows/analyzers.yml +++ b/.github/workflows/analyzers.yml @@ -1,11 +1,17 @@ name: Clang-Tidy and Clazy Qt5.15/6.7 -on: - push: - branches: - - main - - gh-actions - - silverqx-develop +# Invoke manually from the command-line using the gh command, eg.: +# gh workflow run --ref silverqx-develop +# The reason for this is that I have 2 self-hosted runners on one PC (one for Linux and other for +# Windows) and I'm not able to serialize all these workflows and because of that I would have to +# decrease parallel and it would take hours to finish, so all Linux workflows must be invoked +# manually. +on: workflow_dispatch +# on: +# push: +# branches: +# - main +# - gh-actions concurrency: group: tinyorm-linux @@ -46,6 +52,13 @@ jobs: [[ "${{ runner.name }}" == 'merydeye-'* ]] && isSelfHostedRunner='true' || isSelfHostedRunner='false' echo "TinyIsSelfHostedRunner=$isSelfHostedRunner" >> $GITHUB_ENV + # Parallel 4 ISN't maximum but because this workflow runs hours I will use parallel 4 to be + # able continue working on my PC, also, I decided to use the different strategy, I will use + # the on: workflow_dispatch for all Linux GitHub Actions and will invoke these workflows + # manually from the command-line using the gh command, eg.: + # gh workflow run --ref silverqx-develop + # -- + # The below is Outdated but I leave the comment. [[ "$isSelfHostedRunner" == 'true' ]] && parallel=4 || parallel=2 echo "TinyParallel=$parallel" >> $GITHUB_ENV diff --git a/.github/workflows/linux-qt6-drivers.yml b/.github/workflows/linux-qt6-drivers.yml index a17a28015..7124f033c 100644 --- a/.github/workflows/linux-qt6-drivers.yml +++ b/.github/workflows/linux-qt6-drivers.yml @@ -6,12 +6,18 @@ name: Linux GCC/Clang Qt6.7 TinyDrivers -on: - push: - branches: - - main - - gh-actions - - silverqx-develop +# Invoke manually from the command-line using the gh command, eg.: +# gh workflow run --ref silverqx-develop +# The reason for this is that I have 2 self-hosted runners on one PC (one for Linux and other for +# Windows) and I'm not able to serialize all these workflows and because of that I would have to +# decrease parallel and it would take hours to finish, so all Linux workflows must be invoked +# manually. +on: workflow_dispatch +# on: +# push: +# branches: +# - main +# - gh-actions concurrency: group: tinyorm-linux @@ -30,20 +36,21 @@ jobs: strategy: matrix: - drivers-type: [Shared, Loadable] + drivers-type: [Shared] + # drivers-type: [Shared, Loadable] build-type: - key: debug name: Debug - - key: release - name: Release + # - key: release + # name: Release compiler: - key: clang18 command: clang++-18 - - key: gcc13 - command: g++-13 + # - key: gcc13 + # command: g++-13 steps: - uses: actions/checkout@v4 @@ -55,13 +62,19 @@ jobs: runnerWorkPath=$(realpath '${{ runner.workspace }}/..') echo "TinyRunnerWorkPath=$runnerWorkPath" >> $GITHUB_ENV + # Parallel gcc to 3 and clang to 8 is maximum what my computer allows but I decided to use + # the different strategy, I will use the on: workflow_dispatch for all Linux GitHub Actions + # and will invoke these workflows manually from the command-line using the gh command, eg.: + # gh workflow run --ref silverqx-develop + # -- + # The below is Outdated but I leave the comment. # For gcc13 with the parallel 4 I saw 15.1GB maximum memory usage from 15.6GB and that is # very close to the edge, so I have to decrease it to 3. # For clang18 it was ~11.6 from 15.6GB so parallel 8 is ok. # I must divide all parallel by 2 because I have 2 self-hosted runners on the same computer # and also -1 for reserve to avoid swapping, so for clang: 8 / 2 - 1 = 3 and for gcc: # 3 / 2 - 1 = 1. - parallel=${{ matrix.compiler.key == 'gcc13' && '1' || '3' }} + parallel=${{ matrix.compiler.key == 'gcc13' && '3' || '8' }} echo "TinyParallel=$parallel" >> $GITHUB_ENV tinyormPath=$(realpath ./main) diff --git a/.github/workflows/vcpkg-linux.yml b/.github/workflows/vcpkg-linux.yml index 2c835adb0..4d81b0a2b 100644 --- a/.github/workflows/vcpkg-linux.yml +++ b/.github/workflows/vcpkg-linux.yml @@ -4,12 +4,18 @@ name: Vcpkg Linux -on: - push: - branches: - - main - - gh-actions - - silverqx-develop +# Invoke manually from the command-line using the gh command, eg.: +# gh workflow run --ref silverqx-develop +# The reason for this is that I have 2 self-hosted runners on one PC (one for Linux and other for +# Windows) and I'm not able to serialize all these workflows and because of that I would have to +# decrease parallel and it would take hours to finish, so all Linux workflows must be invoked +# manually. +on: workflow_dispatch +# on: +# push: +# branches: +# - main +# - gh-actions concurrency: group: tinyorm-linux @@ -71,6 +77,12 @@ jobs: [[ "${{ runner.name }}" == 'merydeye-'* ]] && isSelfHostedRunner='true' || isSelfHostedRunner='false' echo "TinyIsSelfHostedRunner=$isSelfHostedRunner" >> $GITHUB_ENV + # Parallel gcc to 3 and clang to 8 is maximum what my computer allows but I decided to use + # the different strategy, I will use the on: workflow_dispatch for all Linux GitHub Actions + # and will invoke these workflows manually from the command-line using the gh command, eg.: + # gh workflow run --ref silverqx-develop + # -- + # The below is Outdated but I leave the comment. # I must divide all parallel by 2 because I have 2 self-hosted runners on the same computer # and also -1 for reserve to avoid swapping, so 10 / 2 - 1 = 4 [[ "$isSelfHostedRunner" == 'true' ]] && parallel=4 || parallel=2