name: "Component CI: StinkyTofu" on: workflow_call: inputs: docker_image: type: string required: true linux_runner: type: string required: true windows_runner: type: string required: true permissions: contents: read jobs: linux: name: Linux runs-on: ${{ inputs.linux_runner }} container: image: ${{ inputs.docker_image }} env: ROCM_PATH: /opt/rocm defaults: run: working-directory: shared/stinkytofu steps: - name: Checkout repository uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - name: Setup ROCm uses: ./.github/actions/setup-rocm-linux with: amdgpu_family: gfx94X-dcgpu - name: Install Python dependencies run: pip install -r requirements.txt - name: Build (GCC) run: invoke build --gcc --build-dir build_gcc --clean - name: Build run: invoke build - name: Debug stinkytofu-opt working-directory: shared/stinkytofu/build run: | ldd tools/stinkytofu-opt/stinkytofu-opt ./tools/stinkytofu-opt/stinkytofu-opt --list-passes - name: Test working-directory: shared/stinkytofu/build run: ctest --output-on-failure - name: Test pip install uses: ./.github/actions/pip-install-test with: package_path: shared/stinkytofu test_path: python_module/tests windows: name: Windows runs-on: ${{ inputs.windows_runner }} env: BUILD_DIR: B:\build defaults: run: shell: bash working-directory: shared/stinkytofu steps: - name: Configure git long paths working-directory: . run: git config --global core.longpaths true - name: Checkout repository uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - name: Set up Python uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0 with: python-version: "3.12" - name: Setup ROCm uses: ./.github/actions/setup-rocm-windows with: amdgpu_family: gfx1151 - name: Install Python dependencies run: pip install -r requirements.txt - name: Install GTest run: vcpkg install gtest - name: Build run: invoke build --build-dir "${{ env.BUILD_DIR }}/stinkytofu" - name: Test working-directory: ${{ env.BUILD_DIR }}/stinkytofu run: ctest --output-on-failure - name: Build (static) run: invoke build --static --build-dir "${{ env.BUILD_DIR }}/stinkytofu-static" --clean - name: Test (static) working-directory: ${{ env.BUILD_DIR }}/stinkytofu-static run: ctest --output-on-failure - name: Test pip install uses: ./.github/actions/pip-install-test with: package_path: shared/stinkytofu test_path: python_module/tests