From ea43b29ee70e61b1ff8fd4d20b1a6f34023cba32 Mon Sep 17 00:00:00 2001 From: Jake Shadle Date: Mon, 5 Feb 2024 15:02:43 +0100 Subject: [PATCH 01/12] Update to spirv-tools 0.10.0 --- Cargo.lock | 8 ++++---- crates/rustc_codegen_spirv/Cargo.toml | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index dfdb60c6f0..252d22e370 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2491,9 +2491,9 @@ version = "0.9.0" [[package]] name = "spirv-tools" -version = "0.9.0" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc7c8ca2077515286505bd3ccd396e55ac5706e80322e1d6d22a82e1cad4f7c3" +checksum = "bcb3b0832881834994b7ec82b709ec5491043ceb4bf8101e27da6b5234b24261" dependencies = [ "memchr", "spirv-tools-sys", @@ -2502,9 +2502,9 @@ dependencies = [ [[package]] name = "spirv-tools-sys" -version = "0.7.0" +version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4b32d9d6469cd6b50dcd6bd841204b5946b4fb7b70a97872717cdc417659c9a" +checksum = "48e68b55a97aa6856e010a6f2477425875a97873e147bb0232160e73c45bdae7" dependencies = [ "cc", ] diff --git a/crates/rustc_codegen_spirv/Cargo.toml b/crates/rustc_codegen_spirv/Cargo.toml index 4b94d02edf..bc9cce2bcf 100644 --- a/crates/rustc_codegen_spirv/Cargo.toml +++ b/crates/rustc_codegen_spirv/Cargo.toml @@ -56,7 +56,7 @@ sanitize-filename = "0.4" serde = { version = "1.0", features = ["derive"] } serde_json = "1.0" smallvec = { version = "1.6.1", features = ["union"] } -spirv-tools = { version = "0.9", default-features = false } +spirv-tools = { version = "0.10", default-features = false } rustc_codegen_spirv-types.workspace = true spirt = "0.3.0" lazy_static = "1.4.0" From 09170ee37456c6717c83c39a7d95016c8a1762e2 Mon Sep 17 00:00:00 2001 From: Jake Shadle Date: Mon, 5 Feb 2024 15:02:55 +0100 Subject: [PATCH 02/12] Use pre-built binaries from spirv-tools-rs --- .github/install-tools/Cargo.toml | 8 +++ .github/install-tools/src/main.rs | 109 ++++++++++++++++++++++++++++++ .github/workflows/ci.yaml | 60 ++++------------ 3 files changed, 130 insertions(+), 47 deletions(-) create mode 100644 .github/install-tools/Cargo.toml create mode 100644 .github/install-tools/src/main.rs diff --git a/.github/install-tools/Cargo.toml b/.github/install-tools/Cargo.toml new file mode 100644 index 0000000000..1c77e39287 --- /dev/null +++ b/.github/install-tools/Cargo.toml @@ -0,0 +1,8 @@ +[package] +name = "install-tools" +edition = "2021" +publish = false + +[dependencies] +tar = "0.4" +zstd = "0.13" diff --git a/.github/install-tools/src/main.rs b/.github/install-tools/src/main.rs new file mode 100644 index 0000000000..fca33f562a --- /dev/null +++ b/.github/install-tools/src/main.rs @@ -0,0 +1,109 @@ +use std::{env, fs, io::Write as _, process::Command}; + +struct Group(bool); + +impl Group { + fn new(group: &str) -> Self { + let is_gh = env::var_os("CI").is_some(); + if is_gh { + println!("::group::{group}"); + } else { + println!("{group}"); + } + Self(is_gh) + } +} + +impl Drop for Group { + fn drop(&mut self) { + if self.0 { + println!("::endgroup::"); + } + } +} + +fn main() { + let (triple, release, td) = { + let mut args = env::args().skip(1); + let triple = args.next().expect("expected target triple"); + let release = args.next().expect("expected release tag name"); + let td = args.next().expect("expected output directory"); + + (triple, release, td) + }; + + let compressed = { + let _s = Group::new(&format!("downloading {triple} tarball")); + let mut cmd = Command::new("curl"); + cmd.args(["-f", "-L"]) + .arg(format!("https://github.com/EmbarkStudios/spirv-tools-rs/releases/download/{release}/{triple}.tar.zst")) + .stdout(std::process::Stdio::piped()); + + let output = cmd + .spawn() + .expect("curl is not installed") + .wait_with_output() + .expect("failed to wait for curl"); + + if !output.status.success() { + panic!("failed to download tarball via curl"); + } + + output.stdout + }; + + let decoded = { + let _s = Group::new(&format!("decompressing {triple} tarball")); + // All archives are <8MiB decompressed + let uncompressed = Vec::with_capacity(8 * 1024 * 1024); + let mut decoder = + zstd::stream::write::Decoder::new(uncompressed).expect("failed to create decoder"); + decoder + .write_all(&compressed) + .expect("failed to decompress"); + decoder.flush().expect("failed to flush decompress stream"); + + decoder.into_inner() + }; + + { + let _s = Group::new(&format!("untarring {triple} tarball")); + { + let mut tar = tar::Archive::new(std::io::Cursor::new(&decoded)); + + if tar + .entries() + .expect("failed to retrieve entries") + .filter(|ent| ent.is_ok()) + .count() + == 0 + { + panic!("no valid entries found in tarball"); + } + } + + let mut tar = tar::Archive::new(std::io::Cursor::new(decoded)); + tar.unpack(&td).expect("failed to untar files"); + } + + if let Some(gh_path) = env::var_os("GITHUB_PATH") { + let _s = Group::new(&format!("adding '{td}' to $GITHUB_PATH ({gh_path:?})")); + + // emulate >> for both empty and non-empty files + let has_contents = fs::metadata(&gh_path).map_or(false, |md| md.len() > 0); + + let mut file = fs::OpenOptions::new() + .append(true) + .open(gh_path) + .expect("failed to open $GITHUB_PATH"); + + let td = if has_contents { + format!("\n{td}\n") + } else { + td + }; + + file.write_all(td.as_bytes()) + .expect("failed to write to $GITHUB_PATH"); + } +} diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index f354ade507..a3d5f587ab 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -22,50 +22,19 @@ jobs: target: aarch64-linux-android runs-on: ${{ matrix.os }} env: - # Get platform-specific download links from https://github.com/KhronosGroup/SPIRV-Tools/blob/master/docs/downloads.md - # which will point to the `spirv-tools` Google Cloud Storage Bucket - if - # you need to manually look around, you can search for `spirv_tools_version` - # (which should be in the `YYYYMMDD` format and appear in paths) in these - # listings (NB: they're limited to 1000 results and may need adjustment): - # https://storage.googleapis.com/spirv-tools/?list-type=2&start-after=artifacts/prod/graphics_shader_compiler/spirv-tools/linux-clang-release/continuous/1800 - # https://storage.googleapis.com/spirv-tools/?list-type=2&start-after=artifacts/prod/graphics_shader_compiler/spirv-tools/macos-clang-release/continuous/1800 - # https://storage.googleapis.com/spirv-tools/?list-type=2&start-after=artifacts/prod/graphics_shader_compiler/spirv-tools/windows-msvc-2017-release/continuous/1800 - spirv_tools_version: "20221024" - # NOTE(eddyb) do not forget to update both the above date and below links! - # FIXME(eddyb) automate this somewhat by taking advantage of the bucket APIs, - # and look for the first build with the date in `spirv_tools_version`. - spirv_tools_linux_url: "https://storage.googleapis.com/spirv-tools/artifacts/prod/graphics_shader_compiler/spirv-tools/linux-clang-release/continuous/1863/20221024-094528/install.tgz" - spirv_tools_macos_url: "https://storage.googleapis.com/spirv-tools/artifacts/prod/graphics_shader_compiler/spirv-tools/macos-clang-release/continuous/1875/20221024-094531/install.tgz" - spirv_tools_windows_url: "https://storage.googleapis.com/spirv-tools/artifacts/prod/graphics_shader_compiler/spirv-tools/windows-msvc-2017-release/continuous/1851/20221024-094908/install.zip" RUSTUP_UNPACK_RAM: "26214400" RUSTUP_IO_THREADS: "1" steps: - - uses: actions/checkout@v2 - - if: ${{ runner.os == 'Linux' }} - name: Linux - Install native dependencies and spirv-tools - run: | - sudo apt install libwayland-cursor0 libxkbcommon-dev libwayland-dev - mkdir "${HOME}/spirv-tools" - curl -fL "$spirv_tools_linux_url" | tar -xz -C "${HOME}/spirv-tools" - echo "${HOME}/spirv-tools/install/bin" >> $GITHUB_PATH - - if: ${{ runner.os == 'macOS' }} - name: Mac - Install spirv-tools - # FIXME(eddyb) deduplicate with Linux (and maybe even Windows?). - run: | - mkdir "${HOME}/spirv-tools" - curl -fL "$spirv_tools_macos_url" | tar -xz -C "${HOME}/spirv-tools" - echo "${HOME}/spirv-tools/install/bin" >> $GITHUB_PATH - - if: ${{ runner.os == 'Windows' }} - name: Windows - Install spirv-tools + - uses: actions/checkout@v4 + # Install the spirv-tools binaries from tarballs hosted on each release + # of spirv-tools. This downloads the tarball, decompresses it, unpacks + # the binaries to the specified path, and adds them to PATH + - name: Install spirv-tools binaries shell: bash - run: | - tmparch=$(mktemp) - mkdir "${HOME}/spirv-tools" - curl -fL -o "$tmparch" "$spirv_tools_windows_url" - unzip "$tmparch" -d "${HOME}/spirv-tools" - - if: ${{ runner.os == 'Windows' }} - # Runs separately to add spir-v tools to Powershell's Path. - run: echo "$HOME/spirv-tools/install/bin" >> $env:GITHUB_PATH + run: cargo run --manifest-path .github/install-tools/Cargo.toml -- ${{matrix.target}} 0.10.0 "${{github.workspace}}/bin" + - if: ${{ runner.os == 'Linux' }} + name: Linux - Install native dependencies + run: sudo apt install libwayland-cursor0 libxkbcommon-dev libwayland-dev # cargo version is a random command that forces the installation of rust-toolchain - name: install rust-toolchain run: cargo version @@ -142,16 +111,13 @@ jobs: # Note that we are explicitly NOT checking out submodules, to validate # that we haven't accidentally enabled spirv-tools native compilation # and regressed CI times - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 with: submodules: "false" - name: Install native dependencies run: sudo apt install libwayland-cursor0 libxkbcommon-dev libwayland-dev - name: Install spirv-tools - run: | - mkdir "${HOME}/spirv-tools" - curl -fL https://storage.googleapis.com/spirv-tools/artifacts/prod/graphics_shader_compiler/spirv-tools/linux-clang-release/continuous/1409/20210313-175801/install.tgz | tar -xz -C "${HOME}/spirv-tools" - echo "${HOME}/spirv-tools/install/bin" >> $GITHUB_PATH + run: cargo run --manifest-path .github/install-tools/Cargo.toml -- x86_64-unknown-linux-gnu 0.10.0 "${{github.workspace}}/bin" - name: Install rustup components run: rustup component add rustfmt clippy # cargo version is a random command that forces the installation of rust-toolchain @@ -173,7 +139,7 @@ jobs: run: .github/workflows/lint.sh cargo-deny: - runs-on: ubuntu-20.04 + runs-on: ubuntu-22.04 steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - uses: EmbarkStudios/cargo-deny-action@v1 From 05472acd34a4f469ebaac0856963e8d8a81ed929 Mon Sep 17 00:00:00 2001 From: Jake Shadle Date: Mon, 5 Feb 2024 15:10:12 +0100 Subject: [PATCH 03/12] Oops --- .github/install-tools/Cargo.toml | 3 +++ .gitignore | 1 + 2 files changed, 4 insertions(+) diff --git a/.github/install-tools/Cargo.toml b/.github/install-tools/Cargo.toml index 1c77e39287..811dd12310 100644 --- a/.github/install-tools/Cargo.toml +++ b/.github/install-tools/Cargo.toml @@ -1,8 +1,11 @@ [package] name = "install-tools" edition = "2021" +version = "0.1.0" publish = false [dependencies] tar = "0.4" zstd = "0.13" + +[workspace] \ No newline at end of file diff --git a/.gitignore b/.gitignore index b22a782596..5a73168f0b 100644 --- a/.gitignore +++ b/.gitignore @@ -2,3 +2,4 @@ target/ .vscode/ .vim/ tests/Cargo.lock +.github/install-tools/Cargo.lock From 57bc8b4f46ecd538dc1fe5ef4d2583c0334940fe Mon Sep 17 00:00:00 2001 From: Jake Shadle Date: Mon, 5 Feb 2024 15:14:35 +0100 Subject: [PATCH 04/12] Target != host for android --- .github/workflows/ci.yaml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index a3d5f587ab..16e1220d97 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -14,12 +14,16 @@ jobs: include: - os: ubuntu-20.04-16core target: x86_64-unknown-linux-gnu + host: x86_64-unknown-linux-gnu - os: windows-2022-16core target: x86_64-pc-windows-msvc + host: x86_64-pc-windows-msvc - os: macOS-latest-xl target: x86_64-apple-darwin + host: x86_64-apple-darwin - os: ubuntu-20.04-16core target: aarch64-linux-android + host: x86_64-unknown-linux-gnu runs-on: ${{ matrix.os }} env: RUSTUP_UNPACK_RAM: "26214400" @@ -31,7 +35,7 @@ jobs: # the binaries to the specified path, and adds them to PATH - name: Install spirv-tools binaries shell: bash - run: cargo run --manifest-path .github/install-tools/Cargo.toml -- ${{matrix.target}} 0.10.0 "${{github.workspace}}/bin" + run: cargo run --manifest-path .github/install-tools/Cargo.toml -- ${{matrix.host}} 0.10.0 "${{github.workspace}}/bin" - if: ${{ runner.os == 'Linux' }} name: Linux - Install native dependencies run: sudo apt install libwayland-cursor0 libxkbcommon-dev libwayland-dev From d5f7e32948f6f48ba7503e39f2cacef73877544b Mon Sep 17 00:00:00 2001 From: Jake Shadle Date: Mon, 5 Feb 2024 15:17:11 +0100 Subject: [PATCH 05/12] Use non-ancient ubuntu --- .github/workflows/ci.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 16e1220d97..709cf912b7 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -12,7 +12,7 @@ jobs: strategy: matrix: include: - - os: ubuntu-20.04-16core + - os: ubuntu-22.04-16core target: x86_64-unknown-linux-gnu host: x86_64-unknown-linux-gnu - os: windows-2022-16core @@ -21,7 +21,7 @@ jobs: - os: macOS-latest-xl target: x86_64-apple-darwin host: x86_64-apple-darwin - - os: ubuntu-20.04-16core + - os: ubuntu-22.04-16core target: aarch64-linux-android host: x86_64-unknown-linux-gnu runs-on: ${{ matrix.os }} @@ -110,7 +110,7 @@ jobs: lint: name: Lint - runs-on: ubuntu-20.04-16core + runs-on: ubuntu-22.04-16core steps: # Note that we are explicitly NOT checking out submodules, to validate # that we haven't accidentally enabled spirv-tools native compilation From 159076ab24ac7e7a86d1c750639c113e9669d16c Mon Sep 17 00:00:00 2001 From: Jake Shadle Date: Mon, 5 Feb 2024 15:30:38 +0100 Subject: [PATCH 06/12] Oh right --- .github/workflows/ci.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 709cf912b7..16e1220d97 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -12,7 +12,7 @@ jobs: strategy: matrix: include: - - os: ubuntu-22.04-16core + - os: ubuntu-20.04-16core target: x86_64-unknown-linux-gnu host: x86_64-unknown-linux-gnu - os: windows-2022-16core @@ -21,7 +21,7 @@ jobs: - os: macOS-latest-xl target: x86_64-apple-darwin host: x86_64-apple-darwin - - os: ubuntu-22.04-16core + - os: ubuntu-20.04-16core target: aarch64-linux-android host: x86_64-unknown-linux-gnu runs-on: ${{ matrix.os }} @@ -110,7 +110,7 @@ jobs: lint: name: Lint - runs-on: ubuntu-22.04-16core + runs-on: ubuntu-20.04-16core steps: # Note that we are explicitly NOT checking out submodules, to validate # that we haven't accidentally enabled spirv-tools native compilation From 3cd9ef03a553c14631110b971b7819c8d3448930 Mon Sep 17 00:00:00 2001 From: Jake Shadle Date: Mon, 5 Feb 2024 15:44:31 +0100 Subject: [PATCH 07/12] Update expected output --- tests/ui/lang/core/ref/member_ref_arg-broken.stderr | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/ui/lang/core/ref/member_ref_arg-broken.stderr b/tests/ui/lang/core/ref/member_ref_arg-broken.stderr index 4552ca5cce..0c0759c940 100644 --- a/tests/ui/lang/core/ref/member_ref_arg-broken.stderr +++ b/tests/ui/lang/core/ref/member_ref_arg-broken.stderr @@ -3,6 +3,7 @@ warning: `#[inline(never)]` function `member_ref_arg_broken::h` needs to be inli warning: `#[inline(never)]` function `member_ref_arg_broken::h_newtyped` needs to be inlined because it has illegal argument or return types error: error:0:0 - OpLoad Pointer '$ID[%$ID]' is not a logical pointer. + %39 = OpLoad %uint %38 | = note: spirv-val failed = note: module `$TEST_BUILD_DIR/lang/core/ref/member_ref_arg-broken.default` From d18533fece947761e76a60a99eb2d3d4a3b4c6f7 Mon Sep 17 00:00:00 2001 From: Jake Shadle Date: Mon, 5 Feb 2024 19:08:23 +0100 Subject: [PATCH 08/12] Address feedback --- .github/install-spirv-tools/Cargo.toml | 14 ++++++++++++++ .../src/main.rs | 0 .github/install-tools/Cargo.toml | 11 ----------- .github/workflows/ci.yaml | 5 +---- .gitignore | 2 +- Cargo.toml | 3 ++- crates/rustc_codegen_spirv/Cargo.toml | 4 ++-- 7 files changed, 20 insertions(+), 19 deletions(-) create mode 100644 .github/install-spirv-tools/Cargo.toml rename .github/{install-tools => install-spirv-tools}/src/main.rs (100%) delete mode 100644 .github/install-tools/Cargo.toml diff --git a/.github/install-spirv-tools/Cargo.toml b/.github/install-spirv-tools/Cargo.toml new file mode 100644 index 0000000000..365c38d9a4 --- /dev/null +++ b/.github/install-spirv-tools/Cargo.toml @@ -0,0 +1,14 @@ +# We make this tool its own workspace as it doesn't share dependencies with the +# rest of the workspace, and it shouldn't be built normally, only as a helper +# for CI so it would just slow down local development for no reason +[workspace] + +[package] +name = "install-spirv-tools" +edition = "2021" +version = "0.1.0" +publish = false + +[dependencies] +tar = "0.4" +zstd = "0.13" diff --git a/.github/install-tools/src/main.rs b/.github/install-spirv-tools/src/main.rs similarity index 100% rename from .github/install-tools/src/main.rs rename to .github/install-spirv-tools/src/main.rs diff --git a/.github/install-tools/Cargo.toml b/.github/install-tools/Cargo.toml deleted file mode 100644 index 811dd12310..0000000000 --- a/.github/install-tools/Cargo.toml +++ /dev/null @@ -1,11 +0,0 @@ -[package] -name = "install-tools" -edition = "2021" -version = "0.1.0" -publish = false - -[dependencies] -tar = "0.4" -zstd = "0.13" - -[workspace] \ No newline at end of file diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 16e1220d97..889b8b8b29 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -14,13 +14,10 @@ jobs: include: - os: ubuntu-20.04-16core target: x86_64-unknown-linux-gnu - host: x86_64-unknown-linux-gnu - os: windows-2022-16core target: x86_64-pc-windows-msvc - host: x86_64-pc-windows-msvc - os: macOS-latest-xl target: x86_64-apple-darwin - host: x86_64-apple-darwin - os: ubuntu-20.04-16core target: aarch64-linux-android host: x86_64-unknown-linux-gnu @@ -35,7 +32,7 @@ jobs: # the binaries to the specified path, and adds them to PATH - name: Install spirv-tools binaries shell: bash - run: cargo run --manifest-path .github/install-tools/Cargo.toml -- ${{matrix.host}} 0.10.0 "${{github.workspace}}/bin" + run: cargo run --manifest-path .github/install-spirv-tools/Cargo.toml -- ${{matrix.host || matrix.target}} 0.10.0 "${{github.workspace}}/bin" - if: ${{ runner.os == 'Linux' }} name: Linux - Install native dependencies run: sudo apt install libwayland-cursor0 libxkbcommon-dev libwayland-dev diff --git a/.gitignore b/.gitignore index 5a73168f0b..d93c2cc44c 100644 --- a/.gitignore +++ b/.gitignore @@ -2,4 +2,4 @@ target/ .vscode/ .vim/ tests/Cargo.lock -.github/install-tools/Cargo.lock +.github/install-spirv-tools/Cargo.lock diff --git a/Cargo.toml b/Cargo.toml index 70f266ee50..933e024d3f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -31,10 +31,11 @@ license = "MIT OR Apache-2.0" repository = "https://github.com/EmbarkStudios/rust-gpu" [workspace.dependencies] +spirv-builder = { path = "./crates/spirv-builder", version = "=0.9.0", default-features = false } spirv-std = { path = "./crates/spirv-std", version = "=0.9.0" } spirv-std-types = { path = "./crates/spirv-std/shared", version = "=0.9.0" } spirv-std-macros = { path = "./crates/spirv-std/macros", version = "=0.9.0" } -spirv-builder = { path = "./crates/spirv-builder", version = "=0.9.0", default-features = false } +spirv-tools = { version = "0.10", default-features = false } rustc_codegen_spirv = { path = "./crates/rustc_codegen_spirv", version = "=0.9.0", default-features = false } rustc_codegen_spirv-types = { path = "./crates/rustc_codegen_spirv-types", version = "=0.9.0" } diff --git a/crates/rustc_codegen_spirv/Cargo.toml b/crates/rustc_codegen_spirv/Cargo.toml index bc9cce2bcf..13f7b3ea34 100644 --- a/crates/rustc_codegen_spirv/Cargo.toml +++ b/crates/rustc_codegen_spirv/Cargo.toml @@ -51,14 +51,14 @@ ar = "0.9.0" either = "1.8.0" indexmap = "1.6.0" rspirv = "0.11" +rustc_codegen_spirv-types.workspace = true rustc-demangle = "0.1.21" sanitize-filename = "0.4" serde = { version = "1.0", features = ["derive"] } serde_json = "1.0" smallvec = { version = "1.6.1", features = ["union"] } -spirv-tools = { version = "0.10", default-features = false } -rustc_codegen_spirv-types.workspace = true spirt = "0.3.0" +spirv-tools.workspace = true lazy_static = "1.4.0" itertools = "0.10.5" From cd3796f93dc71da2ff4e43cafe397331b3f2bdcc Mon Sep 17 00:00:00 2001 From: Jake Shadle Date: Mon, 5 Feb 2024 19:10:21 +0100 Subject: [PATCH 09/12] Oops --- .github/workflows/ci.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 889b8b8b29..ce85ebd1bf 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -118,7 +118,7 @@ jobs: - name: Install native dependencies run: sudo apt install libwayland-cursor0 libxkbcommon-dev libwayland-dev - name: Install spirv-tools - run: cargo run --manifest-path .github/install-tools/Cargo.toml -- x86_64-unknown-linux-gnu 0.10.0 "${{github.workspace}}/bin" + run: cargo run --manifest-path .github/install-spirv-tools/Cargo.toml -- x86_64-unknown-linux-gnu 0.10.0 "${{github.workspace}}/bin" - name: Install rustup components run: rustup component add rustfmt clippy # cargo version is a random command that forces the installation of rust-toolchain From 3b940624fe14a25006bf17bf7d9cf2ab7bb361e7 Mon Sep 17 00:00:00 2001 From: Jake Shadle Date: Mon, 5 Feb 2024 19:10:59 +0100 Subject: [PATCH 10/12] Cancel actions when new commits are pushed --- .github/workflows/ci.yaml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index ce85ebd1bf..44ed4e1683 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -6,6 +6,11 @@ on: name: CI +# Cancel PR actions on new commits +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} + cancel-in-progress: true + jobs: test: name: Test From 2874de3364a5ae66a699a0b00450b0127d927dcc Mon Sep 17 00:00:00 2001 From: Jake Shadle Date: Wed, 7 Feb 2024 08:11:04 +0100 Subject: [PATCH 11/12] Update CHANGELOG --- CHANGELOG.md | 63 +++++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 62 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index b3051d206c..b3fd97d3b5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,5 @@ + + # `rust-gpu` Changelog All notable changes to this project will be documented in this file. @@ -30,15 +32,18 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] ### Changed πŸ›  + - [PR#1101](https://github.com/EmbarkStudios/rust-gpu/pull/1101) Add `ignore` and `no_run` to documentation to make `cargo test` pass. - [PR#1112](https://github.com/EmbarkStudios/rust-gpu/pull/1112) updated wgpu and winit in example runners - [PR#1100](https://github.com/EmbarkStudios/rust-gpu/pull/1100) updated toolchain to `nightly-2023-09-30` - [PR#1091](https://github.com/EmbarkStudios/rust-gpu/pull/1091) updated toolchain to `nightly-2023-08-29` - [PR#1085](https://github.com/EmbarkStudios/rust-gpu/pull/1085) updated toolchain to `nightly-2023-07-08` +- [PR#1127](https://github.com/EmbarkStudios/rust-gpu/pull/1127) updated `spirv-tools` to `0.10.0`, which follows `vulkan-sdk-1.3.275`. ## [0.9.0] ### Added ⭐ + - [PR#1082](https://github.com/EmbarkStudios/rust-gpu/pull/1082) added partial support for extracting `format_args!` from `panic!`s, and converting them to `debugPrintf` calls (if enabled via `ShaderPanicStrategy`), including runtime @@ -55,6 +60,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 (see its documentation for more details about each available panic handling strategy) ### Changed πŸ›  + - [PR#1083](https://github.com/EmbarkStudios/rust-gpu/pull/1083) updated SPIR-T to get pretty-printer improvements (especially for `OpExtInst`, including Rust-GPU's custom ones), and started more aggressively deduplicating custom debuginfo instructions (to make SPIR-T dumps more readable) @@ -67,30 +73,35 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [0.8.0] ### Added ⭐ + - [PR#1064](https://github.com/EmbarkStudios/rust-gpu/pull/1064) added a Rust-GPU-private "extended instruction set" (to allow us to have custom `OpExtInst`s), with the initial custom `OpExtInst`s being used to improve debuginfo source locations (using ranges instead of just the starting position, and tracking inlined calls) ### Changed πŸ›  + - [PR#1067](https://github.com/EmbarkStudios/rust-gpu/pull/1067) updated toolchain to `nightly-2023-04-15` - [PR#1038](https://github.com/EmbarkStudios/rust-gpu/pull/1038) relaxed `glam` version requirements (from only `0.22`, to `>=0.22, <=0.24`) ### Removed πŸ”₯ + - [PR#1052](https://github.com/EmbarkStudios/rust-gpu/pull/1052) removed `--no-spirt`, committing to SPIR-T as a mandatory part of the Rust-GPU compiler backend, to reduce the cost of maintenance, testing and further feature development - * Note: if you were using `--no-spirt` to work around [`naga` issue #1977](https://github.com/gfx-rs/naga/issues/1977) + - Note: if you were using `--no-spirt` to work around [`naga` issue #1977](https://github.com/gfx-rs/naga/issues/1977) (valid loops causing `The 'break' is used outside of a 'loop' or 'switch' context`), you may be able to `cargo update -p naga` to update to a fixed `naga` version (`0.11.1` for `wgpu 0.15`, `0.12.1` for `wgpu 0.16`, and any later versions) ### Fixed 🩹 + - [PR#1059](https://github.com/EmbarkStudios/rust-gpu/pull/1059) fixed the `inline` pass not copying `OpDecorate`s in the callee (which led to their loss). ## [0.7.0] ### Added ⭐ + - [PR#1020](https://github.com/EmbarkStudios/rust-gpu/pull/1020) added SPIR-T `qptr` support in the form of `--spirt-passes=qptr`, a way to turn off "Storage Class inference", and reporting for SPIR-T diagnostics - to test `qptr` fully, you can use: @@ -100,6 +111,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [PR#1031](https://github.com/EmbarkStudios/rust-gpu/pull/1031) added `Components` generic parameter to `Image` type, allowing images to return lower dimensional vectors and even scalars from the sampling API ### Changed πŸ›  + - [PR#1040](https://github.com/EmbarkStudios/rust-gpu/pull/1040) refactored "zombie" (delayed error) reporting to use SPIR-V `OpSource`, be more helpful, and added `--no-early-report-zombies` to delay it even further (see also [the `--no-early-report-zombies` codegen args docs](docs/src/codegen-args.md#--no-early-report-zombies)) - [PR#1035](https://github.com/EmbarkStudios/rust-gpu/pull/1035) reduced the number of CGUs ("codegen units") used by `spirv-builder` to just `1` @@ -108,6 +120,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [PR#1005](https://github.com/EmbarkStudios/rust-gpu/pull/1005) updated toolchain to `nightly-2023-03-04` ### Fixed 🩹 + - [PR#1041](https://github.com/EmbarkStudios/rust-gpu/pull/1041) fixed `Image::gather()` not always returning a `Vec4`. - [PR#1025](https://github.com/EmbarkStudios/rust-gpu/pull/1025) fixed [#1024](https://github.com/EmbarkStudios/rust-gpu/issues/1024) by keeping checked arithmetic "zombie" `bool`s disjoint from normal `bool` (`false`) consts - [PR#1023](https://github.com/EmbarkStudios/rust-gpu/pull/1023) fixed [#1021](https://github.com/EmbarkStudios/rust-gpu/issues/1021) by always inlining calls with "not obviously legal" pointer args (instead of only inlining calls with "obviously illegal" pointer args) @@ -117,14 +130,17 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [0.6.1] ### Fixed 🩹 + - [PR#1006](https://github.com/EmbarkStudios/rust-gpu/pull/1006) fixed [#1002](https://github.com/EmbarkStudios/rust-gpu/issues/1002) by rewriting away all `spirv-std` uses of `asm!("OpReturnValue %result")` and disallowing `OpReturn`/`OpReturnValue` from inline `asm!` (as it's always UB to leave `asm!` blocks in any way other than falling through their end) ## [0.6.0] ### Added ⭐ + - [PR#998](https://github.com/EmbarkStudios/rust-gpu/pull/998) added `extra_arg()` SpirvBuilder API to be able to set codegen args otherwise not supported by the API (for example, to set `--spirv-passes`) ### Changed πŸ›  + - [PR#999](https://github.com/EmbarkStudios/rust-gpu/pull/999) made the [`SPIR-πŸ‡Ή` shader IR framework](https://github.com/EmbarkStudios/spirt) the default (you can opt out via `RUSTGPU_CODEGEN_ARGS=--no-spirt`) - [PR#992](https://github.com/EmbarkStudios/rust-gpu/pull/992) renamed `rust-toolchain` to `rust-toolchain.toml` - [PR#991](https://github.com/EmbarkStudios/rust-gpu/pull/991) updated toolchain to `nightly-2023-01-21` @@ -133,17 +149,20 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [0.5.0] ### Added ⭐ + - [PR#988](https://github.com/EmbarkStudios/rust-gpu/pull/988) added a couple of (highly experimental) `SPIR-πŸ‡Ή` optimization passes, and `--spirt-passes=...` codegen args as a way to enable them (see also [the `--spirt-passes` codegen args docs](docs/src/codegen-args.md#--spirt-passes-PASSES)) ### Changed πŸ› οΈ + - [PR#982](https://github.com/EmbarkStudios/rust-gpu/pull/982) updated toolchain to `nightly-2022-12-18` - [PR#953](https://github.com/EmbarkStudios/rust-gpu/pull/953) migrated to the Rust 2021 edition, and fixed Rust 2021 support for shader crates to be on par with Rust 2018 (discrepancies having been limited to/caused by `panic!` changes in Rust 2021) ## [0.4.0] ### Added ⭐ + - [PR#959](https://github.com/EmbarkStudios/rust-gpu/pull/959) added two `spirv-builder` environment variables to customize *only* the `rustc` invocations for shader crates and their dependencies: - `RUSTGPU_RUSTFLAGS="..."` for shader `RUSTFLAGS="..."` - `RUSTGPU_CODEGEN_ARGS="..."` for shader "codegen args" (i.e. `RUSTFLAGS=-Cllvm-args="..."`) @@ -152,53 +171,64 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 (opt-in via `RUSTGPU_CODEGEN_ARGS=--spirt`, see also [the `--spirt` docs](docs/src/codegen-args.md#--spirt), for more details) ### Changed πŸ› οΈ + - [PR#958](https://github.com/EmbarkStudios/rust-gpu/pull/958) updated toolchain to `nightly-2022-10-29` - [PR#941](https://github.com/EmbarkStudios/rust-gpu/pull/941) applied workspace inheritance to `Cargo.toml` files - [PR#959](https://github.com/EmbarkStudios/rust-gpu/pull/959) moved `rustc_codegen_spirv` debugging functionality from environment variables to "codegen args" options/flags (see [the updated docs](docs/src/codegen-args.md) for more details) - [PR#967](https://github.com/EmbarkStudios/rust-gpu/pull/967) made `--dump-*` ["codegen args"](docs/src/codegen-args.md) include identifying information (e.g. crate names) in the names of files they emit ### Removed πŸ”₯ + - [PR#946](https://github.com/EmbarkStudios/rust-gpu/pull/946) removed the `fn`/closure `#[spirv(unroll_loops)]` attribute, as it has no users, is becoming non-trivial to support, and requires redesign for better ergonomics (e.g. `#[spirv(unroll)]` applied to individual loops, not the whole `fn`/closure) ## [0.4.0-alpha.17] ### Fixed 🩹 + - [PR#937](https://github.com/EmbarkStudios/rust-gpu/pull/937) fixed Rust-GPU crates not referring to each-other by exact version - [PR#937](https://github.com/EmbarkStudios/rust-gpu/pull/937) fixed `spirv-std` referring to an older version of `spirv-std-macros` ## [0.4.0-alpha.16] ### Added ⭐ + - [PR#935](https://github.com/EmbarkStudios/rust-gpu/pull/935) added check for environment variable `RUSTGPU_SKIP_TOOLCHAIN_CHECK` to prevent toolchain check ### Changed πŸ› οΈ + - 🚨BREAKING🚨 [#926](https://github.com/EmbarkStudios/rust-gpu/pull/926) migrated from `register_attr` to `register_tool`. [More information](docs/src/migration-to-register-tool.md). - [PR#935](https://github.com/EmbarkStudios/rust-gpu/pull/935) updated toolchain to `nightly-2022-10-01` - [PR#934](https://github.com/EmbarkStudios/rust-gpu/pull/934) updated `glam` to `0.22` - [PR#928](https://github.com/EmbarkStudios/rust-gpu/pull/928) updated `spirv-tools` to `0.9` (SPIRV-Tools `2022.4`) ### Removed πŸ”₯ + - [PR#934](https://github.com/EmbarkStudios/rust-gpu/pull/934) Removed `glam::BVec` support (they are no longer `#[repl(simd)]` in `glam`, as Rust doesn't support SIMD vectors with `bool` elements) ### Fixed 🩹 + - [PR#927](https://github.com/EmbarkStudios/rust-gpu/pull/927) re-taught Cargo to rebuild shader crates when `rustc_codegen_spirv` is rebuilt, via [`-Zbinary-dep-depinfo`](https://github.com/rust-lang/rust/pull/93969) (broken since a toolchain update in `0.4.0-alpha.13`, and has been causing spurious build failures ever since) ## [0.4.0-alpha.15] ### Added ⭐ + - [PR#919](https://github.com/EmbarkStudios/rust-gpu/pull/919) added a build-time check for the nightly toolchain version, to provide user-friendly error messages ### Changed πŸ› οΈ + - [PR#918](https://github.com/EmbarkStudios/rust-gpu/pull/918) updated toolchain to `nightly-2022-08-29` ## [0.4.0-alpha.14] ### Changed πŸ›  + - [PR#904](https://github.com/EmbarkStudios/rust-gpu/pull/904) renamed helper `spirv-types` crate to `spirv-std-types` ## [0.4.0-alpha.13] ### Added ⭐ + - [PR#717](https://github.com/EmbarkStudios/rust-gpu/pull/717) added `noreturn` support to inline `asm!` - [PR#742](https://github.com/EmbarkStudios/rust-gpu/pull/742) added a `spirv-builder` option to include all debug info - [PR#787](https://github.com/EmbarkStudios/rust-gpu/pull/787) documented `Cargo.toml` `[profile.β‹―.build-override]` setting for avoiding slow builds @@ -208,6 +238,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - new `spirv-std` APIs: `ByteAddressableBuffer`[#735](https://github.com/EmbarkStudios/rust-gpu/pull/735), `SampledImage::sample_by_lod`[#755](https://github.com/EmbarkStudios/rust-gpu/pull/755), `arch::read_clock_khr`[#757](https://github.com/EmbarkStudios/rust-gpu/pull/757), `arch::{signed,unsigned}_{min,max}`[#763](https://github.com/EmbarkStudios/rust-gpu/pull/763), `debug_printf!`[#768](https://github.com/EmbarkStudios/rust-gpu/pull/768), `arch::*memory_barrier*`[#769](https://github.com/EmbarkStudios/rust-gpu/pull/769), `arch::IndexUnchecked`[#805](https://github.com/EmbarkStudios/rust-gpu/pull/805), `RayQuery::confirm_intersection`[#822](https://github.com/EmbarkStudios/rust-gpu/pull/822), `arch::atomic_i_increment`[#839](https://github.com/EmbarkStudios/rust-gpu/pull/839), `arch::atomic`[#877](https://github.com/EmbarkStudios/rust-gpu/pull/877) ### Changed πŸ›  + - [PR#743](https://github.com/EmbarkStudios/rust-gpu/pull/743) set the SPIR-V "generator magic number" to [the value reserved for Rust-GPU](https://github.com/KhronosGroup/SPIRV-Headers/pull/174) - [PR#761](https://github.com/EmbarkStudios/rust-gpu/pull/761) made `spirv-std` build on stable Rust by avoiding `enum`s in `const`-generics - [PR#784](https://github.com/EmbarkStudios/rust-gpu/pull/784) documented `spirv-std` throughout @@ -216,6 +247,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [PR#888](https://github.com/EmbarkStudios/rust-gpu/pull/888) widened the supported `glam` version range to `0.17`-`0.21` ### Fixed 🩹 + - [PR#729](https://github.com/EmbarkStudios/rust-gpu/pull/729) fixed [#723](https://github.com/EmbarkStudios/rust-gpu/issues/723) by explicitly allowing unused shader inputs/outputs in storage class inference - [PR#732](https://github.com/EmbarkStudios/rust-gpu/pull/732) fixed `rustc` ICE messages being truncated with `rustc_codegen_spirv` (broken since a toolchain update in `0.4.0-alpha.12`) - [PR#737](https://github.com/EmbarkStudios/rust-gpu/pull/737) fixed [#642](https://github.com/EmbarkStudios/rust-gpu/issues/642) by re-adding `-Zsymbol-mangling-version=v0` (for generic parameters in `fn` names) @@ -226,23 +258,28 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [0.4.0-alpha.12] ### Added ⭐ + - [PR#704](https://github.com/EmbarkStudios/rust-gpu/pull/704) added `Image::gather` and `Image::sample_bias` to `spirv-std` - [PR#709](https://github.com/EmbarkStudios/rust-gpu/pull/709) added float packing/unpacking operations to `spirv-std` ### Changed πŸ›  + - [PR#716](https://github.com/EmbarkStudios/rust-gpu/pull/716) updated toolchain to `nightly-2021-08-10` ### Removed πŸ”₯ + - [PR#710](https://github.com/EmbarkStudios/rust-gpu/pull/710) removed "implicit bindless" and kernel modes ## [0.4.0-alpha.11] ### Changed πŸ›  + - [PR#702](https://github.com/EmbarkStudios/rust-gpu/pull/702) updated `glam` to `0.17` ## [0.4.0-alpha.10] ### Added ⭐ + - [PR#655](https://github.com/EmbarkStudios/rust-gpu/pull/655) added a `watch` feature to `spirv-builder` for hot reloading shaders - [PR#652](https://github.com/EmbarkStudios/rust-gpu/pull/652) documented `Image!` in the Rust-GPU book - [PR#660](https://github.com/EmbarkStudios/rust-gpu/pull/660) added a `spirv-builder` option to name global `OpVariables` @@ -250,20 +287,24 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [PR#683](https://github.com/EmbarkStudios/rust-gpu/pull/683) added a `spirv-builder` option to treat warnings as errors ### Changed πŸ›  + - [PR#672](https://github.com/EmbarkStudios/rust-gpu/pull/672) updated toolchain to `nightly-2021-06-09` - [PR#674](https://github.com/EmbarkStudios/rust-gpu/pull/674) updated `glam` to `0.16` ### Removed πŸ”₯ + - [PR#666](https://github.com/EmbarkStudios/rust-gpu/pull/666) removed `arch::arithmetic` from `spirv-std` ## [0.4.0-alpha.9] ### Fixed 🩹 + - fixed miscompilation in peephole optimizations (see [PR#646](https://github.com/EmbarkStudios/rust-gpu/pull/646)) ## [0.4.0-alpha.8] ### Added ⭐ + - [PR#608](https://github.com/EmbarkStudios/rust-gpu/pull/608) added `Image::query_*` operations to `spirv-std` - [PR#610](https://github.com/EmbarkStudios/rust-gpu/pull/610) added `spirv-builder` support for enabling extra extensions and/or capabilities - [PR#612](https://github.com/EmbarkStudios/rust-gpu/pull/612) added `is_helper_invocation` to `spirv-std` @@ -276,6 +317,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [PR#643](https://github.com/EmbarkStudios/rust-gpu/pull/643) added `Image::read_subpass` to `spirv-std` ### Changed πŸ›  + - [PR#616](https://github.com/EmbarkStudios/rust-gpu/pull/616) updated `spirv-tools` to `0.6.1` and turned on emission of line-based debug info - [PR#631](https://github.com/EmbarkStudios/rust-gpu/pull/631) updated toolchain to `nightly-2021-05-24` - [PR#641](https://github.com/EmbarkStudios/rust-gpu/pull/641) made `spirv-std` depend on `glam` (`0.15.2`), instead of the other way around @@ -283,11 +325,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [0.4.0-alpha.7] ### Fixed 🩹 + - [PR#607](https://github.com/EmbarkStudios/rust-gpu/pull/607) removed accidental use of `feature(or_patterns)` (recently stabilized, only on nightly) ## [0.4.0-alpha.6] ### Added ⭐ + - [PR#586](https://github.com/EmbarkStudios/rust-gpu/pull/586) added support for constant memory (`&'static _` references), within the limits of SPIR-V - [PR#559](https://github.com/EmbarkStudios/rust-gpu/pull/559) added the ability to set a Rust "target triple" in `spirv-builder` (e.g. `"spirv-unknown-vulkan1.1"` for Vulkan `1.1`) - [PR#563](https://github.com/EmbarkStudios/rust-gpu/pull/563) added `SPV_KHR_ray_tracing` APIs to `spirv-std` @@ -295,32 +339,39 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [PR#359](https://github.com/EmbarkStudios/rust-gpu/pull/359) added a `const`-generic `Image` type, and `Image!` macro wrapping it (to add "named parameters"), to `spirv-std` ### Changed πŸ›  + - [PR#587](https://github.com/EmbarkStudios/rust-gpu/pull/587) updated `glam` to `0.14` - [PR#605](https://github.com/EmbarkStudios/rust-gpu/pull/605) updated toolchain to `nightly-2021-04-25` ### Fixed 🩹 + - [PR#594](https://github.com/EmbarkStudios/rust-gpu/pull/594) fixed [#585](https://github.com/EmbarkStudios/rust-gpu/issues/585) by explicitly banning `Image`/`Sampler`/`SampledImage` entry-point parameters not behind references - [PR#598](https://github.com/EmbarkStudios/rust-gpu/pull/598) fixed [#581](https://github.com/EmbarkStudios/rust-gpu/issues/581) by switching `memory::Semantics` from an `enum` to a `bitflags!`, in `spirv-std` ## [0.4.0-alpha.5] ### Removed πŸ”₯ + - [PR#583](https://github.com/EmbarkStudios/rust-gpu/pull/583) removed `memcmp` from `spirv-std` ## [0.4.0-alpha.4] ### Added ⭐ + - [PR#519](https://github.com/EmbarkStudios/rust-gpu/pull/519) added `memory_barrier` and `control_barrier` to `spirv-std` ### Changed πŸ›  + - [PR#567](https://github.com/EmbarkStudios/rust-gpu/pull/567) removed the need to manually specify the storage class for `Image`/`Sampler`/`ImageSampler` entry-point parameters ### Deprecated 🚧 + - [PR#576](https://github.com/EmbarkStudios/rust-gpu/pull/576) deprecated `#[spirv(block)]` in favor of automatically wrapping the user types in "interface blocks" ## [0.4.0-alpha.3] ### Added ⭐ + - [PR#551](https://github.com/EmbarkStudios/rust-gpu/pull/551) added multi-module (one SPIR-V module per entry-point) support to `spirv-builder` - [PR#504](https://github.com/EmbarkStudios/rust-gpu/pull/504) added basic support for unsized `struct`s (e.g. ending with a `[T]` field) - [PR#545](https://github.com/EmbarkStudios/rust-gpu/pull/545) added `Image` methods for sampling depth reference and/or with project coordinate, to `spirv-std` @@ -328,19 +379,23 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [0.4.0-alpha.2] ### Added ⭐ + - [PR#541](https://github.com/EmbarkStudios/rust-gpu/pull/541) added `#[spirv(invariant)]` (like the `invariant` keyword in GLSL) ### Fixed 🩹 + - made `arch::derivative` functions public, in `spirv-std` ## [0.4.0-alpha.1] ### Added ⭐ + - [PR#498](https://github.com/EmbarkStudios/rust-gpu/pull/498) added `sample_by_lod`/`sample_by_gradient` image methods to `spirv-std` - [PR#521](https://github.com/EmbarkStudios/rust-gpu/pull/521) added `Cubemap` to `spirv-std` - [PR#520](https://github.com/EmbarkStudios/rust-gpu/pull/520) added `arch::primitive` functions to `spirv-std` ### Changed πŸ›  + - [PR#496](https://github.com/EmbarkStudios/rust-gpu/pull/496) updated `spirv-tools` to `0.5.0` - [PR#516](https://github.com/EmbarkStudios/rust-gpu/pull/516) updated toolchain to `nightly-2021-03-21` - [PR#443](https://github.com/EmbarkStudios/rust-gpu/pull/443) replaced `spirv_std::storage_class` "named pointer types" with `#[spirv(...)] &T` entry-point parameters @@ -348,15 +403,18 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [0.3.1] ### Added ⭐ + - [PR#480](https://github.com/EmbarkStudios/rust-gpu/pull/480) added a `fetch` image method to `spirv-std` - [PR#446](https://github.com/EmbarkStudios/rust-gpu/pull/446) added `arch::*` functions for all SPIR-V arithmetic operations (not involving matrices), to `spirv-std` ### Removed πŸ”₯ + - [PR#476](https://github.com/EmbarkStudios/rust-gpu/pull/476) removed `glam` as a dependency of `spirv-std` ## [0.3.0] ### Added ⭐ + - [PR#414](https://github.com/EmbarkStudios/rust-gpu/pull/414) added storage class type inference - [PR#469](https://github.com/EmbarkStudios/rust-gpu/pull/469) added initial support for Algebraic Data Type enums (e.g. `Option`) - [PR#421](https://github.com/EmbarkStudios/rust-gpu/pull/421) added ability to provide `const` arguments to `asm!` @@ -370,6 +428,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - new `spirv-std` APIs: `vector_extract_dynamic`[PR#394](https://github.com/EmbarkStudios/rust-gpu/pull/394), `vector_insert_dynamic`[PR#411](https://github.com/EmbarkStudios/rust-gpu/pull/411), `textures::StorageImage2d`[PR#434](https://github.com/EmbarkStudios/rust-gpu/pull/434), `any`/`all`[PR#380](https://github.com/EmbarkStudios/rust-gpu/pull/441), `discard`[PR#441](https://github.com/EmbarkStudios/rust-gpu/pull/380), `demote_to_helper_invocation`[PR#380](https://github.com/EmbarkStudios/rust-gpu/pull/380), ``SampledImage``[PR#320](https://github.com/EmbarkStudios/rust-gpu/pull/320) ### Changed πŸ›  + - [PR#461](https://github.com/EmbarkStudios/rust-gpu/pull/461) removed requirement of `#[allow(unused_attributes)]` in front of `#[spirv]` attributes to remove warnings - [PR#398](https://github.com/EmbarkStudios/rust-gpu/pull/398) `rustc_codegen_spirv` now removes different `OpName`s that target the same ID - [PR#396](https://github.com/EmbarkStudios/rust-gpu/pull/396) `rustc_codegen_spirv` now tries to deduplicate generated `OpVariable`s @@ -377,6 +436,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [0.2.0] ### Added ⭐ + - [PR#287](https://github.com/EmbarkStudios/rust-gpu/pull/287) added a new structurizer, which means that you can now use `match` expressions and `continue`s - [PR#317](https://github.com/EmbarkStudios/rust-gpu/pull/317) added the `#[spirv(flat)]` attribute that matches SPIR-V's "Flat" decorator. - [PR#276](https://github.com/EmbarkStudios/rust-gpu/pull/276) added support for textures. @@ -387,6 +447,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [PR#254](https://github.com/EmbarkStudios/rust-gpu/pull/254) added initial support in Rust and `rust-gpu` for inline SPIR-V with the `asm!` nightly feature ### Changed πŸ›  + - [PR#219](https://github.com/EmbarkStudios/rust-gpu/pull/219) improvements to error messages regarding constant pointers - [PR#280](https://github.com/EmbarkStudios/rust-gpu/pull/280) all Storage Classes (e.g. `Input`/`Output`) are now defined in `spirv_std::storage_class` - [PR#275](https://github.com/EmbarkStudios/rust-gpu/pull/275) Rust's language items such `rust_eh_personality` and `panic_handler` are now defined in `spirv-std` for SPIR-V targets From 56820d1c4951fc9e9776e8436b5a8cd62800f486 Mon Sep 17 00:00:00 2001 From: Jake Shadle Date: Wed, 7 Feb 2024 08:34:22 +0100 Subject: [PATCH 12/12] Fixup --- CHANGELOG.md | 64 ++-------------------------------------------------- 1 file changed, 2 insertions(+), 62 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index b3fd97d3b5..0e46df035d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,3 @@ - - # `rust-gpu` Changelog All notable changes to this project will be documented in this file. @@ -32,18 +30,16 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] ### Changed πŸ›  - +- [PR#1127](https://github.com/EmbarkStudios/rust-gpu/pull/1127) updated `spirv-tools` to `0.10.0`, which follows `vulkan-sdk-1.3.275`. - [PR#1101](https://github.com/EmbarkStudios/rust-gpu/pull/1101) Add `ignore` and `no_run` to documentation to make `cargo test` pass. - [PR#1112](https://github.com/EmbarkStudios/rust-gpu/pull/1112) updated wgpu and winit in example runners - [PR#1100](https://github.com/EmbarkStudios/rust-gpu/pull/1100) updated toolchain to `nightly-2023-09-30` - [PR#1091](https://github.com/EmbarkStudios/rust-gpu/pull/1091) updated toolchain to `nightly-2023-08-29` - [PR#1085](https://github.com/EmbarkStudios/rust-gpu/pull/1085) updated toolchain to `nightly-2023-07-08` -- [PR#1127](https://github.com/EmbarkStudios/rust-gpu/pull/1127) updated `spirv-tools` to `0.10.0`, which follows `vulkan-sdk-1.3.275`. ## [0.9.0] ### Added ⭐ - - [PR#1082](https://github.com/EmbarkStudios/rust-gpu/pull/1082) added partial support for extracting `format_args!` from `panic!`s, and converting them to `debugPrintf` calls (if enabled via `ShaderPanicStrategy`), including runtime @@ -60,7 +56,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 (see its documentation for more details about each available panic handling strategy) ### Changed πŸ›  - - [PR#1083](https://github.com/EmbarkStudios/rust-gpu/pull/1083) updated SPIR-T to get pretty-printer improvements (especially for `OpExtInst`, including Rust-GPU's custom ones), and started more aggressively deduplicating custom debuginfo instructions (to make SPIR-T dumps more readable) @@ -73,35 +68,30 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [0.8.0] ### Added ⭐ - - [PR#1064](https://github.com/EmbarkStudios/rust-gpu/pull/1064) added a Rust-GPU-private "extended instruction set" (to allow us to have custom `OpExtInst`s), with the initial custom `OpExtInst`s being used to improve debuginfo source locations (using ranges instead of just the starting position, and tracking inlined calls) ### Changed πŸ›  - - [PR#1067](https://github.com/EmbarkStudios/rust-gpu/pull/1067) updated toolchain to `nightly-2023-04-15` - [PR#1038](https://github.com/EmbarkStudios/rust-gpu/pull/1038) relaxed `glam` version requirements (from only `0.22`, to `>=0.22, <=0.24`) ### Removed πŸ”₯ - - [PR#1052](https://github.com/EmbarkStudios/rust-gpu/pull/1052) removed `--no-spirt`, committing to SPIR-T as a mandatory part of the Rust-GPU compiler backend, to reduce the cost of maintenance, testing and further feature development - - Note: if you were using `--no-spirt` to work around [`naga` issue #1977](https://github.com/gfx-rs/naga/issues/1977) + * Note: if you were using `--no-spirt` to work around [`naga` issue #1977](https://github.com/gfx-rs/naga/issues/1977) (valid loops causing `The 'break' is used outside of a 'loop' or 'switch' context`), you may be able to `cargo update -p naga` to update to a fixed `naga` version (`0.11.1` for `wgpu 0.15`, `0.12.1` for `wgpu 0.16`, and any later versions) ### Fixed 🩹 - - [PR#1059](https://github.com/EmbarkStudios/rust-gpu/pull/1059) fixed the `inline` pass not copying `OpDecorate`s in the callee (which led to their loss). ## [0.7.0] ### Added ⭐ - - [PR#1020](https://github.com/EmbarkStudios/rust-gpu/pull/1020) added SPIR-T `qptr` support in the form of `--spirt-passes=qptr`, a way to turn off "Storage Class inference", and reporting for SPIR-T diagnostics - to test `qptr` fully, you can use: @@ -111,7 +101,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [PR#1031](https://github.com/EmbarkStudios/rust-gpu/pull/1031) added `Components` generic parameter to `Image` type, allowing images to return lower dimensional vectors and even scalars from the sampling API ### Changed πŸ›  - - [PR#1040](https://github.com/EmbarkStudios/rust-gpu/pull/1040) refactored "zombie" (delayed error) reporting to use SPIR-V `OpSource`, be more helpful, and added `--no-early-report-zombies` to delay it even further (see also [the `--no-early-report-zombies` codegen args docs](docs/src/codegen-args.md#--no-early-report-zombies)) - [PR#1035](https://github.com/EmbarkStudios/rust-gpu/pull/1035) reduced the number of CGUs ("codegen units") used by `spirv-builder` to just `1` @@ -120,7 +109,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [PR#1005](https://github.com/EmbarkStudios/rust-gpu/pull/1005) updated toolchain to `nightly-2023-03-04` ### Fixed 🩹 - - [PR#1041](https://github.com/EmbarkStudios/rust-gpu/pull/1041) fixed `Image::gather()` not always returning a `Vec4`. - [PR#1025](https://github.com/EmbarkStudios/rust-gpu/pull/1025) fixed [#1024](https://github.com/EmbarkStudios/rust-gpu/issues/1024) by keeping checked arithmetic "zombie" `bool`s disjoint from normal `bool` (`false`) consts - [PR#1023](https://github.com/EmbarkStudios/rust-gpu/pull/1023) fixed [#1021](https://github.com/EmbarkStudios/rust-gpu/issues/1021) by always inlining calls with "not obviously legal" pointer args (instead of only inlining calls with "obviously illegal" pointer args) @@ -130,17 +118,14 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [0.6.1] ### Fixed 🩹 - - [PR#1006](https://github.com/EmbarkStudios/rust-gpu/pull/1006) fixed [#1002](https://github.com/EmbarkStudios/rust-gpu/issues/1002) by rewriting away all `spirv-std` uses of `asm!("OpReturnValue %result")` and disallowing `OpReturn`/`OpReturnValue` from inline `asm!` (as it's always UB to leave `asm!` blocks in any way other than falling through their end) ## [0.6.0] ### Added ⭐ - - [PR#998](https://github.com/EmbarkStudios/rust-gpu/pull/998) added `extra_arg()` SpirvBuilder API to be able to set codegen args otherwise not supported by the API (for example, to set `--spirv-passes`) ### Changed πŸ›  - - [PR#999](https://github.com/EmbarkStudios/rust-gpu/pull/999) made the [`SPIR-πŸ‡Ή` shader IR framework](https://github.com/EmbarkStudios/spirt) the default (you can opt out via `RUSTGPU_CODEGEN_ARGS=--no-spirt`) - [PR#992](https://github.com/EmbarkStudios/rust-gpu/pull/992) renamed `rust-toolchain` to `rust-toolchain.toml` - [PR#991](https://github.com/EmbarkStudios/rust-gpu/pull/991) updated toolchain to `nightly-2023-01-21` @@ -149,20 +134,17 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [0.5.0] ### Added ⭐ - - [PR#988](https://github.com/EmbarkStudios/rust-gpu/pull/988) added a couple of (highly experimental) `SPIR-πŸ‡Ή` optimization passes, and `--spirt-passes=...` codegen args as a way to enable them (see also [the `--spirt-passes` codegen args docs](docs/src/codegen-args.md#--spirt-passes-PASSES)) ### Changed πŸ› οΈ - - [PR#982](https://github.com/EmbarkStudios/rust-gpu/pull/982) updated toolchain to `nightly-2022-12-18` - [PR#953](https://github.com/EmbarkStudios/rust-gpu/pull/953) migrated to the Rust 2021 edition, and fixed Rust 2021 support for shader crates to be on par with Rust 2018 (discrepancies having been limited to/caused by `panic!` changes in Rust 2021) ## [0.4.0] ### Added ⭐ - - [PR#959](https://github.com/EmbarkStudios/rust-gpu/pull/959) added two `spirv-builder` environment variables to customize *only* the `rustc` invocations for shader crates and their dependencies: - `RUSTGPU_RUSTFLAGS="..."` for shader `RUSTFLAGS="..."` - `RUSTGPU_CODEGEN_ARGS="..."` for shader "codegen args" (i.e. `RUSTFLAGS=-Cllvm-args="..."`) @@ -171,64 +153,53 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 (opt-in via `RUSTGPU_CODEGEN_ARGS=--spirt`, see also [the `--spirt` docs](docs/src/codegen-args.md#--spirt), for more details) ### Changed πŸ› οΈ - - [PR#958](https://github.com/EmbarkStudios/rust-gpu/pull/958) updated toolchain to `nightly-2022-10-29` - [PR#941](https://github.com/EmbarkStudios/rust-gpu/pull/941) applied workspace inheritance to `Cargo.toml` files - [PR#959](https://github.com/EmbarkStudios/rust-gpu/pull/959) moved `rustc_codegen_spirv` debugging functionality from environment variables to "codegen args" options/flags (see [the updated docs](docs/src/codegen-args.md) for more details) - [PR#967](https://github.com/EmbarkStudios/rust-gpu/pull/967) made `--dump-*` ["codegen args"](docs/src/codegen-args.md) include identifying information (e.g. crate names) in the names of files they emit ### Removed πŸ”₯ - - [PR#946](https://github.com/EmbarkStudios/rust-gpu/pull/946) removed the `fn`/closure `#[spirv(unroll_loops)]` attribute, as it has no users, is becoming non-trivial to support, and requires redesign for better ergonomics (e.g. `#[spirv(unroll)]` applied to individual loops, not the whole `fn`/closure) ## [0.4.0-alpha.17] ### Fixed 🩹 - - [PR#937](https://github.com/EmbarkStudios/rust-gpu/pull/937) fixed Rust-GPU crates not referring to each-other by exact version - [PR#937](https://github.com/EmbarkStudios/rust-gpu/pull/937) fixed `spirv-std` referring to an older version of `spirv-std-macros` ## [0.4.0-alpha.16] ### Added ⭐ - - [PR#935](https://github.com/EmbarkStudios/rust-gpu/pull/935) added check for environment variable `RUSTGPU_SKIP_TOOLCHAIN_CHECK` to prevent toolchain check ### Changed πŸ› οΈ - - 🚨BREAKING🚨 [#926](https://github.com/EmbarkStudios/rust-gpu/pull/926) migrated from `register_attr` to `register_tool`. [More information](docs/src/migration-to-register-tool.md). - [PR#935](https://github.com/EmbarkStudios/rust-gpu/pull/935) updated toolchain to `nightly-2022-10-01` - [PR#934](https://github.com/EmbarkStudios/rust-gpu/pull/934) updated `glam` to `0.22` - [PR#928](https://github.com/EmbarkStudios/rust-gpu/pull/928) updated `spirv-tools` to `0.9` (SPIRV-Tools `2022.4`) ### Removed πŸ”₯ - - [PR#934](https://github.com/EmbarkStudios/rust-gpu/pull/934) Removed `glam::BVec` support (they are no longer `#[repl(simd)]` in `glam`, as Rust doesn't support SIMD vectors with `bool` elements) ### Fixed 🩹 - - [PR#927](https://github.com/EmbarkStudios/rust-gpu/pull/927) re-taught Cargo to rebuild shader crates when `rustc_codegen_spirv` is rebuilt, via [`-Zbinary-dep-depinfo`](https://github.com/rust-lang/rust/pull/93969) (broken since a toolchain update in `0.4.0-alpha.13`, and has been causing spurious build failures ever since) ## [0.4.0-alpha.15] ### Added ⭐ - - [PR#919](https://github.com/EmbarkStudios/rust-gpu/pull/919) added a build-time check for the nightly toolchain version, to provide user-friendly error messages ### Changed πŸ› οΈ - - [PR#918](https://github.com/EmbarkStudios/rust-gpu/pull/918) updated toolchain to `nightly-2022-08-29` ## [0.4.0-alpha.14] ### Changed πŸ›  - - [PR#904](https://github.com/EmbarkStudios/rust-gpu/pull/904) renamed helper `spirv-types` crate to `spirv-std-types` ## [0.4.0-alpha.13] ### Added ⭐ - - [PR#717](https://github.com/EmbarkStudios/rust-gpu/pull/717) added `noreturn` support to inline `asm!` - [PR#742](https://github.com/EmbarkStudios/rust-gpu/pull/742) added a `spirv-builder` option to include all debug info - [PR#787](https://github.com/EmbarkStudios/rust-gpu/pull/787) documented `Cargo.toml` `[profile.β‹―.build-override]` setting for avoiding slow builds @@ -238,7 +209,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - new `spirv-std` APIs: `ByteAddressableBuffer`[#735](https://github.com/EmbarkStudios/rust-gpu/pull/735), `SampledImage::sample_by_lod`[#755](https://github.com/EmbarkStudios/rust-gpu/pull/755), `arch::read_clock_khr`[#757](https://github.com/EmbarkStudios/rust-gpu/pull/757), `arch::{signed,unsigned}_{min,max}`[#763](https://github.com/EmbarkStudios/rust-gpu/pull/763), `debug_printf!`[#768](https://github.com/EmbarkStudios/rust-gpu/pull/768), `arch::*memory_barrier*`[#769](https://github.com/EmbarkStudios/rust-gpu/pull/769), `arch::IndexUnchecked`[#805](https://github.com/EmbarkStudios/rust-gpu/pull/805), `RayQuery::confirm_intersection`[#822](https://github.com/EmbarkStudios/rust-gpu/pull/822), `arch::atomic_i_increment`[#839](https://github.com/EmbarkStudios/rust-gpu/pull/839), `arch::atomic`[#877](https://github.com/EmbarkStudios/rust-gpu/pull/877) ### Changed πŸ›  - - [PR#743](https://github.com/EmbarkStudios/rust-gpu/pull/743) set the SPIR-V "generator magic number" to [the value reserved for Rust-GPU](https://github.com/KhronosGroup/SPIRV-Headers/pull/174) - [PR#761](https://github.com/EmbarkStudios/rust-gpu/pull/761) made `spirv-std` build on stable Rust by avoiding `enum`s in `const`-generics - [PR#784](https://github.com/EmbarkStudios/rust-gpu/pull/784) documented `spirv-std` throughout @@ -247,7 +217,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [PR#888](https://github.com/EmbarkStudios/rust-gpu/pull/888) widened the supported `glam` version range to `0.17`-`0.21` ### Fixed 🩹 - - [PR#729](https://github.com/EmbarkStudios/rust-gpu/pull/729) fixed [#723](https://github.com/EmbarkStudios/rust-gpu/issues/723) by explicitly allowing unused shader inputs/outputs in storage class inference - [PR#732](https://github.com/EmbarkStudios/rust-gpu/pull/732) fixed `rustc` ICE messages being truncated with `rustc_codegen_spirv` (broken since a toolchain update in `0.4.0-alpha.12`) - [PR#737](https://github.com/EmbarkStudios/rust-gpu/pull/737) fixed [#642](https://github.com/EmbarkStudios/rust-gpu/issues/642) by re-adding `-Zsymbol-mangling-version=v0` (for generic parameters in `fn` names) @@ -258,28 +227,23 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [0.4.0-alpha.12] ### Added ⭐ - - [PR#704](https://github.com/EmbarkStudios/rust-gpu/pull/704) added `Image::gather` and `Image::sample_bias` to `spirv-std` - [PR#709](https://github.com/EmbarkStudios/rust-gpu/pull/709) added float packing/unpacking operations to `spirv-std` ### Changed πŸ›  - - [PR#716](https://github.com/EmbarkStudios/rust-gpu/pull/716) updated toolchain to `nightly-2021-08-10` ### Removed πŸ”₯ - - [PR#710](https://github.com/EmbarkStudios/rust-gpu/pull/710) removed "implicit bindless" and kernel modes ## [0.4.0-alpha.11] ### Changed πŸ›  - - [PR#702](https://github.com/EmbarkStudios/rust-gpu/pull/702) updated `glam` to `0.17` ## [0.4.0-alpha.10] ### Added ⭐ - - [PR#655](https://github.com/EmbarkStudios/rust-gpu/pull/655) added a `watch` feature to `spirv-builder` for hot reloading shaders - [PR#652](https://github.com/EmbarkStudios/rust-gpu/pull/652) documented `Image!` in the Rust-GPU book - [PR#660](https://github.com/EmbarkStudios/rust-gpu/pull/660) added a `spirv-builder` option to name global `OpVariables` @@ -287,24 +251,20 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [PR#683](https://github.com/EmbarkStudios/rust-gpu/pull/683) added a `spirv-builder` option to treat warnings as errors ### Changed πŸ›  - - [PR#672](https://github.com/EmbarkStudios/rust-gpu/pull/672) updated toolchain to `nightly-2021-06-09` - [PR#674](https://github.com/EmbarkStudios/rust-gpu/pull/674) updated `glam` to `0.16` ### Removed πŸ”₯ - - [PR#666](https://github.com/EmbarkStudios/rust-gpu/pull/666) removed `arch::arithmetic` from `spirv-std` ## [0.4.0-alpha.9] ### Fixed 🩹 - - fixed miscompilation in peephole optimizations (see [PR#646](https://github.com/EmbarkStudios/rust-gpu/pull/646)) ## [0.4.0-alpha.8] ### Added ⭐ - - [PR#608](https://github.com/EmbarkStudios/rust-gpu/pull/608) added `Image::query_*` operations to `spirv-std` - [PR#610](https://github.com/EmbarkStudios/rust-gpu/pull/610) added `spirv-builder` support for enabling extra extensions and/or capabilities - [PR#612](https://github.com/EmbarkStudios/rust-gpu/pull/612) added `is_helper_invocation` to `spirv-std` @@ -317,7 +277,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [PR#643](https://github.com/EmbarkStudios/rust-gpu/pull/643) added `Image::read_subpass` to `spirv-std` ### Changed πŸ›  - - [PR#616](https://github.com/EmbarkStudios/rust-gpu/pull/616) updated `spirv-tools` to `0.6.1` and turned on emission of line-based debug info - [PR#631](https://github.com/EmbarkStudios/rust-gpu/pull/631) updated toolchain to `nightly-2021-05-24` - [PR#641](https://github.com/EmbarkStudios/rust-gpu/pull/641) made `spirv-std` depend on `glam` (`0.15.2`), instead of the other way around @@ -325,13 +284,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [0.4.0-alpha.7] ### Fixed 🩹 - - [PR#607](https://github.com/EmbarkStudios/rust-gpu/pull/607) removed accidental use of `feature(or_patterns)` (recently stabilized, only on nightly) ## [0.4.0-alpha.6] ### Added ⭐ - - [PR#586](https://github.com/EmbarkStudios/rust-gpu/pull/586) added support for constant memory (`&'static _` references), within the limits of SPIR-V - [PR#559](https://github.com/EmbarkStudios/rust-gpu/pull/559) added the ability to set a Rust "target triple" in `spirv-builder` (e.g. `"spirv-unknown-vulkan1.1"` for Vulkan `1.1`) - [PR#563](https://github.com/EmbarkStudios/rust-gpu/pull/563) added `SPV_KHR_ray_tracing` APIs to `spirv-std` @@ -339,39 +296,32 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [PR#359](https://github.com/EmbarkStudios/rust-gpu/pull/359) added a `const`-generic `Image` type, and `Image!` macro wrapping it (to add "named parameters"), to `spirv-std` ### Changed πŸ›  - - [PR#587](https://github.com/EmbarkStudios/rust-gpu/pull/587) updated `glam` to `0.14` - [PR#605](https://github.com/EmbarkStudios/rust-gpu/pull/605) updated toolchain to `nightly-2021-04-25` ### Fixed 🩹 - - [PR#594](https://github.com/EmbarkStudios/rust-gpu/pull/594) fixed [#585](https://github.com/EmbarkStudios/rust-gpu/issues/585) by explicitly banning `Image`/`Sampler`/`SampledImage` entry-point parameters not behind references - [PR#598](https://github.com/EmbarkStudios/rust-gpu/pull/598) fixed [#581](https://github.com/EmbarkStudios/rust-gpu/issues/581) by switching `memory::Semantics` from an `enum` to a `bitflags!`, in `spirv-std` ## [0.4.0-alpha.5] ### Removed πŸ”₯ - - [PR#583](https://github.com/EmbarkStudios/rust-gpu/pull/583) removed `memcmp` from `spirv-std` ## [0.4.0-alpha.4] ### Added ⭐ - - [PR#519](https://github.com/EmbarkStudios/rust-gpu/pull/519) added `memory_barrier` and `control_barrier` to `spirv-std` ### Changed πŸ›  - - [PR#567](https://github.com/EmbarkStudios/rust-gpu/pull/567) removed the need to manually specify the storage class for `Image`/`Sampler`/`ImageSampler` entry-point parameters ### Deprecated 🚧 - - [PR#576](https://github.com/EmbarkStudios/rust-gpu/pull/576) deprecated `#[spirv(block)]` in favor of automatically wrapping the user types in "interface blocks" ## [0.4.0-alpha.3] ### Added ⭐ - - [PR#551](https://github.com/EmbarkStudios/rust-gpu/pull/551) added multi-module (one SPIR-V module per entry-point) support to `spirv-builder` - [PR#504](https://github.com/EmbarkStudios/rust-gpu/pull/504) added basic support for unsized `struct`s (e.g. ending with a `[T]` field) - [PR#545](https://github.com/EmbarkStudios/rust-gpu/pull/545) added `Image` methods for sampling depth reference and/or with project coordinate, to `spirv-std` @@ -379,23 +329,19 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [0.4.0-alpha.2] ### Added ⭐ - - [PR#541](https://github.com/EmbarkStudios/rust-gpu/pull/541) added `#[spirv(invariant)]` (like the `invariant` keyword in GLSL) ### Fixed 🩹 - - made `arch::derivative` functions public, in `spirv-std` ## [0.4.0-alpha.1] ### Added ⭐ - - [PR#498](https://github.com/EmbarkStudios/rust-gpu/pull/498) added `sample_by_lod`/`sample_by_gradient` image methods to `spirv-std` - [PR#521](https://github.com/EmbarkStudios/rust-gpu/pull/521) added `Cubemap` to `spirv-std` - [PR#520](https://github.com/EmbarkStudios/rust-gpu/pull/520) added `arch::primitive` functions to `spirv-std` ### Changed πŸ›  - - [PR#496](https://github.com/EmbarkStudios/rust-gpu/pull/496) updated `spirv-tools` to `0.5.0` - [PR#516](https://github.com/EmbarkStudios/rust-gpu/pull/516) updated toolchain to `nightly-2021-03-21` - [PR#443](https://github.com/EmbarkStudios/rust-gpu/pull/443) replaced `spirv_std::storage_class` "named pointer types" with `#[spirv(...)] &T` entry-point parameters @@ -403,18 +349,15 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [0.3.1] ### Added ⭐ - - [PR#480](https://github.com/EmbarkStudios/rust-gpu/pull/480) added a `fetch` image method to `spirv-std` - [PR#446](https://github.com/EmbarkStudios/rust-gpu/pull/446) added `arch::*` functions for all SPIR-V arithmetic operations (not involving matrices), to `spirv-std` ### Removed πŸ”₯ - - [PR#476](https://github.com/EmbarkStudios/rust-gpu/pull/476) removed `glam` as a dependency of `spirv-std` ## [0.3.0] ### Added ⭐ - - [PR#414](https://github.com/EmbarkStudios/rust-gpu/pull/414) added storage class type inference - [PR#469](https://github.com/EmbarkStudios/rust-gpu/pull/469) added initial support for Algebraic Data Type enums (e.g. `Option`) - [PR#421](https://github.com/EmbarkStudios/rust-gpu/pull/421) added ability to provide `const` arguments to `asm!` @@ -428,7 +371,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - new `spirv-std` APIs: `vector_extract_dynamic`[PR#394](https://github.com/EmbarkStudios/rust-gpu/pull/394), `vector_insert_dynamic`[PR#411](https://github.com/EmbarkStudios/rust-gpu/pull/411), `textures::StorageImage2d`[PR#434](https://github.com/EmbarkStudios/rust-gpu/pull/434), `any`/`all`[PR#380](https://github.com/EmbarkStudios/rust-gpu/pull/441), `discard`[PR#441](https://github.com/EmbarkStudios/rust-gpu/pull/380), `demote_to_helper_invocation`[PR#380](https://github.com/EmbarkStudios/rust-gpu/pull/380), ``SampledImage``[PR#320](https://github.com/EmbarkStudios/rust-gpu/pull/320) ### Changed πŸ›  - - [PR#461](https://github.com/EmbarkStudios/rust-gpu/pull/461) removed requirement of `#[allow(unused_attributes)]` in front of `#[spirv]` attributes to remove warnings - [PR#398](https://github.com/EmbarkStudios/rust-gpu/pull/398) `rustc_codegen_spirv` now removes different `OpName`s that target the same ID - [PR#396](https://github.com/EmbarkStudios/rust-gpu/pull/396) `rustc_codegen_spirv` now tries to deduplicate generated `OpVariable`s @@ -436,7 +378,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [0.2.0] ### Added ⭐ - - [PR#287](https://github.com/EmbarkStudios/rust-gpu/pull/287) added a new structurizer, which means that you can now use `match` expressions and `continue`s - [PR#317](https://github.com/EmbarkStudios/rust-gpu/pull/317) added the `#[spirv(flat)]` attribute that matches SPIR-V's "Flat" decorator. - [PR#276](https://github.com/EmbarkStudios/rust-gpu/pull/276) added support for textures. @@ -447,7 +388,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [PR#254](https://github.com/EmbarkStudios/rust-gpu/pull/254) added initial support in Rust and `rust-gpu` for inline SPIR-V with the `asm!` nightly feature ### Changed πŸ›  - - [PR#219](https://github.com/EmbarkStudios/rust-gpu/pull/219) improvements to error messages regarding constant pointers - [PR#280](https://github.com/EmbarkStudios/rust-gpu/pull/280) all Storage Classes (e.g. `Input`/`Output`) are now defined in `spirv_std::storage_class` - [PR#275](https://github.com/EmbarkStudios/rust-gpu/pull/275) Rust's language items such `rust_eh_personality` and `panic_handler` are now defined in `spirv-std` for SPIR-V targets