yum-mirror/slang

Making it easier to work with shaders

git clone https://git.yummers.dev/yum-mirror/slang

kaizhangNVDNI: try using sparse checkout for MDL-SDK (#6190)1f1892d03

master
2.4 KiB65 linesraw
1name: Push MDL Benchmark Results
2
3on:
4  push:
5    branches: [master]
6    paths-ignore:
7      - "docs/**"
8      - "LICENSES/**"
9      - "LICENSE"
10      - "CONTRIBUTING.md"
11      - "README.md"
12concurrency:
13  group: ${{ github.workflow }}-${{ github.ref }}
14  cancel-in-progress: true
15
16jobs:
17  build:
18    runs-on: [Windows, benchmark, self-hosted]
19    steps:
20      - uses: actions/checkout@v4
21        with:
22          submodules: "true"
23          fetch-depth: "0"
24      - name: Common setup
25        uses: ./.github/actions/common-setup
26        with:
27          os: windows
28          compiler: cl
29          platform: x86_64
30          config: release
31          build-llvm: true
32      - name: Build Slang
33        run: |
34          cmake --preset default --fresh -DSLANG_SLANG_LLVM_FLAVOR=USE_SYSTEM_LLVM -DCMAKE_COMPILE_WARNING_AS_ERROR=false
35          cmake --workflow --preset release
36      - uses: actions/checkout@v4
37        with:
38          repository: "shader-slang/MDL-SDK"
39          path: "external/MDL-SDK"
40          sparse-checkout: |
41            ./examples/mdl_sdk/dxr/content/slangified
42      - name: Run benchmark
43        run: |
44          cd tools/benchmark
45          cp ../../external/MDL-SDK/examples/mdl_sdk/dxr/content/slangified/*.slang .
46          pip install prettytable argparse
47          python compile.py --samples 16 --target dxil
48      - uses: actions/checkout@v4
49        with:
50          repository: "shader-slang/slang-material-modules-benchmark"
51          path: "external/slang-material-modules-benchmark"
52          token: ${{ secrets.SLANG_MDL_BENCHMARK_RESULTS_PAT }}
53      - name: Push results
54        run: |
55          cp tools/benchmark/benchmarks.json external\slang-material-modules-benchmark
56          echo $(Invoke-Expression "git log -1 --pretty=%s") > external\slang-material-modules-benchmark\commit
57          echo $(Invoke-Expression "git log -1 --pretty=%H") > external\slang-material-modules-benchmark\commit-hash
58          echo $(Invoke-Expression "git log -1 --pretty=%s") > external\slang-material-modules-benchmark\current
59          echo $(Invoke-Expression "git log -1 --pretty=%H") >> external\slang-material-modules-benchmark\current
60          cd external\slang-material-modules-benchmark
61          ls
62          git add benchmarks.json current
63          git commit -m "$(cat commit)" -m "https://github.com/shader-slang/slang/commit/$(cat commit-hash)"
64          git log
65          git push