-
Notifications
You must be signed in to change notification settings - Fork 522
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] SkiaSharp 2.88.8 (Xamarin) crashes randomly with Mali GPUs #2843
Comments
Are you able to reproduce this crash at all? And maybe try SkiaSharp 3.x? Not much to go on there, but if the crash is in the GLES library, could it be some Android issue? Are you able to get the symbol in libSkiaSharp.so that is the start of the crash? |
I actually happen to have Google Pixel 6a, which has Mali GPU, and I managed to get it crash sometimes with SkiaSharp 2.80.3, so there's a fair chance that I can get it crash also with 2.88.8. The game used to crash when zooming out to minimap scale, so I can try that again. (In minimap zoom scale, bitmaps get scaled very small in the game so that you can see the entire map.) My experience though is that the crash in minimap zoom happens much less frequently these than in 2.80.3, so I was expecting the bug to have been fixed, but apparently not entirely so. How do I get the symbol(s) from libSkiaSharp.so normally? Should I get Android logs or is there a way to get further debug data e.g. in debug configuration using SkiaSharp? Tommi has been playing around with building SkiaSharp, too, but getting a custom SkiaSharp in the game could be a bit much, but in theory might be possible. It is obviously some Android / OpenGL / Mali driver issue, or some kind of an incompatibility between those. SkiaSharp 3.0x does not seem to be available on Xamarin. On that note, we are still stuck with Xamarin because of the iOS memory corruption problem mentioned in #2840 which is the most serious problem we have encountered with SkiaSharp so far. My guess is that that corruption problem may have something to do with a threading problem / incompatibility between .NET MAUI layout cycle (perhaps works now differently from Xamarin) and SKGLView rendering cycle (which seems to be oddly slow like it would cause .NET layout cycle to wait for OpenGL to finish drawing or the like, see #2842). I suspect that because the corruption starts to happen after I open many game menus / pages / layouts with SKGLViews (say, 40 times), and after that suddenly things break down with SkiaSharp. |
With the old 2.80.3, which crashes easier, I managed to get the following log:
|
Also, 6 hours ago the seemingly same crash was reported by Google Play on 2.88.8 with Google Husky (Pixel 8 Pro) with Android 14. @mattleibow Does this help anything? At least the function names seem to be now there, and this is 2.88.8 for sure.
|
Description
Even after upgrading to 2.88.8 (Xamarin Android), we are still seeing the following crash with Mali GPUs (from Google Play Console):
Only happens with SKGLView.
Code
https://github.com/hyvanmielenpelit/GnollHack
Expected Behavior
SkiaSharp and SKGLView do not crash with Mali GPUs.
Actual Behavior
On Android, SkiaSharp crashes randomly when SKGLView is used with Mali GPUs. (But seems a bit rarer than with 2.80.3, which we used before.)
Version of SkiaSharp
2.88.3 (Current)
Last Known Good Version of SkiaSharp
Other (Please indicate in the description)
IDE / Editor
Visual Studio (Windows)
Platform / Operating System
Android
Platform / Operating System Version
Android 13, as reported by Google Play Console. Also, a couple of Android 14 phones.
Devices
Motorola Vicky (moto g72), as reported by Google Play Console. Also, a couple of Google Tensor / Pixel phones.
Relevant Screenshots
No response
Relevant Log Output
No response
Code of Conduct
The text was updated successfully, but these errors were encountered: