android / tuningfork

Android Performance Tuner is a library to help developers measure frame rendering time across different devices and game stages. This plugin will help developers integrate Android Performance Tuner into their game.
https://developer.android.com/games/sdk/performance-tuner/unity
Other
54 stars 30 forks source link

Most likely, current APT implementation is incompatible with Unity 6 (crash Unity_TuningFork_init_with_settings in libunitytuningfork.so after updating project) #47

Open vitalik198 opened 1 month ago

vitalik198 commented 1 month ago

Stacktrace

backtrace:
  Unknown
  #01  pc 0x00000000000546a0  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/lib/arm64/libunitytuningfork.so (BuildId: 04852f825bd5553cd874f1a06c85fd27ef52a1b5)
  #02  pc 0x0000000000054540  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/lib/arm64/libunitytuningfork.so (Unity_TuningFork_init_with_settings+16) (BuildId: 04852f825bd5553cd874f1a06c85fd27ef52a1b5)
  #03  pc 0x00000000038438c0  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/lib/arm64/libil2cpp.so (BuildId: 97e8ca7f7d264d9f04de5c470ac6b41c714ef91d)
  #04  pc 0x0000000003096694  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/lib/arm64/libil2cpp.so (BuildId: 97e8ca7f7d264d9f04de5c470ac6b41c714ef91d)
  #05  pc 0x0000000003098320  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/lib/arm64/libil2cpp.so (BuildId: 97e8ca7f7d264d9f04de5c470ac6b41c714ef91d)
  #06  pc 0x000000000214fbfc  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/lib/arm64/libil2cpp.so (BuildId: 97e8ca7f7d264d9f04de5c470ac6b41c714ef91d)
  #07  pc 0x00000000044903e4  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/lib/arm64/libil2cpp.so (BuildId: 97e8ca7f7d264d9f04de5c470ac6b41c714ef91d)
  #08  pc 0x00000000020b17f0  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/lib/arm64/libil2cpp.so (BuildId: 97e8ca7f7d264d9f04de5c470ac6b41c714ef91d)
  #09  pc 0x00000000020b173c  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/lib/arm64/libil2cpp.so (BuildId: 97e8ca7f7d264d9f04de5c470ac6b41c714ef91d)
  #10  pc 0x00000000006c4c08  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/lib/arm64/libunity.so (BuildId: b532fa16d4192bf4)
  #11  pc 0x00000000006d859c  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/lib/arm64/libunity.so (BuildId: b532fa16d4192bf4)
  #12  pc 0x00000000006e15fc  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/lib/arm64/libunity.so (BuildId: b532fa16d4192bf4)
  #13  pc 0x00000000006e1210  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/lib/arm64/libunity.so (BuildId: b532fa16d4192bf4)
  #14  pc 0x00000000004f3498  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/lib/arm64/libunity.so (BuildId: b532fa16d4192bf4)
  #15  pc 0x00000000005da7d4  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/lib/arm64/libunity.so (BuildId: b532fa16d4192bf4)
  #16  pc 0x00000000005cd838  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/lib/arm64/libunity.so (BuildId: b532fa16d4192bf4)
  #17  pc 0x00000000005cd878  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/lib/arm64/libunity.so (BuildId: b532fa16d4192bf4)
  #18  pc 0x00000000005cdb1c  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/lib/arm64/libunity.so (BuildId: b532fa16d4192bf4)
  #19  pc 0x000000000076ca9c  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/lib/arm64/libunity.so (BuildId: b532fa16d4192bf4)
  #20  pc 0x000000000076d9fc  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/lib/arm64/libunity.so (BuildId: b532fa16d4192bf4)
  #21  pc 0x0000000000440354  /apex/com.android.art/lib64/libart.so (art_quick_generic_jni_trampoline+148)
  #22  pc 0x000000000020a2b0  /apex/com.android.art/lib64/libart.so (nterp_helper+4016)
  #23  pc 0x0000000000492070  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/base.apk (com.unity3d.player.z0.handleMessage+280)
  #24  pc 0x00000000004e5e04  /system/framework/arm64/boot-framework.oat (android.os.Handler.dispatchMessage+148)
  #25  pc 0x00000000004e9138  /system/framework/arm64/boot-framework.oat (android.os.Looper.loopOnce+1032)
  #26  pc 0x00000000004e8c90  /system/framework/arm64/boot-framework.oat (android.os.Looper.loop+560)
  #27  pc 0x0000000000209398  /apex/com.android.art/lib64/libart.so (nterp_helper+152)
  #28  pc 0x0000000000484694  /data/app/~~6QVdmFBKoivyFj_FPzwMaw==/com.DamagedRabbit.NeonLight-A8n33cN4Csva7NPrkNPj7A==/base.apk (com.unity3d.player.B0.run+48)
  #29  pc 0x000000000043696c  /apex/com.android.art/lib64/libart.so (art_quick_invoke_stub+556)
  #30  pc 0x0000000000468738  /apex/com.android.art/lib64/libart.so (art::ArtMethod::Invoke(art::Thread*, unsigned int*, unsigned int, art::JValue*, char const*)+156)
  #31  pc 0x0000000000468420  /apex/com.android.art/lib64/libart.so (art::JValue art::InvokeVirtualOrInterfaceWithJValues<art::ArtMethod*>(art::ScopedObjectAccessAlreadyRunnable const&, _jobject*, art::ArtMethod*, jvalue const*)+388)
  #32  pc 0x0000000000617f0c  /apex/com.android.art/lib64/libart.so (art::Thread::CreateCallback(void*)+1668)
  #33  pc 0x00000000000b62b8  /apex/com.android.runtime/lib64/bionic/libc.so (__pthread_start(void*)+208)
  #34  pc 0x0000000000052fb8  /apex/com.android.runtime/lib64/bionic/libc.so (__start_thread+64)
ShitCoder86 commented 1 month ago

Similar issue with crash on Unity 6 in Unity_TuningFork_init_with_settings

SIGSEGV: Segmentation violation (invalid memory reference)

0 0x0 1 libunitytuningfork.so +0xcae5c (anonymous namespace)::findSwappy() 2 libunitytuningfork.so +0xcacfc Unity_TuningFork_init_with_settings 3 libil2cpp.so +0x329cd50 0x7c9dcefd54 4 libil2cpp.so +0x2a22798 0x7c9d47579c 5 libil2cpp.so +0x2a24554 0x7c9d477558 6 libil2cpp.so +0x1e481fc 0x7c9c89b200 7 libil2cpp.so +0x3dd02f0 0x7c9e8232f4 8 libil2cpp.so +0x1ce0c70 0x7c9c733c74 9 libil2cpp.so +0x1ce0bbc 0x7c9c733bc0 10 libunity.so +0x5e1974 0x7cb17f8978 11 libunity.so +0x5f3c98 0x7cb180ac9c 12 libunity.so +0x5fdf18 0x7cb1814f1c 13 libunity.so +0x5fdb30 0x7cb1814b34 14 libunity.so +0x4274bc 0x7cb163e4c0 15 libunity.so +0x500754 0x7cb1717758 16 libunity.so +0x4f4638 0x7cb170b63c 17 libunity.so +0x4f4678 0x7cb170b67c 18 libunity.so +0x4f4904 0x7cb170b908 19 libunity.so +0x688cec 0x7cb189fcf0 20 libgame.so +0x13140 Unity::UnityApplication::Loop() 21 libgame.so +0x1573c MainLoop(android_app) 22 libgame.so +0x15808 android_main 23 libgame.so +0x1bd98 android_app_entry 24 libc.so +0x102e9c __pthread_start(void) 25 libc.so +0x96c2c __start_thread