2022-11-20 03:45:42 +11:00
|
|
|
// SPDX-License-Identifier: Apache-2.0 OR MIT OR Unlicense
|
2022-10-29 06:01:15 +11:00
|
|
|
|
2023-01-18 06:08:20 +11:00
|
|
|
// Bitflags for each stage that can fail allocation.
|
|
|
|
let STAGE_BINNING: u32 = 0x1u;
|
|
|
|
let STAGE_TILE_ALLOC: u32 = 0x2u;
|
|
|
|
let STAGE_PATH_COARSE: u32 = 0x4u;
|
|
|
|
let STAGE_COARSE: u32 = 0x8u;
|
|
|
|
|
2023-01-18 14:51:46 +11:00
|
|
|
// This must be kept in sync with the struct in src/render.rs
|
2022-10-29 06:01:15 +11:00
|
|
|
struct BumpAllocators {
|
2023-01-18 06:08:20 +11:00
|
|
|
// Bitmask of stages that have failed allocation.
|
|
|
|
failed: atomic<u32>,
|
2022-10-29 06:01:15 +11:00
|
|
|
binning: atomic<u32>,
|
|
|
|
ptcl: atomic<u32>,
|
2022-11-02 10:20:15 +11:00
|
|
|
tile: atomic<u32>,
|
2022-11-04 13:33:11 +11:00
|
|
|
segments: atomic<u32>,
|
2023-01-18 06:08:20 +11:00
|
|
|
blend: atomic<u32>,
|
2022-10-29 06:01:15 +11:00
|
|
|
}
|