#asahi-gpu · 2022-12-13 19:19
alyssai really need to start an "easy task board" and get Lina in the reviewing loop too#asahi-gpu · 2022-12-13 19:19
joskeToo late already 😁#asahi-gpu · 2022-12-13 19:04
iaguisalyssa: I'd be happy to help. I hope I'm not overstepping here, but I know some C and I _think_ I ported the logic right. I've only tested that it compiles and I don't have much context on the code semantics. Anyway, it's here: https://gitlab.freedesktop.org/iaguis/mesa/-/commit/456bd9fc2aec3c51cce28a480581c6158312caf2 and I can file a MR if it looks ok#asahi-gpu · 2022-12-13 18:52
DcowBut I would appreciate if you gonna dump some other tasks in the future to give me more chances #asahi-gpu · 2022-12-13 18:52
DcowEh...I would jump at this task, but so much going on already. Gonna move to another country in a ~week and $work not making it easy #asahi-gpu · 2022-12-13 18:40
joskealyssa: I'll have a go at that if nobody beats me to it#asahi-gpu · 2022-12-13 16:19
alyssa^ That change to Panfrost needs to be ported to Asahi (which originally copied the buggy Panfrost code)#asahi-gpu · 2022-12-13 16:19
alyssahttps://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20285#asahi-gpu · 2022-12-13 16:19
alyssaAnyone want an easy Mesa task?#asahi-gpu · 2022-12-08 23:09
alyssaso there's the relevant info, if jannau or lina or anyone else wants to write the fix#asahi-gpu · 2022-12-08 23:09
alyssaanyway I'm supposed to be on break right now but I was eating dinner and it clicked what was going wrong#asahi-gpu · 2022-12-08 23:08
alyssaonce in a patch to shrink the default encoder size, such that instead of allocating 0x80000 we only allocate 64k and then we end up hitting this issue at much smaller draw call counts, once in drawoverhead#asahi-gpu · 2022-12-08 23:07
alyssaand come to think of it I've actually hit this bug twice and not debugged in either case because I thought it was something else#asahi-gpu · 2022-12-08 23:07
alyssa10k fish at aquarium would probably hit it, 1k would probably not#asahi-gpu · 2022-12-08 23:06
alyssawhich explains how I missed it#asahi-gpu · 2022-12-08 23:06
alyssathis code path only triggers at high draw call counts#asahi-gpu · 2022-12-08 23:05
alyssaHere we allocating with 256 alignment, but maybe we need more than that#asahi-gpu · 2022-12-08 23:05
alyssahttps://gitlab.freedesktop.org/asahi/mesa/-/blob/main/src/gallium/drivers/asahi/agx_state.c#L2037#asahi-gpu · 2022-12-08 23:04
alyssabut it's possible there is a heavier alignment requirement#asahi-gpu · 2022-12-08 23:04
alyssathis indicates that the control stream ("encoder") is allocated as regular memory. so not the 32-bit thing#asahi-gpu · 2022-12-08 23:04
alyssahttps://gitlab.freedesktop.org/asahi/mesa/-/blob/main/src/gallium/drivers/asahi/agx_batch.c#L48#asahi-gpu · 2022-12-08 23:03
alyssaassert(batch_encoder_current + AGX_VDM_STREAM_LINK_LENGTH <= batch->encoder_end && "...")#asahi-gpu · 2022-12-08 23:03
alyssaensure_cmdbuf_has_space should probably also assert its own precondition#asahi-gpu · 2022-12-08 23:03
alyssait's also possibly the XML for VDM_STREAM_LINK itself is busted though I don't think so, because otherwise we couldn't trace across stream links (and we can)#asahi-gpu · 2022-12-08 23:02
alyssaI don't remember what macOS does#asahi-gpu · 2022-12-08 23:02
alyssai.e. low 32-bit perhaps?#asahi-gpu · 2022-12-08 23:02
alyssaI woudl also check whether we need any special allocation for the stream#asahi-gpu · 2022-12-08 23:01
alyssaIt's unclear whether that bug can be hit in practice, but if not it's only by accident#asahi-gpu · 2022-12-08 23:00
alyssawithout overflow on the link#asahi-gpu · 2022-12-08 23:00
alyssai.e. we need to make sure we left enough room for the next draw to link to a new stream#asahi-gpu · 2022-12-08 23:00
alyssaassert(batch_encoder_current + AGX_VDM_STREAM_LINK_LENGTH <= batch->encoder_end && "...")#asahi-gpu · 2022-12-08 23:00
alyssaWe actually need to assert something stronger:#asahi-gpu · 2022-12-08 22:59
alyssathat assert then is wrong#asahi-gpu · 2022-12-08 22:59
alyssahttps://gitlab.freedesktop.org/asahi/mesa/-/blob/main/src/gallium/drivers/asahi/agx_state.c#L2194#asahi-gpu · 2022-12-08 22:59
alyssaso that when we ensure there's room each time, there's actually room + enough for a final stream link for the *next* draw#asahi-gpu · 2022-12-08 22:59
alyssawe need to add AGX_VDM_STREAM_LINK_LENGTH to space at the beginning#asahi-gpu · 2022-12-08 22:59
alyssaOne bug jumps out:#asahi-gpu · 2022-12-08 22:57
alyssaI think this mechanism might be busted.#asahi-gpu · 2022-12-08 22:56
alyssajannau: https://gitlab.freedesktop.org/asahi/mesa/-/blob/main/src/gallium/drivers/asahi/agx_state.c#L2026#asahi-gpu · 2022-12-08 19:46
corionThe gpu driver is ridiculously nice.#asahi-gpu · 2022-12-08 06:56
jannauall good, I was just testing mpv across a couple of window managers/compositors#asahi-gpu · 2022-12-08 02:25
linajannau: For gnome terminal you need to unset the use system color scheme thing, else the background breaks. I don't know what's up with that...#asahi-gpu · 2022-12-07 22:16
jannauon asahi rendering is broken and resumes when selecting 5000 fish#asahi-gpu · 2022-12-07 22:15
jannaumight be the same or similar issue as quakejs, debian user say it crashes firefox on their systems#asahi-gpu · 2022-12-07 22:13
jannauhttp://webglsamples.org/aquarium/aquarium.html breaks down when selecting 10000 fish or more with vertex batch faults#asahi-gpu · 2022-12-07 20:42
jannaucompositing in general as well#asahi-gpu · 2022-12-07 20:40
jannaugnome terminal on gnome/x11 is very broken#asahi-gpu · 2022-12-07 13:38
CyrinuxI forgot to place important "usb / TB dock" in my sentense, by we, I tought about end-users following#asahi-gpu · 2022-12-07 13:31
_jannau_see https://asahilinux.org/copyright/#reverse-engineering-policy for reference#asahi-gpu · 2022-12-07 13:29
_jannau_it's not related to the gpu at all. Who is we and what kind of information are you thinking about?