#asahi-gpu · 2023-02-14 03:48
alyssahi = hi + u64_hi#asahi-gpu · 2023-02-14 03:48
alyssalo_hi = mad(u32, u32, u64_lo)#asahi-gpu · 2023-02-14 03:48
alyssathey implement (u32 * u32) + u64 in two instructions#asahi-gpu · 2023-02-14 03:47
alyssaI see what's happening. cute.#asahi-gpu · 2023-02-14 03:47
alyssaoh, no#asahi-gpu · 2023-02-14 03:47
alyssaor not, uh#asahi-gpu · 2023-02-14 03:41
alyssa(Spoiler alert: bindless image writes are 100% a thing and it's a straightforward mechanism and I just need a bit more staring to get the details)#asahi-gpu · 2023-02-14 03:41
alyssafrom context of the shader I'm staring at#asahi-gpu · 2023-02-14 03:40
alyssaI *think* the u2 should be u2_u3..#asahi-gpu · 2023-02-14 03:40
alyssa 16: 9e138c0202840100 imadd r4_r5.cache, r6.cache, 32, u2#asahi-gpu · 2023-02-12 17:23
alyssaif you're not setting those =true explicitly in AGXV, please do so#asahi-gpu · 2023-02-12 17:23
alyssaella-0: https://rosenzweig.io/0001-asahi-Remove-default-true-on-index-list-values.patch#asahi-gpu · 2023-02-12 13:33
karolherbstlina: probably needs patches... #asahi-gpu · 2023-02-12 13:15
linaThe problem with 4K kernels is that I have no way to tell the GEM shmem backend to allocate in contiguous 16K pages...#asahi-gpu · 2023-02-12 09:57
dhewgalyssa: nice, thanks! I would have guessed there's way more to be done before even considering nine#asahi-gpu · 2023-02-12 03:18
alyssauniversity calls~#asahi-gpu · 2023-02-12 03:17
alyssaunfortunately I think that's time for the weekend#asahi-gpu · 2023-02-12 03:17
alyssathere's plenty of room in the image_write encoding for a samplerureg, just a matter of finding it#asahi-gpu · 2023-02-12 02:14
alyssaI don't understand the various Vulkan extensions well enough to know if this is a problem#asahi-gpu · 2023-02-12 02:14
alyssahttps://developer.apple.com/documentation/metal/mtlsamplerdescriptor/2915782-supportargumentbuffers?language=objc#asahi-gpu · 2023-02-12 02:13
alyssathis corresponds to the limit of 2048 samplers allowed in argument buffers in metal#asahi-gpu · 2023-02-12 02:13
alyssa(because now the sampler descriptor is 5 words -> round up to 8 words for a power-of-two limit)#asahi-gpu · 2023-02-12 02:13
alyssaif custom border colours are allowed, we only get (conservatively) 2048 samplers#asahi-gpu · 2023-02-12 02:12
alyssai.e. we only get to set the bottom 16-bits of the pointer ourselves#asahi-gpu · 2023-02-12 02:12
alyssaalso, it looks like -- while textures are full bindless -- samplers are basically a heap with maximum size 8192#asahi-gpu · 2023-02-12 01:41
alyssabut I guess bumping M1 to 13.x firmware to get the fancy features isn't the worst thing in the world #asahi-gpu · 2023-02-12 01:40
alyssabut mesh isn't added until Metal 3 == macOS 13#asahi-gpu · 2023-02-12 01:40
alyssaAt least, I'm not convinced it gets used for geometry or tessellation shaders on Apple's driver, though it's definitely needed for mesh#asahi-gpu · 2023-02-12 01:40
alyssalina: I think the firmware allocation feature I mentioned might not be added until macOS 13#asahi-gpu · 2023-02-11 20:07
alyssalest this all be purely theoretical#asahi-gpu · 2023-02-11 20:07
alyssakicking the can down the line until we have 4K pages#asahi-gpu · 2023-02-11 20:06
alyssadamned if you do, damned if you dont#asahi-gpu · 2023-02-11 20:06
alyssayeah I am still waffling#asahi-gpu · 2023-02-11 20:06
alyssawhich isn't ideal#asahi-gpu · 2023-02-11 20:05
alyssaThe fighting comes with something like glBitmap + glClipControl used together#asahi-gpu · 2023-02-11 20:04
alyssaMeh. Will do the flushing option to light up the CAP and then when we actually have workloads we can optimize#asahi-gpu · 2023-02-11 20:03
alyssawhich violates the "only pay for what you use" rule#asahi-gpu · 2023-02-11 20:03
alyssathe annoyance there is that it would then add overhead to all GL apps#asahi-gpu · 2023-02-11 20:03
alyssaTempted to just go the shader variant + lower_clip_halfz route since it would be parity with Zink#asahi-gpu · 2023-02-11 20:02
alyssaFor native GL, the flush is a bit cleaner but would require caution to ensure we don't flush unnecessarily with stuff like u_blitter#asahi-gpu · 2023-02-11 20:01
alyssaAnd then Zink on top of a VK_EXT_depth_clip_control driver will end up creating pipeline variants#asahi-gpu · 2023-02-11 20:00
alyssaFor VK_EXT_depth_clip_control, the bit is pipeline state. Flushing isn't an option but there's no dynamic state needed: just fix the [0, 1] clip space by default and insert the fix up code for Zink.#asahi-gpu · 2023-02-11 20:00
alyssaHonestly unsure which approach I hate least (shader variants, dynamic state, flushing)#asahi-gpu · 2023-02-11 19:54
alyssa"Because this bit is render pass state, we can’t use it to change the clip space between draws. That’s okay for baseline OpenGL and Vulkan, but it prevents us from efficiently implementing the ARB_clip_control and VK_EXT_depth_clip_control extensions. There are at least three (inefficient) implementations."#asahi-gpu · 2023-02-11 19:53
alyssawrote up the issue ad nauseum there#asahi-gpu · 2023-02-11 19:53
alyssahttps://rosenzweig.io/blog/asahi-gpu-part-6.html#asahi-gpu · 2023-02-11 19:52
alyssawhich isn't hard but there are two ways to square the circle and they both suck#asahi-gpu · 2023-02-11 19:52
alyssamostly blocked on clip control#asahi-gpu · 2023-02-11 19:49
alyssaonce 4K pages are supported by the gpu driver, I'll probably give FEX + Wine + Nine a whirl#asahi-gpu · 2023-02-11 19:11
alyssadhewg: nine support isn't going to be hard, I'm just waiting for the page size mess to get sorted