Skip to content

Commit

Permalink
Merge branch 'trunk' into un/packInt
Browse files Browse the repository at this point in the history
  • Loading branch information
VlaDexa authored Apr 12, 2024
2 parents 27ecb13 + 9df6819 commit b0967e7
Show file tree
Hide file tree
Showing 34 changed files with 1,896 additions and 389 deletions.
279 changes: 140 additions & 139 deletions Cargo.lock

Large diffs are not rendered by default.

20 changes: 10 additions & 10 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -45,27 +45,27 @@ keywords = ["graphics"]
license = "MIT OR Apache-2.0"
homepage = "https://wgpu.rs/"
repository = "https://github.com/gfx-rs/wgpu"
version = "0.19.0"
version = "0.19.3"
authors = ["gfx-rs developers"]

[workspace.dependencies.wgc]
package = "wgpu-core"
path = "./wgpu-core"
version = "0.19.0"
version = "0.19.3"

[workspace.dependencies.wgt]
package = "wgpu-types"
path = "./wgpu-types"
version = "0.19.0"
version = "0.19.2"

[workspace.dependencies.hal]
package = "wgpu-hal"
path = "./wgpu-hal"
version = "0.19.0"
version = "0.19.3"

[workspace.dependencies.naga]
path = "./naga"
version = "0.19.0"
version = "0.19.2"

[workspace.dependencies]
anyhow = "1.0"
Expand Down Expand Up @@ -114,16 +114,16 @@ renderdoc-sys = "1.1.0"
ron = "0.8"
rustc-hash = "1.1.0"
serde = "1"
serde_json = "1.0.113"
serde_json = "1.0.115"
smallvec = "1"
static_assertions = "1.1.0"
thiserror = "1"
wgpu = { version = "0.19.0", path = "./wgpu" }
wgpu-core = { version = "0.19.0", path = "./wgpu-core" }
wgpu = { version = "0.19.3", path = "./wgpu" }
wgpu-core = { version = "0.19.3", path = "./wgpu-core" }
wgpu-example = { version = "0.19.0", path = "./examples/common" }
wgpu-macros = { version = "0.19.0", path = "./wgpu-macros" }
wgpu-test = { version = "0.19.0", path = "./tests" }
wgpu-types = { version = "0.19.0", path = "./wgpu-types" }
wgpu-types = { version = "0.19.2", path = "./wgpu-types" }
winit = { version = "0.29", features = ["android-native-activity"] }

# Metal dependencies
Expand Down Expand Up @@ -171,7 +171,7 @@ deno_url = "0.143.0"
deno_web = "0.174.0"
deno_webidl = "0.143.0"
deno_webgpu = { version = "0.110.0", path = "./deno_webgpu" }
tokio = "1.36.0"
tokio = "1.37.0"
termcolor = "1.4.1"

[patch."https://github.com/gfx-rs/naga"]
Expand Down
14 changes: 2 additions & 12 deletions examples/src/water/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -834,18 +834,8 @@ static TEST: crate::framework::ExampleTestParams = crate::framework::ExampleTest
// To be fixed in <https://github.com/gfx-rs/wgpu/issues/5231>.
.expect_fail(wgpu_test::FailureCase {
backends: Some(wgpu::Backends::VULKAN),
reasons: vec![
wgpu_test::FailureReason::validation_error().with_message(concat!(
"vkCmdEndRenderPass: ",
"Hazard WRITE_AFTER_READ in subpass 0 for attachment 1 depth aspect ",
"during store with storeOp VK_ATTACHMENT_STORE_OP_STORE. ",
"Access info (",
"usage: SYNC_LATE_FRAGMENT_TESTS_DEPTH_STENCIL_ATTACHMENT_WRITE, ",
"prior_usage: SYNC_FRAGMENT_SHADER_SHADER_SAMPLED_READ, ",
"read_barriers: VkPipelineStageFlags2(0), ",
"command: vkCmdDraw"
)),
],
reasons: vec![wgpu_test::FailureReason::validation_error()
.with_message(concat!("Hazard WRITE_AFTER_"))],
behavior: wgpu_test::FailureBehavior::AssertFailure,
..Default::default()
}),
Expand Down
4 changes: 2 additions & 2 deletions naga/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "naga"
version = "0.19.0"
version = "0.19.2"
authors = ["gfx-rs developers"]
edition = "2021"
description = "Shader translation infrastructure"
Expand Down Expand Up @@ -41,7 +41,7 @@ harness = false

[dependencies]
arbitrary = { version = "1.3", features = ["derive"], optional = true }
bitflags = "2.4"
bitflags = "2.5"
bit-set = "0.5"
termcolor = { version = "1.4.1" }
# remove termcolor dep when updating to the next version of codespan-reporting
Expand Down
6 changes: 4 additions & 2 deletions naga/src/front/spv/error.rs
Original file line number Diff line number Diff line change
Expand Up @@ -118,8 +118,8 @@ pub enum Error {
ControlFlowGraphCycle(crate::front::spv::BlockId),
#[error("recursive function call %{0}")]
FunctionCallCycle(spirv::Word),
#[error("invalid array size {0:?}")]
InvalidArraySize(Handle<crate::Constant>),
#[error("invalid array size %{0}")]
InvalidArraySize(spirv::Word),
#[error("invalid barrier scope %{0}")]
InvalidBarrierScope(spirv::Word),
#[error("invalid barrier memory semantics %{0}")]
Expand All @@ -130,6 +130,8 @@ pub enum Error {
come from a binding)"
)]
NonBindingArrayOfImageOrSamplers,
#[error("naga only supports specialization constant IDs up to 65535 but was given {0}")]
SpecIdTooHigh(u32),
}

impl Error {
Expand Down
7 changes: 5 additions & 2 deletions naga/src/front/spv/function.rs
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,11 @@ impl<I: Iterator<Item = u32>> super::Frontend<I> {
})
},
local_variables: Arena::new(),
expressions: self
.make_expression_storage(&module.global_variables, &module.constants),
expressions: self.make_expression_storage(
&module.global_variables,
&module.constants,
&module.overrides,
),
named_expressions: crate::NamedExpressions::default(),
body: crate::Block::new(),
}
Expand Down
13 changes: 8 additions & 5 deletions naga/src/front/spv/image.rs
Original file line number Diff line number Diff line change
Expand Up @@ -507,11 +507,14 @@ impl<I: Iterator<Item = u32>> super::Frontend<I> {
}
spirv::ImageOperands::CONST_OFFSET => {
let offset_constant = self.next()?;
let offset_handle = self.lookup_constant.lookup(offset_constant)?.handle;
let offset_handle = ctx.global_expressions.append(
crate::Expression::Constant(offset_handle),
Default::default(),
);
let offset_expr = self
.lookup_constant
.lookup(offset_constant)?
.inner
.to_expr();
let offset_handle = ctx
.global_expressions
.append(offset_expr, Default::default());
offset = Some(offset_handle);
words_left -= 1;
}
Expand Down
Loading

0 comments on commit b0967e7

Please sign in to comment.