NDK-STACK stack frame not useful - android

Ndk-stack give this output:
Build fingerprint: 'intel/inet_alc5651_64/inet_alc5651:5.1.1/LMY47V/inet-soft0504291459:userdebug/release-keys'
pid: 30534, tid: 30557, name: GLThread 2273 >>> xxx <<<
signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x18
Stack frame #00 pc 001a26a3 [anon:Mem_0x20000000]
Stack frame #01 pc 0000302f [anon:Mem_0x10002002]
It is not obvious. I could not find error memory address. Why is this output like above ?

Related

Java_org_cocos2dx_lib_Cocos2dxRenderer_nativeOnPause

In Google Play I have daily crash reporting ever-increasing.
signal 11 (SIGSEGV), code 1 (SEGV_MAPERR)
Java_org_cocos2dx_lib_Cocos2dxRenderer_nativeOnPause
backtrace:
pid: 0, tid: 0 >>> com.Feelinglucky.swipelight <<<
backtrace:
#00 pc 00000000002ca46c /data/app/com.Feelinglucky.swipelight-2/lib/arm/libplayer.so (Java_org_cocos2dx_lib_Cocos2dxRenderer_nativeOnPause+7)
#01 pc 0000000001c0c02d /data/app/com.Feelinglucky.swipelight-2/oat/arm/base.odex
How can i solve this problem? Thanks in advance

How to find which method caused crash from NDK stack trace

