Open jcm93 opened 3 months ago
Filter chain failure is odd, I wonder if it might be something in SPIRV-Cross.. Will take a look this or next week.
Metal GPU captures would be massively helpful here, as well as LLVM logs from the compiler if you’re able to get them.
Metal GPU captures would be massively helpful here, as well as LLVM logs from the compiler if you’re able to get them.
Sure, I'll get captures from the ones that appear to be rendering nothing; can you provide any guidance on the latter point? Is there a way to get the compiler output to appear in stdout for example? Would compiling librashader in debug mode do the job? I notice that I already get compilation warnings from the shaders by default.
It should show up in debug logs in Xcode when first loading the shader. It’s not a librashader thing but a Metal -> MetalIR thing
Hmm, I don't get any output I can see from filter chain creation, even with Xcode Metal API and Shader validation enabled. I tried in the objctest
code as well; selecting crt-guest-advanced-ntsc
just ends up with a nil _filterChain
. I see a couple compilation warnings, but compilation succeeds.
Thats fine, I’ll investigate crt-guest-advanced-ntsc on my end.
Here are the GPU captures. They should be labeled appropriately. Let me know if you have any issues opening or getting relevant data from them!
https://drive.google.com/file/d/11bNWB78_drEg1IW3t4ZcViupYgg8qQkd/view?usp=sharing
For the vhs shader capture, it seemed to peg my GPU above a certain resolution, so I notched it just above that and took a capture. Again, that one could just be a shader issue, but I figured it was worth including. I also included a megabezel capture; it seems to be doing some very weird stuff indeed (frame times there were exceedingly high every few frames, though not every frame, so looking at this more closely, I think it's just dropping frames; regardless, I included three frames in that capture); I couldn't exactly tell what was going on.
mudlord-pal is a known broken shader: https://github.com/SnowflakePowered/librashader/actions/runs/8577373017/job/23509866495#step:4:376
seems like crt-guest-advanced has been failing, will need to double check but it smells like a shader issue.
Anime4k is also a known broken shader
scratch that, seems to be the result of a driver issue
Testing some things in ares and noticed another librashader issue with certain 'smoothing' shaders such as presets/crt-royale-smooth.slangp
or bezel/Mega_Bezel/Presets/MBZ__0__SMOOTH-ADV.slangp
.
Left librashader, right RetroArch:
Screenshots are of the megabezel shader; here is a gputrace from the crt-royale-smooth
shader which exhibits similar behavior.
https://drive.google.com/file/d/1NBePGt62XmFZ_mthqlR8YTj8EC7EFVdG/view?usp=share_link
Native Metal support was recently added to ares to complement its librashader support. I've started to do some testing with a bunch of shaders and wanted to start reporting preliminary findings from the .slangp shader library it bundles.
Overall impressions are great. Most things seem to be working correctly and performing well.
I don't have a reference for how these shaders behave on other platforms, so I can mostly only point out things that seem 'obviously broken,' or else obvious things like compiler failures.
With that said, here's a preliminary list so far. I expect to eventually test everything, this is just from my first round of tests, to start getting stuff out there.
Loads fine, blank output
crt/crt-geom-deluxe.slangp
crt/crt-slangtest-cubic.slangp
crt/crt-slangtest-lanczos.slangp
Filter chain creation failure
crt/crt-guest-advanced-ntsc.slangp
known broken shadervhs/mudlord-pal-vhs.slangp
test/feedback-noncausal.slangp
known broken shadersharpen/Anime4k.slangp
vhs/VHSPro.slangp
Other
vhs/vhs_and_crt_godot.slangp
- Loads, renders, but pegs GPU to 100% even at low resolutions. Could just be a shader issue.presets/crt-royale-smooth.slangp
- blurring issue, see downthreadbezel/Mega_Bezel/Presets/MBZ__0__SMOOTH-ADV.slangp
- same blurring issueshader issuereshade/gba.slangp
- Fails to create presetshader issuereshade/nds.slangp
- Fails to create presetOther notes so far are that "megabezel" shader performance across the board is somewhat poor at ~4K resolutions when its reflections are enabled. This may simply be a shader issue but I figured worth including.
For testing, the ares' recent CI builds all include the Metal backend. I can provide more information or Metal GPU captures as well if needed for anything, if that is helpful.