Open bvisness opened 4 months ago
Fixed by ffc3c8a1.
Buffer size limits where using u32
, but the webgpu implementation on M1 has a limit of 4GB (ie it overflows u32 size by one), and the oc_wgpu_canvas_encode_batch
inner loop is done in such a way that we were looping indefinitely over the start of the buffer, allocating memory from the scratch arena at each iteration.
As a quick fix I changed the buffer max size computation to u64. But we should take better measures to prevent this kind of problem:
On my M1 MacBook Air, the Breakout, Clock, and UI samples all present a blank screen and start using extreme amounts of real memory (growing to many gigabytes before my computer complains).