Skip to content

Commit eb02c64

Browse files
authored
Upgrade to WGPU 27.x (#101)
1 parent 9640718 commit eb02c64

File tree

8 files changed

+53
-39
lines changed

8 files changed

+53
-39
lines changed

Cargo.lock

Lines changed: 43 additions & 29 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "wgpu-profiler"
3-
version = "0.24.0"
3+
version = "0.25.0"
44
authors = ["Andreas Reich <r_andreas2@web.de>"]
55
edition = "2021"
66
description = "Simple profiler scopes for wgpu using timer queries"
@@ -21,7 +21,7 @@ puffin = ["dep:puffin", "profiling/profile-with-puffin"]
2121
[dependencies]
2222
parking_lot = "0.12" # Used for Mutex & RwLock. Note that wgpu already depends on parking_lot as well.
2323
thiserror = "2"
24-
wgpu = { version = "26.0.0", default-features = false }
24+
wgpu = { version = "27.0.0", default-features = false }
2525

2626
tracy-client = { version = "0.18", optional = true }
2727
puffin = { version = "0.19.1", optional = true }
@@ -31,5 +31,5 @@ futures-lite = "2"
3131
profiling = "1"
3232
puffin_http = "0.16.1"
3333
tracy-client = "0.18"
34-
wgpu = { version = "26.0.0", default-features = true }
34+
wgpu = { version = "27.0.0", default-features = true }
3535
winit = "0.30"

src/tracy.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ pub fn create_tracy_gpu_client(
3939
queue.submit([timestamp_encoder.finish(), copy_encoder.finish()]);
4040

4141
map_buffer.slice(..).map_async(wgpu::MapMode::Read, |_| ());
42-
device.poll(wgpu::PollType::Wait).unwrap();
42+
device.poll(wgpu::PollType::wait_indefinitely()).unwrap();
4343

4444
let view = map_buffer.slice(..).get_mapped_range();
4545
let timestamp: i64 = i64::from_le_bytes((*view).try_into().unwrap());

tests/src/dropped_frame_handling.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ fn handle_dropped_frames_gracefully() {
3636
}
3737

3838
// Poll to explicitly trigger mapping callbacks.
39-
device.poll(wgpu::PollType::Wait).unwrap();
39+
device.poll(wgpu::PollType::wait_indefinitely()).unwrap();
4040

4141
// A single (!) frame should now be available.
4242
assert!(profiler

tests/src/errors.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ fn end_frame_unresolved_query() {
7878
}
7979
assert_eq!(profiler.end_frame(), Ok(()));
8080

81-
device.poll(wgpu::PollType::Wait).unwrap();
81+
device.poll(wgpu::PollType::wait_indefinitely()).unwrap();
8282
}
8383

8484
#[test]

tests/src/interleaved_command_buffer.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ fn interleaved_scopes() {
2626
queue.submit([encoder1.finish(), encoder0.finish()]);
2727
profiler.end_frame().unwrap();
2828

29-
device.poll(wgpu::PollType::Wait).unwrap();
29+
device.poll(wgpu::PollType::wait_indefinitely()).unwrap();
3030

3131
// Single frame should now be available.
3232
let frame = profiler
@@ -102,7 +102,7 @@ fn multithreaded_scopes() {
102102
queue.submit([command_buffer0, command_buffer1, resolve_encoder.finish()]);
103103
profiler.end_frame().unwrap();
104104

105-
device.poll(wgpu::PollType::Wait).unwrap();
105+
device.poll(wgpu::PollType::wait_indefinitely()).unwrap();
106106

107107
// Single frame should now be available.
108108
let frame = profiler

tests/src/multiple_resolves_per_frame.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ fn multiple_resolves_per_frame() {
3434
}
3535

3636
// Poll to explicitly trigger mapping callbacks.
37-
device.poll(wgpu::PollType::Wait).unwrap();
37+
device.poll(wgpu::PollType::wait_indefinitely()).unwrap();
3838

3939
// Frame should now be available and contain all the scopes.
4040
let scopes = profiler

tests/src/nested_scopes.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ fn nested_scopes(device: &wgpu::Device, queue: &wgpu::Queue) {
6060
queue.submit([encoder0.finish(), encoder1.finish(), encoder2.finish()]);
6161
profiler.end_frame().unwrap();
6262

63-
device.poll(wgpu::PollType::Wait).unwrap();
63+
device.poll(wgpu::PollType::wait_indefinitely()).unwrap();
6464

6565
// Single frame should now be available.
6666
let frame = profiler

0 commit comments

Comments
 (0)