#
…

2023-04-15

00:23A_L_I_C_E has quit [Ping timeout: 480 seconds]
00:24A_L_I_C_E has joined #asahi-gpu
00:57A_L_I_C_E has quit [Read error: Connection reset by peer]
00:58A_L_I_C_E has joined #asahi-gpu
01:13possiblemeatball has joined #asahi-gpu
01:17renatorabelo has joined #asahi-gpu
01:20Emantor has quit [Quit: ZNC - http://znc.in]
01:20Emantor has joined #asahi-gpu
02:11renatorabelo has quit [Read error: Connection reset by peer]
02:41pthariensflame has joined #asahi-gpu
02:44alyssa has joined #asahi-gpu
02:44alyssamultisampling_fails--;
02:54pthariensflame has quit [Quit: Textual IRC Client: www.textualapp.com]
03:11alyssamultisampling_fails--;!nin
03:37possiblemeatball has quit [Quit: Quit]
04:43A_L_I_C_E has quit [Ping timeout: 480 seconds]
05:14A_L_I_C_E has joined #asahi-gpu
05:47A_L_I_C_E has quit [Ping timeout: 480 seconds]
06:05A_L_I_C_E has joined #asahi-gpu
06:44chipxxx has quit [Ping timeout: 480 seconds]
07:11nsklaus has joined #asahi-gpu
09:28i509vcb has quit [Quit: Connection closed for inactivity]
09:35cylm has joined #asahi-gpu
12:31yuka has quit [Remote host closed the connection]
12:31possiblemeatball has joined #asahi-gpu
12:32possiblemeatball has quit [Remote host closed the connection]
12:32possiblemeatball has joined #asahi-gpu
12:35kujeger has quit [Quit: ZNC 1.8.2 - https://znc.in]
12:38kujeger has joined #asahi-gpu
13:24yuka has joined #asahi-gpu
16:01nsklaus has quit [Quit: ZZZzzz…]
16:05cylm_ has joined #asahi-gpu
16:47pthariensflame has joined #asahi-gpu
16:49cylm_ has quit [Quit: WeeChat 3.8]
16:50pthariensflame has quit []
16:54i509vcb has joined #asahi-gpu
16:59tertu has quit [Quit: so long...]
17:09pthariensflame has joined #asahi-gpu
17:11pthariensflame has quit []
17:31A_L_I_C_E has quit [Remote host closed the connection]
18:00nsklaus has joined #asahi-gpu
19:15alyssa has quit [Quit: leaving]
19:32drubrkletern has joined #asahi-gpu
20:02ChaosPrincess has quit [Quit: WeeChat 3.8]
20:02ChaosPrincess has joined #asahi-gpu
20:06zocker has joined #asahi-gpu
20:20Hibyehello has quit [Ping timeout: 480 seconds]
20:29darkapex1 has joined #asahi-gpu
20:31darkapex has quit [Ping timeout: 480 seconds]
20:31nela has quit [Ping timeout: 480 seconds]
20:43drubrkletern has quit [Ping timeout: 480 seconds]
20:50nela has joined #asahi-gpu
20:53drubrkletern has joined #asahi-gpu
21:43Z750 has quit [Quit: bye]
21:44Z750 has joined #asahi-gpu
22:32yuka has quit [Remote host closed the connection]
22:33yuka has joined #asahi-gpu
22:54alyssa has joined #asahi-gpu
22:55alyssaok, dolphin apples to apples
22:55alyssaon macos
22:55alyssamelty molten galaxy trace
22:55alyssa4K specialized shader: 63fps
22:55alyssa4K ubershaders: 11.5fps
22:56alyssa(moltenvk)
22:57alyssa4K special shader: ~100fps
22:57alyssa4K ubershaders: 11.5fps
22:58alyssaso those are our targets ^^
22:58alyssaoh, also:
22:59alyssanative ubershaders (metal): 120fps
22:59alyssanative ubershaders (moltenvk): 120fps
23:00alyssaand just for completeness, on OpenGL:
23:00alyssanative ubershaders: 120fps
23:01alyssa4K specialized: 54fps
23:01alyssa4K exclusive: 10fps
23:02nsklaus has quit [Quit: ZZZzzz…]
23:09alyssa--------------------------------
23:10alyssaOver on agx/next, GLES backend
23:10alyssa4K specialized: 47fps
23:10alyssa4K uber: 4.3fps
23:11alyssanative uber: 78fps
23:11alyssa---------------------
23:11alyssaso... we have work to do.
23:13alyssa1. 4K specialized perf is slightly behind Apple's GL driver, and about half what it should be (Metal backend)
23:13alyssa2. 4K uber is a bit less than half of Apple's GL driver and a bit more than a third of what it should be (Metal)
23:14alyssa3. native uber is not worth quantifying since macos is hitting the 120fps cap here on all backends, we need to be 50% faster to do the same
23:14alyssaso... we have a lot of work to go still :|
23:15alyssaat least it's not 10x slower...
23:15alyssasomewhere between 2x to 3x slower on this workload, though
23:15alyssait's not 100% clear to me if this is apples to apples (no pun intended)
23:15alyssagiven the different backends involved
23:17alyssasome of this (especially ubershader perf) is going to be compiler related, I imagine
23:19alyssaTellowKrinkle: Seeing as you wrote the winning backend, any ideas what to look into for dolphin go fast? O:)
23:19TellowKrinkleBTW afaik most of the difference between Metal and MVK on macOS is whether we have texture compression enabled or not (at the moment, MVK specifies MTLTextureUsagePixelFormatView on pretty much all textures, which disables that).
23:20alyssaI got big wins already from compression, yeah
23:20TellowKrinkleYou can test that by going to the Metal renderer's texture allocation code and adding the PFV flag there
23:20alyssa(we weren't compressing array textures before, that won back a ton of perf)
23:20TellowKrinkleAhh yeah, Dolphin is 100% array textures
23:21alyssaOk, I had locally disabled z/s compression since it was causing issues
23:22alyssabut forcing it on anyway (Dolphin rendering still seems fine)
23:22alyssa4K specialized: 60fps
23:22alyssa4K uber: 4.3fps
23:22alyssanative uber: 78fps
23:23tertu has joined #asahi-gpu
23:23alyssaso after fixing z/s compression, our gles beats apple's gl
23:23alyssafor specialized shaders
23:24alyssaneedle doesn't move for ubershaders since I guess those aren't bandwidth bound
23:25alyssa(our gles specialized is sitill not up to metal -- 60fps vs 100fps -- though maybe some of those differences are within dolphin? maybe?)
23:26alyssaI wonder how much ubershaders are getting hurt by the serialization of the fragment shaders
23:26alyssabecause they're reading gl_FragColor right at the top and then don't use it until the bottom
23:26alyssawhich forces overdraw to get serialized... shouldn't be too hard to sink the load down, I think
23:27TellowKrinkleIf you look at the decompilation of ubershaders, Metal does the same
23:27alyssasink the load or not?
23:27TellowKrinkleLoad happens before the main ubershader loop
23:27alyssaWell. That's not great but not our problem then, heh
23:28* alyssashould maybe look at one of those disassembled Metal ubershaders
23:29* alyssadoesn't want to be 37% the performance of Metal :-V
23:29alyssa(Granted, 37% the performance of Metal would still be totally playable. And there's piles of content we'll have available that's just not possible on macOS but still.)
23:30alyssahopefully some of that is something dumb
23:30alyssathere's a long tail of ALU cycle shaving we could do for the ubershaders, but I'm not convinced any of it would move the needle
23:30drubrkletern has quit [Remote host closed the connection]
23:31alyssaseeing as I've literally never seen an ALU saving optimization matter for fps
23:32alyssascheduling might be significant for the ubershaders though
23:32alyssain terms of both pressure and latency, given how big these are
23:33TellowKrinkleUhh do you know if things like HSR and stuff are getting enabled for non-ubershaders? I've noticed Apple GPUs having a much larger gap between uber and non-uber shaders than e.g. AMD, and have been wondering if that's due to Apple GPUs getting a good bit of their performance from optimizations that get blocked by ubershaders.
23:34TellowKrinkleHybrid in particular sees much worse slowdowns when small amounts of ubershader are inserted into an otherwise non-ubershader render than I see on AMD
23:34alyssaHSR is going to be hurt by the gl_FragDepth write, I think
23:35TellowKrinkleWe shouldn't do that in specialized shaders though
23:36TellowKrinkle(Unless you have accurate depth or whatever that flag is called enabled)
23:36alyssaright. if specialized shaders don't usually gl_FragDepth write, but ubershaders do, that'll be a gap
23:36alyssaas I mentioned above loading gl_FragColor at the top of the shader is going to force the shaders to be totally serialized, which is also going to magnify the issue (maybe)
23:39alyssahere I'm going to try copypasting some code from panfrost and see if that makes things go brr
23:40TellowKrinkleBTW does gpuvis work on Asahi yet? That might be a good way to see if we're running into scheduling issues.
23:40alyssaprobably not
23:40* alyssalooks up what gpuvis is
23:41alyssa's a question for lina I think
23:42alyssaTellowKrinkle: also is there any cool stuff Dolphin can do on Linux but not macOS that I can use to sell this if perf doesn't pan out? :~P
23:43TellowKrinkleI've used Apple's equivalent of that for debugging almost all the GPU-related optimizations I've done for either PCSX2 or Dolphin
23:45TellowKrinkleI don't think Dolphin has too much Linux specific stuff. I'm not too familiar with the more uncommon stuff though, I only joined the project a year ago.
23:47alyssaWas worth a try ;P
23:51TellowKrinkleLet me quick run a no-PFV test of melty molten galaxy and make sure that accounts for all the performance difference between MVK and Metal
…