My app crashes due to .so file.
I followed this link https://developer.android.com/ndk/guides/ndk-stack.html
Using the above link i am able to take stack-trace dump from log cat.
And from stack trace it shows me all functions name using ndk-stack tool.But i am unable to find out which method exactly caused my app to crash??
This is the log from my app stating fatal signal.
id: 26940, tid: 27543, name: Thread-579 >>> com.nexge.nexgeotpdialer <<<
signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x34
Its stating fault address 0x34.but using ndk-stack tool it shows all threads with function names but which one caused crash??
********** Crash dump: **********
Build fingerprint: 'Xiaomi/land/land:6.0.1/MMB29M/V8.5.4.0.MALMIED:user/release-keys'
pid: 26940, tid: 27543, name: Thread-579 >>> com.nexge.nexgeotpdialer <<<
signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x34
Stack frame #00 pc 00155638 /data/app/com.nexge.nexgeotpdialer-1/lib/arm/libpjsua2.so (pj_thread_destroy+3): Routine pj_thread_create at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjlib/build/../src/pj/os_core_unix.c:570 (discriminator 5)
Stack frame #01 pc 0011973f /data/app/com.nexge.nexgeotpdialer-1/lib/arm/libpjsua2.so (start_signal+238): Routine check_rx_late_pkt at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjmedia/build/../src/pjmedia/compressed_rtp.c:667 (discriminator 2)
Stack frame #02 pc 00155471 /data/app/com.nexge.nexgeotpdialer-1/lib/arm/libpjsua2.so (thread_main+40): Routine pj_init at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjlib/build/../src/pj/os_core_unix.c:214 (discriminator 2)
Stack frame #03 pc 0004185b /system/lib/libc.so (_ZL15__pthread_startPv+30)
Stack frame #04 pc 000192a5 /system/lib/libc.so (__start_thread+6)
Crash dump is completed
********** Crash dump: **********
Build fingerprint: 'Xiaomi/land/land:6.0.1/MMB29M/V8.5.4.0.MALMIED:user/release-keys'
pid: 28169, tid: 28422, name: Thread-618 >>> com.nexge.nexgeotpdialer <<<
signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x34
Stack frame #00 pc 00155638 /data/app/com.nexge.nexgeotpdialer-1/lib/arm/libpjsua2.so (pj_thread_destroy+3): Routine pj_thread_create at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjlib/build/../src/pj/os_core_unix.c:570 (discriminator 5)
Stack frame #01 pc 0011973f /data/app/com.nexge.nexgeotpdialer-1/lib/arm/libpjsua2.so (start_signal+238): Routine check_rx_late_pkt at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjmedia/build/../src/pjmedia/compressed_rtp.c:667 (discriminator 2)
Stack frame #02 pc 00155471 /data/app/com.nexge.nexgeotpdialer-1/lib/arm/libpjsua2.so (thread_main+40): Routine pj_init at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjlib/build/../src/pj/os_core_unix.c:214 (discriminator 2)
Stack frame #03 pc 0004185b /system/lib/libc.so (_ZL15__pthread_startPv+30)
Stack frame #04 pc 000192a5 /system/lib/libc.so (__start_thread+6)
Crash dump is completed
********** Crash dump: **********
Build fingerprint: 'Xiaomi/land/land:6.0.1/MMB29M/V8.5.4.0.MALMIED:user/release-keys'
pid: 29519, tid: 30349, name: Thread-620 >>> com.nexge.nexgeotpdialer <<<
signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x34
Stack frame #00 pc 00155660 /data/app/com.nexge.nexgeotpdialer-2/lib/arm/libpjsua2.so (pj_thread_destroy+3): Routine pj_enter_critical_section at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjlib/build/../src/pj/os_core_unix.c:1094
Stack frame #01 pc 00119763 /data/app/com.nexge.nexgeotpdialer-2/lib/arm/libpjsua2.so (start_signal+238): Routine check_rx_late_pkt at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjmedia/build/../src/pjmedia/compressed_rtp.c:672
Stack frame #02 pc 00155499 /data/app/com.nexge.nexgeotpdialer-2/lib/arm/libpjsua2.so (thread_main+40): Routine pj_init at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjlib/build/../src/pj/os_core_unix.c:218
Stack frame #03 pc 0004185b /system/lib/libc.so (_ZL15__pthread_startPv+30)
Stack frame #04 pc 000192a5 /system/lib/libc.so (__start_thread+6)
Crash dump is completed
********** Crash dump: **********
Build fingerprint: 'Xiaomi/land/land:6.0.1/MMB29M/V8.5.4.0.MALMIED:user/release-keys'
pid: 10036, tid: 10963, name: Thread-755 >>> com.nexge.nexgeotpdialer <<<
signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x34
Stack frame #00 pc 00155660 /data/app/com.nexge.nexgeotpdialer-1/lib/arm/libpjsua2.so (pj_thread_destroy+3): Routine pj_enter_critical_section at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjlib/build/../src/pj/os_core_unix.c:1094
Stack frame #01 pc 00119763 /data/app/com.nexge.nexgeotpdialer-1/lib/arm/libpjsua2.so (start_signal+238): Routine check_rx_late_pkt at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjmedia/build/../src/pjmedia/compressed_rtp.c:672
Stack frame #02 pc 00155499 /data/app/com.nexge.nexgeotpdialer-1/lib/arm/libpjsua2.so (thread_main+40): Routine pj_init at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjlib/build/../src/pj/os_core_unix.c:218
Stack frame #03 pc 0004185b /system/lib/libc.so (_ZL15__pthread_startPv+30)
Stack frame #04 pc 000192a5 /system/lib/libc.so (__start_thread+6)
Crash dump is completed
********** Crash dump: **********
Build fingerprint: 'Xiaomi/land/land:6.0.1/MMB29M/V8.5.4.0.MALMIED:user/release-keys'
pid: 11338, tid: 11813, name: Thread-751 >>> com.nexge.nexgeotpdialer <<<
signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x34
Stack frame #00 pc 00155660 /data/app/com.nexge.nexgeotpdialer-2/lib/arm/libpjsua2.so (pj_thread_destroy+3): Routine pj_enter_critical_section at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjlib/build/../src/pj/os_core_unix.c:1094
Stack frame #01 pc 00119763 /data/app/com.nexge.nexgeotpdialer-2/lib/arm/libpjsua2.so (start_signal+238): Routine check_rx_late_pkt at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjmedia/build/../src/pjmedia/compressed_rtp.c:672
Stack frame #02 pc 00155499 /data/app/com.nexge.nexgeotpdialer-2/lib/arm/libpjsua2.so (thread_main+40): Routine pj_init at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjlib/build/../src/pj/os_core_unix.c:218
Stack frame #03 pc 0004185b /system/lib/libc.so (_ZL15__pthread_startPv+30)
Stack frame #04 pc 000192a5 /system/lib/libc.so (__start_thread+6)
Crash dump is completed
********** Crash dump: **********
Build fingerprint: 'Xiaomi/land/land:6.0.1/MMB29M/V8.5.4.0.MALMIED:user/release-keys'
pid: 12197, tid: 12384, name: Thread-801 >>> com.nexge.nexgeotpdialer <<<
signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x34
Stack frame #00 pc 00155660 /data/app/com.nexge.nexgeotpdialer-2/lib/arm/libpjsua2.so (pj_thread_destroy+3): Routine pj_enter_critical_section at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjlib/build/../src/pj/os_core_unix.c:1094
Stack frame #01 pc 00119763 /data/app/com.nexge.nexgeotpdialer-2/lib/arm/libpjsua2.so (start_signal+238): Routine check_rx_late_pkt at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjmedia/build/../src/pjmedia/compressed_rtp.c:672
Stack frame #02 pc 00155499 /data/app/com.nexge.nexgeotpdialer-2/lib/arm/libpjsua2.so (thread_main+40): Routine pj_init at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjlib/build/../src/pj/os_core_unix.c:218
Stack frame #03 pc 0004185b /system/lib/libc.so (_ZL15__pthread_startPv+30)
Stack frame #04 pc 000192a5 /system/lib/libc.so (__start_thread+6)
Crash dump is completed
********** Crash dump: **********
Build fingerprint: 'Xiaomi/land/land:6.0.1/MMB29M/V8.5.4.0.MALMIED:user/release-keys'
pid: 14140, tid: 14798, name: Thread-808 >>> com.nexge.nexgeotpdialer <<<
signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x34
Stack frame #00 pc 00155660 /data/app/com.nexge.nexgeotpdialer-1/lib/arm/libpjsua2.so (pj_thread_destroy+3): Routine pj_enter_critical_section at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjlib/build/../src/pj/os_core_unix.c:1094
Stack frame #01 pc 00119763 /data/app/com.nexge.nexgeotpdialer-1/lib/arm/libpjsua2.so (start_signal+238): Routine check_rx_late_pkt at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjmedia/build/../src/pjmedia/compressed_rtp.c:672
Stack frame #02 pc 00155499 /data/app/com.nexge.nexgeotpdialer-1/lib/arm/libpjsua2.so (thread_main+40): Routine pj_init at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjlib/build/../src/pj/os_core_unix.c:218
Stack frame #03 pc 0004185b /system/lib/libc.so (_ZL15__pthread_startPv+30)
Stack frame #04 pc 000192a5 /system/lib/libc.so (__start_thread+6)
Crash dump is completed
********** Crash dump: **********
Build fingerprint: 'Xiaomi/land/land:6.0.1/MMB29M/V8.5.4.0.MALMIED:user/release-keys'
pid: 15644, tid: 16119, name: Thread-839 >>> com.nexge.nexgeotpdialer <<<
signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x34
Stack frame #00 pc 00155660 /data/app/com.nexge.nexgeotpdialer-1/lib/arm/libpjsua2.so (pj_thread_destroy+3): Routine pj_enter_critical_section at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjlib/build/../src/pj/os_core_unix.c:1094
Stack frame #01 pc 00119763 /data/app/com.nexge.nexgeotpdialer-1/lib/arm/libpjsua2.so (start_signal+238): Routine check_rx_late_pkt at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjmedia/build/../src/pjmedia/compressed_rtp.c:672
Stack frame #02 pc 00155499 /data/app/com.nexge.nexgeotpdialer-1/lib/arm/libpjsua2.so (thread_main+40): Routine pj_init at /home/protocol/Jeeva/PJSIPWorks/AESEncryption/pjlib/build/../src/pj/os_core_unix.c:218
Stack frame #03 pc 0004185b /system/lib/libc.so (_ZL15__pthread_startPv+30)
Stack frame #04 pc 000192a5 /system/lib/libc.so (__start_thread+6)
Crash dump is completed
I too was looking for ways to trace SIGSEGV faults. I decided to do my own trace.
https://github.com/claytonfan/trace
Intended usage:
#include <stdio.h>
#include <stdlib.h>
#include <signal.h>
#include "trace.h
void sig_handler(int signo)
{
if( signo == SIGSEGV ) {
traceDump("Signal SIGSEGV");
}
// may handle other signo's
exit( signo );
}
int main(int argc, char **argv)
{
traceInit( "Prgram Test", &printf, 0 );
signal( SIGSEGV, sig_handler );
//
// and possibly other signals
//
// . . . main() logic . . .
return( 0 );
}
Hope that helps.

