Update naga to gfx-21

This commit is contained in:
Dzmitry Malyshau 2021-04-11 01:07:46 -04:00
parent 4c61a910fc
commit 1ba95585ba
3 changed files with 27 additions and 32 deletions

20
Cargo.lock generated
View File

@ -465,7 +465,7 @@ dependencies = [
[[package]]
name = "gfx-auxil"
version = "0.8.0"
source = "git+https://github.com/gfx-rs/gfx?rev=3ee1ca9ba486b166a52765024d8d149cbb28d486#3ee1ca9ba486b166a52765024d8d149cbb28d486"
source = "git+https://github.com/gfx-rs/gfx?rev=f4288c56e586e69d96d2eaa98404382cd55d759b#f4288c56e586e69d96d2eaa98404382cd55d759b"
dependencies = [
"fxhash",
"gfx-hal",
@ -475,7 +475,7 @@ dependencies = [
[[package]]
name = "gfx-backend-dx11"
version = "0.7.0"
source = "git+https://github.com/gfx-rs/gfx?rev=3ee1ca9ba486b166a52765024d8d149cbb28d486#3ee1ca9ba486b166a52765024d8d149cbb28d486"
source = "git+https://github.com/gfx-rs/gfx?rev=f4288c56e586e69d96d2eaa98404382cd55d759b#f4288c56e586e69d96d2eaa98404382cd55d759b"
dependencies = [
"arrayvec",
"bitflags",
@ -496,7 +496,7 @@ dependencies = [
[[package]]
name = "gfx-backend-dx12"
version = "0.7.0"
source = "git+https://github.com/gfx-rs/gfx?rev=3ee1ca9ba486b166a52765024d8d149cbb28d486#3ee1ca9ba486b166a52765024d8d149cbb28d486"
source = "git+https://github.com/gfx-rs/gfx?rev=f4288c56e586e69d96d2eaa98404382cd55d759b#f4288c56e586e69d96d2eaa98404382cd55d759b"
dependencies = [
"arrayvec",
"bit-set",
@ -517,7 +517,7 @@ dependencies = [
[[package]]
name = "gfx-backend-empty"
version = "0.7.0"
source = "git+https://github.com/gfx-rs/gfx?rev=3ee1ca9ba486b166a52765024d8d149cbb28d486#3ee1ca9ba486b166a52765024d8d149cbb28d486"
source = "git+https://github.com/gfx-rs/gfx?rev=f4288c56e586e69d96d2eaa98404382cd55d759b#f4288c56e586e69d96d2eaa98404382cd55d759b"
dependencies = [
"gfx-hal",
"log",
@ -527,7 +527,7 @@ dependencies = [
[[package]]
name = "gfx-backend-gl"
version = "0.7.0"
source = "git+https://github.com/gfx-rs/gfx?rev=3ee1ca9ba486b166a52765024d8d149cbb28d486#3ee1ca9ba486b166a52765024d8d149cbb28d486"
source = "git+https://github.com/gfx-rs/gfx?rev=f4288c56e586e69d96d2eaa98404382cd55d759b#f4288c56e586e69d96d2eaa98404382cd55d759b"
dependencies = [
"arrayvec",
"bitflags",
@ -550,7 +550,7 @@ dependencies = [
[[package]]
name = "gfx-backend-metal"
version = "0.7.0"
source = "git+https://github.com/gfx-rs/gfx?rev=3ee1ca9ba486b166a52765024d8d149cbb28d486#3ee1ca9ba486b166a52765024d8d149cbb28d486"
source = "git+https://github.com/gfx-rs/gfx?rev=f4288c56e586e69d96d2eaa98404382cd55d759b#f4288c56e586e69d96d2eaa98404382cd55d759b"
dependencies = [
"arrayvec",
"bitflags",
@ -575,7 +575,7 @@ dependencies = [
[[package]]
name = "gfx-backend-vulkan"
version = "0.7.0"
source = "git+https://github.com/gfx-rs/gfx?rev=3ee1ca9ba486b166a52765024d8d149cbb28d486#3ee1ca9ba486b166a52765024d8d149cbb28d486"
source = "git+https://github.com/gfx-rs/gfx?rev=f4288c56e586e69d96d2eaa98404382cd55d759b#f4288c56e586e69d96d2eaa98404382cd55d759b"
dependencies = [
"arrayvec",
"ash",
@ -595,7 +595,7 @@ dependencies = [
[[package]]
name = "gfx-hal"
version = "0.7.0"
source = "git+https://github.com/gfx-rs/gfx?rev=3ee1ca9ba486b166a52765024d8d149cbb28d486#3ee1ca9ba486b166a52765024d8d149cbb28d486"
source = "git+https://github.com/gfx-rs/gfx?rev=f4288c56e586e69d96d2eaa98404382cd55d759b#f4288c56e586e69d96d2eaa98404382cd55d759b"
dependencies = [
"bitflags",
"naga",
@ -916,7 +916,7 @@ dependencies = [
[[package]]
name = "naga"
version = "0.3.1"
source = "git+https://github.com/gfx-rs/naga?tag=gfx-20#0369ee181ed9cd315635fc0e3d99deecdbc72246"
source = "git+https://github.com/gfx-rs/naga?tag=gfx-21#98252cf5d29790f85cc4397e0cf7a5b6cfaac614"
dependencies = [
"bit-set",
"bitflags",
@ -1171,7 +1171,7 @@ dependencies = [
[[package]]
name = "range-alloc"
version = "0.1.2"
source = "git+https://github.com/gfx-rs/gfx?rev=3ee1ca9ba486b166a52765024d8d149cbb28d486#3ee1ca9ba486b166a52765024d8d149cbb28d486"
source = "git+https://github.com/gfx-rs/gfx?rev=f4288c56e586e69d96d2eaa98404382cd55d759b#f4288c56e586e69d96d2eaa98404382cd55d759b"
[[package]]
name = "raw-window-handle"

View File

@ -40,28 +40,28 @@ thiserror = "1"
gpu-alloc = { git = "https://github.com/zakarumych/gpu-alloc.git", rev = "2cd1ad650cdd24d1647b6041f77ced0cbf1ff2a6" }
gpu-descriptor = { version = "0.1" }
hal = { package = "gfx-hal", git = "https://github.com/gfx-rs/gfx", rev = "3ee1ca9ba486b166a52765024d8d149cbb28d486" }
gfx-backend-empty = { git = "https://github.com/gfx-rs/gfx", rev = "3ee1ca9ba486b166a52765024d8d149cbb28d486" }
hal = { package = "gfx-hal", git = "https://github.com/gfx-rs/gfx", rev = "f4288c56e586e69d96d2eaa98404382cd55d759b" }
gfx-backend-empty = { git = "https://github.com/gfx-rs/gfx", rev = "f4288c56e586e69d96d2eaa98404382cd55d759b" }
[target.'cfg(all(not(target_arch = "wasm32"), all(unix, not(target_os = "ios"), not(target_os = "macos"))))'.dependencies]
gfx-backend-vulkan = { git = "https://github.com/gfx-rs/gfx", rev = "3ee1ca9ba486b166a52765024d8d149cbb28d486", features = ["naga"] }
gfx-backend-gl = { git = "https://github.com/gfx-rs/gfx", rev = "3ee1ca9ba486b166a52765024d8d149cbb28d486" }
gfx-backend-vulkan = { git = "https://github.com/gfx-rs/gfx", rev = "f4288c56e586e69d96d2eaa98404382cd55d759b", features = ["naga"] }
gfx-backend-gl = { git = "https://github.com/gfx-rs/gfx", rev = "f4288c56e586e69d96d2eaa98404382cd55d759b" }
[target.'cfg(all(not(target_arch = "wasm32"), any(target_os = "ios", target_os = "macos")))'.dependencies]
gfx-backend-metal = { git = "https://github.com/gfx-rs/gfx", rev = "3ee1ca9ba486b166a52765024d8d149cbb28d486" }
gfx-backend-vulkan = { git = "https://github.com/gfx-rs/gfx", rev = "3ee1ca9ba486b166a52765024d8d149cbb28d486", optional = true }
gfx-backend-metal = { git = "https://github.com/gfx-rs/gfx", rev = "f4288c56e586e69d96d2eaa98404382cd55d759b" }
gfx-backend-vulkan = { git = "https://github.com/gfx-rs/gfx", rev = "f4288c56e586e69d96d2eaa98404382cd55d759b", optional = true }
[target.'cfg(all(not(target_arch = "wasm32"), windows))'.dependencies]
gfx-backend-dx12 = { git = "https://github.com/gfx-rs/gfx", rev = "3ee1ca9ba486b166a52765024d8d149cbb28d486" }
gfx-backend-dx11 = { git = "https://github.com/gfx-rs/gfx", rev = "3ee1ca9ba486b166a52765024d8d149cbb28d486" }
gfx-backend-vulkan = { git = "https://github.com/gfx-rs/gfx", rev = "3ee1ca9ba486b166a52765024d8d149cbb28d486", features = ["naga"] }
gfx-backend-dx12 = { git = "https://github.com/gfx-rs/gfx", rev = "f4288c56e586e69d96d2eaa98404382cd55d759b" }
gfx-backend-dx11 = { git = "https://github.com/gfx-rs/gfx", rev = "f4288c56e586e69d96d2eaa98404382cd55d759b" }
gfx-backend-vulkan = { git = "https://github.com/gfx-rs/gfx", rev = "f4288c56e586e69d96d2eaa98404382cd55d759b", features = ["naga"] }
[target.'cfg(target_arch = "wasm32")'.dependencies]
gfx-backend-gl = { git = "https://github.com/gfx-rs/gfx", rev = "3ee1ca9ba486b166a52765024d8d149cbb28d486" }
gfx-backend-gl = { git = "https://github.com/gfx-rs/gfx", rev = "f4288c56e586e69d96d2eaa98404382cd55d759b" }
[dependencies.naga]
git = "https://github.com/gfx-rs/naga"
tag = "gfx-20"
tag = "gfx-21"
features = ["spv-in", "spv-out", "wgsl-in"]
[dependencies.wgt]

View File

@ -651,10 +651,7 @@ impl Interface {
kind: naga::ScalarKind::Float,
width,
},
naga::TypeInner::Struct {
block: _,
ref members,
} => {
naga::TypeInner::Struct { ref members, .. } => {
for member in members {
Self::populate(list, member.binding.as_ref(), member.ty, arena);
}
@ -690,14 +687,12 @@ impl Interface {
};
let ty = match module.types[var.ty].inner {
naga::TypeInner::Struct {
block: true,
level: naga::StructLevel::Root,
members: _,
} => {
let actual_size = info.layouter[var.ty].size;
ResourceType::Buffer {
size: wgt::BufferSize::new(actual_size as u64).unwrap(),
}
}
span,
} => ResourceType::Buffer {
size: wgt::BufferSize::new(span as u64).unwrap(),
},
naga::TypeInner::Image {
dim,
arrayed,