#asahi-gpu · 2021-04-11 01:16
bloomTBD#asahi-gpu · 2021-04-10 23:13
bloom( regardless https://gitlab.freedesktop.org/asahi/applegpu/-/blob/xml/agx_disasm.c.py and https://gitlab.freedesktop.org/asahi/applegpu/-/blob/xml/dump.py is today's yak shave )#asahi-gpu · 2021-04-10 23:13
bloomThough tbh I am thinking we'd be happier just pulling applegpu.py into mesa#asahi-gpu · 2021-04-10 23:11
bloomhas a WIP XMLification of applegpu's disassembler#asahi-gpu · 2021-04-10 17:54
bloom("Go back to sleep, Bloom.")#asahi-gpu · 2021-04-10 17:51
bloomAnd for my next trick, I shall pull a rabbit out of a hat!#asahi-gpu · 2021-04-10 17:06
bloomvert in this case#asahi-gpu · 2021-04-10 17:06
bloommm#asahi-gpu · 2021-04-10 17:02
bloomworth checking as well, and would probably be easier :)#asahi-gpu · 2021-04-10 17:00
bloomDarkShadow44: modifying a shader to vary its register pressure, disassembling the shader to get the amount spilled (X), and parsing the command stream to get the amount reported (Y)#asahi-gpu · 2021-04-10 16:45
bloomsomething like upper bits are powers of 4, lower bits are 2/3#asahi-gpu · 2021-04-10 16:45
bloomjn__: Yeah, I think you got it spot on.#asahi-gpu · 2021-04-10 16:45
bloomit's not about division by 3 at all, gah#asahi-gpu · 2021-04-10 16:44
bloomd'oh#asahi-gpu · 2021-04-10 16:44
bloomjn__: ty#asahi-gpu · 2021-04-10 16:44
bloom----Oh shit#asahi-gpu · 2021-04-10 16:43
bloomBut again... why 3?!#asahi-gpu · 2021-04-10 16:43
bloomglibc: The "explanation" there is if you divide by 3, that becomes a 124/129 boundary -- fine, 128#asahi-gpu · 2021-04-10 16:42
bloomme too#asahi-gpu · 2021-04-10 16:42
bloomglibc: yeah#asahi-gpu · 2021-04-10 16:42
bloom(388, 7)#asahi-gpu · 2021-04-10 16:42
bloom(372, 6),#asahi-gpu · 2021-04-10 16:42
bloomWorse:#asahi-gpu · 2021-04-10 16:42
bloomIf it's log2, then why is the there are threshold betweeen 20 and 36?#asahi-gpu · 2021-04-10 16:42
bloom^ This should be bugging you#asahi-gpu · 2021-04-10 16:41
bloom (20, 1),#asahi-gpu · 2021-04-10 16:41
bloom (36, 2),#asahi-gpu · 2021-04-10 16:40
bloombut the coefficients get all weird for small n#asahi-gpu · 2021-04-10 16:40
bloomtable.py shows a clear logarithmic pattern (as jn__ also identified) so this doesn't seem far off from AGX#asahi-gpu · 2021-04-10 16:40
bloomso we need to round up the number of 16-byte slots, and then round up the power-of-two#asahi-gpu · 2021-04-10 16:40
bloomOn Mali, the idea is that the hardware allocates a power-of-two number of 16-byte slots#asahi-gpu · 2021-04-10 16:39
bloomYeah#asahi-gpu · 2021-04-10 16:39
bloomceil(log2(ceil(s / 16))) I guess it was#asahi-gpu · 2021-04-10 16:39
bloomer#asahi-gpu · 2021-04-10 16:37
bloomuh. apparently that comment is wrnog, should be ceil(log2(s / 16)) but I digress#asahi-gpu · 2021-04-10 16:37
bloomfwiw, the equivalent field on Mali is https://cgit.freedesktop.org/mesa/mesa/tree/src/panfrost/lib/pan_scratch.c#n70 explanation in the comments#asahi-gpu · 2021-04-10 16:36
bloomheh#asahi-gpu · 2021-04-10 16:33
bloomclearly you are right, that's in the data. but why?#asahi-gpu · 2021-04-10 16:33
bloomIt's the division-by-3 that's baffling me#asahi-gpu · 2021-04-10 16:33
bloomit's certainly a possibility :)#asahi-gpu · 2021-04-10 16:33
bloomgot it#asahi-gpu · 2021-04-10 16:32
bloomjn__: what's f2gen?#asahi-gpu · 2021-04-10 15:56
bloomSpecifically, can you write a function that takes in the left number (340) and outputs the right one (6), fitting so well that it can predict the results for future data?#asahi-gpu · 2021-04-10 15:55
bloomCan you find the pattern in this?#asahi-gpu · 2021-04-10 15:55
bloomglibc: https://github.com/AsahiLinux/gpu/blob/0f4f417ef85f2dcb5840427fc07a1162062f7594/docs/table.py#asahi-gpu · 2021-04-10 14:11
bloomeven have spilling disassembled correctly, nice!#asahi-gpu · 2021-04-10 13:58
bloomdougall: I have to hand it to you, no clue how you figured out the control flow stuff <3#asahi-gpu · 2021-04-09 00:02
bloomhaving one of those nights#asahi-gpu · 2021-04-09 00:02
bloommixed up her endians#asahi-gpu · 2021-04-08 23:22
bloomI'd love to see if metal has secret functions for apple's opengl-on-metal