Android ART loading dex failure

Build fingerprint: GiONEE/F103/GiONEE_GBL7319:5.0/LRX21M/1433132360:user/release-keys
pid: 28431, tid: 28459 >>> com.lily.web <<<
signal 11 (SIGSEGV), code 2 (SEGV_ACCERR), fault addr d3b0f000
#00 pc 0x0 /data/data/***/jars_fusion.dex (???)
#01 pc 0xa1eb7 /system/lib/libart.so (???)
#02 pc 0xb1cc8 [heap] (???)
java.lang.Throwable:
******* Java stack for JNI crash *******
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.lily.web.DexLoader.invokeStaticMethod(SourceFile:70)
at com.lily.web.t.<init>(SourceFile:77)
at com.lily.web.d.o(SourceFile:250)
at com.lily.web.e$2.run(SourceFile:1090)
And the related code is as following:
public Object invokeStaticMethod(String className, String methodName, Class<?>[] parameterTypes, Object... args)
{
try {
Method method = mClassLoader.loadClass(className).getMethod(methodName, parameterTypes);
method.setAccessible(true);
return method.**invoke**(null, args);
} catch {...}
}
Another stack trace:
Build fingerprint: htc/htccn_chs_cu/htc_a5dug:5.0.2/LRX22G/510432.3:user/release-keys
pid: 11542, tid: 11613 >>> com.lily.web:tools <<<
signal 11 (SIGSEGV), code 2 (SEGV_ACCERR), fault addr 90876000
#00 pc 0x0 /data/data/com.lily.web/jars_dex.dex (???)
#01 pc 0xa0a47 /system/lib/libart.so (???)
#02 pc 0xf4f49 /data/dalvik-cache/arm/system#framework#boot.oat (oatexec+1003337)
java.lang.Throwable:
******* Java stack for JNI crash *******
at java.lang.reflect.Method.**invoke**(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
As you can see, jars_fusion.dex is a big dex file of our app on Android platform. And there is a JNI crash while invoking a method in that dex, although the method is found successfully in the dex. Moreover, this issue can not be reproduced by my device or our testers, but is reported from crash auto collector system.
So what it can be the real cause of the issue, or it is just a system fault?

Android Nexus 5.0 Crash Fatal signal 11 (SIGSEGV), code 1 0x999e000c

I get this error on the Lollipop 5.0 Nexus.
This is all i get
Fatal signal 11 (SIGSEGV), code 1 0x999e000c
I get this error when I am trying to record using AudioRecorder class of Android.
I used NDK Stack to dump the crash and I am getting the following logs.
********** Crash dump: **********
Build fingerprint: 'google/hammerhead/hammerhead:5.0/LRX21O/1570415:user/release-keys'
pid: 1752, tid: 2184, name: pool-15-thread- >>> de.shopnow <<<
signal 11 (SIGSEGV), code 2 (SEGV_ACCERR), fault addr 0x9b6d2000
Stack frame #00 pc 00012f1c /system/lib/libc.so (__memcpy_base+95)
Stack frame #01 pc 000569b3 /system/lib/libmedia.so (android::AudioRecord::read(void*, unsigned int)+82)
Stack frame #02 pc 00095dbb /system/lib/libandroid_runtime.so
Stack frame #03 pc 00270fd7 /data/dalvik-cache/arm/system#framework#boot.oat
Has anyone experienced this?
I have faced and fixed this issue. This might be happening because of Hardware Acceleration. Go through this link for more details: http://developer.android.com/guide/topics/graphics/hardware-accel.html

Executing a command line process works on device but not on the emulator

I run the x264 command line encoder from native code using execl:
execl("/bin/sh", "sh", "-c", "/data/data/com.mycompany.myapp/files/components/x264enc5/x264enc5", NULL);
It works fine on device (Nexus 7 with Android 4.2.2), but on the emulator (tried 4.0.3 and 4.2.2) I'm getting this in the log:
F/libc ( 783): Fatal signal 4 (SIGILL) at 0x00000000
(code=268435456)
I/DEBUG ( 34): * ** * ** * ** * ** *
I/DEBUG ( 34): Build fingerprint:
'generic/sdk/generic:4.0.4/MR1/302030:eng/test-keys'
I/DEBUG ( 34): pid: 783, tid: 783 >>>
/data/data/com.mycompany.myapp/files/components/x264enc5/x264enc5
<<<
I/DEBUG ( 34): signal 4 (SIGILL), code 1 (ILL_ILLOPC), fault addr
000c3d68
Does anyone know what could be a possible reason for this problem?

Categories

Resources