Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
62 changes: 34 additions & 28 deletions .github/workflows/generated-bindings-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,10 @@ jobs:
compiler: gcc
v-channel: master
v-version: master
- os: ubuntu-24.04
compiler: gcc
v-channel: v3
v-version: 5ff8ecb55f6709fd7e6f645ef7779383f30c47c0
- os: macos-14
compiler: clang
v-channel: stable
Expand All @@ -99,36 +103,36 @@ jobs:
ref: 2700e4f4c58e9e625657b80f4f44b0584d7c6096
path: generator
- uses: prantlf/setup-v-action@v4
if: matrix.v-channel != 'master'
if: matrix.v-channel == 'stable'
with:
version: ${{ matrix.v-version }}
# V master currently builds a separate v1_fallback executable for tool
# commands such as `v test`. Keep the complete source build together;
# setup-v-action@v4's reduced cache bundle omits that executable.
- name: Check out V master
if: matrix.v-channel == 'master'
# Source-built V revisions include the v1_fallback executable needed by
# tool commands such as `v test`; setup-v-action@v4 omits it from cache.
- name: Check out source-built V
if: matrix.v-channel != 'stable'
uses: actions/checkout@v7
id: checkout_v_master
continue-on-error: true
id: checkout_v_source
continue-on-error: ${{ matrix.v-channel == 'master' }}
with:
repository: vlang/v
path: .ci-v-master
ref: ${{ matrix.v-version }}
path: .ci-v-source
fetch-depth: 1
- name: Build V master
if: matrix.v-channel == 'master' && steps.checkout_v_master.outcome == 'success'
id: setup_v_master
continue-on-error: true
- name: Build source V compiler
if: matrix.v-channel != 'stable' && steps.checkout_v_source.outcome == 'success'
id: setup_v_source
continue-on-error: ${{ matrix.v-channel == 'master' }}
shell: bash
run: |
make -C .ci-v-master
echo "$GITHUB_WORKSPACE/.ci-v-master" >> "$GITHUB_PATH"
.ci-v-master/v -V
make -C .ci-v-source
echo "$GITHUB_WORKSPACE/.ci-v-source" >> "$GITHUB_PATH"
.ci-v-source/v -V
- name: Install Vulkan SDK and SwiftShader test artifacts
if: matrix.v-channel != 'master' || steps.setup_v_master.outcome == 'success'
if: matrix.v-channel == 'stable' || steps.setup_v_source.outcome == 'success'
shell: bash
run: bash .github/scripts/setup-vulkan-ci.sh 1.4.309.0 v1.2
- name: Install registry-matched headers and pinned Volk
if: matrix.v-channel != 'master' || steps.setup_v_master.outcome == 'success'
if: matrix.v-channel == 'stable' || steps.setup_v_source.outcome == 'success'
shell: bash
run: |
set -euo pipefail
Expand All @@ -151,11 +155,11 @@ jobs:
"https://raw.githubusercontent.com/zeux/volk/$volk_commit/volk.c" \
--output "$VULKAN_SDK/include/volk/volk.c"
- name: Verify the public setup diagnostics
if: matrix.v-channel != 'master' || steps.setup_v_master.outcome == 'success'
if: matrix.v-channel == 'stable' || steps.setup_v_source.outcome == 'success'
shell: bash
run: v run setup.vsh --check
- name: Assemble isolated module
if: matrix.v-channel != 'master' || steps.setup_v_master.outcome == 'success'
if: matrix.v-channel == 'stable' || steps.setup_v_source.outcome == 'success'
shell: bash
run: |
set -euo pipefail
Expand All @@ -169,17 +173,19 @@ jobs:
echo "VMODULES=$RUNNER_TEMP/vmodules" >> "$GITHUB_ENV"
- name: Compile smoke test and ergonomic unit tests
id: compile
if: matrix.v-channel != 'master' || steps.setup_v_master.outcome == 'success'
continue-on-error: ${{ matrix.v-channel == 'master' }}
if: matrix.v-channel == 'stable' || steps.setup_v_source.outcome == 'success'
continue-on-error: ${{ matrix.v-channel != 'stable' }}
shell: bash
run: |
set -euo pipefail
v_flags=(-cc "${{ matrix.compiler }}")
if [[ "${{ matrix.v-channel }}" == v3 ]]; then v_flags=(-new-compiler "${v_flags[@]}"); fi
if [[ "${{ runner.os }}" == macOS ]]; then
v -cc "${{ matrix.compiler }}" -o "$RUNNER_TEMP/vulkan-smoke" generator/test
v "${v_flags[@]}" -o "$RUNNER_TEMP/vulkan-smoke" generator/test
else
v -cc "${{ matrix.compiler }}" run generator/test
v "${v_flags[@]}" run generator/test
fi
v -cc "${{ matrix.compiler }}" test ergonomic
v "${v_flags[@]}" test ergonomic
- name: Validate TinyCC loader and ergonomic API
if: runner.os == 'Linux' && matrix.v-channel == 'stable'
shell: bash
Expand All @@ -188,9 +194,9 @@ jobs:
v -cc tcc test ergonomic
VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation \
v -cc tcc run examples/ergonomic_lifecycle
- name: Report V master compatibility warning
if: always() && matrix.v-channel == 'master' && (steps.checkout_v_master.outcome == 'failure' || steps.setup_v_master.outcome == 'failure' || steps.compile.outcome == 'failure')
run: echo "::warning::The live V master compatibility lane failed; stable V 0.5.2 remains authoritative."
- name: Report source compiler compatibility warning
if: always() && matrix.v-channel != 'stable' && (steps.checkout_v_source.outcome == 'failure' || steps.setup_v_source.outcome == 'failure' || steps.compile.outcome == 'failure')
run: echo "::warning::The ${{ matrix.v-channel }} compatibility lane failed; stable V 0.5.2 remains authoritative."
- name: Run lifecycle under validation
if: runner.os == 'Linux' && matrix.v-channel == 'stable'
shell: bash
Expand Down
2 changes: 1 addition & 1 deletion c/volk.c.v
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ module c
#define VK_NO_PROTOTYPES
#define VOLK_IMPLEMENTATION
#include <volk.h>
#include "loader_bridge.h"
#include "@VMODROOT/c/loader_bridge.h"
Loading