Crash: signal 11 (SIGSEGV), code 1 (SEGV_MAPERR) in libopenal.so

Hi,

I updated an app recently on Android (about 10 days ago) and immediately noticed a huge surge in my crash reports in google play console. Since then, i have updated the app 2 times (for reasons other than the crashes) and the crash reports are still alarmingly high. The number 1 crash report is in libopenal.so  (i have 2 other main crashes but i want to concentrate on this one first) (by main crashes i mean > 30 reports in 24 hours).

I know there are discussions in other threads with @vlad regarding various crashes. And i know build 3169 introduced an experimental fix for a bitmap related crash. But i think this is different because libopenal.so has to do with audio (i think). 

This crash report (42 total reports in 24 hours) is from yesterday’s update using build 3169:

backtrace: native: pc 00000000000a2f94 /data/app/com.marlustudio.frenchforkids-2/lib/arm/libopenal.so native: pc 0000000000016874 /data/app/com.marlustudio.frenchforkids-2/lib/arm/libopenal.so (alcCreateContext+436) native: pc 0000000000005ff7 /data/app/com.marlustudio.frenchforkids-2/lib/arm/libalmixer.so (ALmixer\_Init+214) native: pc 000000000011f784 /data/app/com.marlustudio.frenchforkids-2/lib/arm/libcorona.so native: pc 00000000000fe034 /data/app/com.marlustudio.frenchforkids-2/lib/arm/libcorona.so native: pc 000000000000cc04 /data/app/com.marlustudio.frenchforkids-2/lib/arm/liblua.so native: pc 000000000001ce18 /data/app/com.marlustudio.frenchforkids-2/lib/arm/liblua.so native: pc 000000000000d050 /data/app/com.marlustudio.frenchforkids-2/lib/arm/liblua.so native: pc 0000000000005524 /data/app/com.marlustudio.frenchforkids-2/lib/arm/liblua.so (lua\_call+32) native: pc 00000000000126cc /data/app/com.marlustudio.frenchforkids-2/lib/arm/liblua.so native: pc 000000000000cc04 /data/app/com.marlustudio.frenchforkids-2/lib/arm/liblua.so native: pc 000000000001c954 /data/app/com.marlustudio.frenchforkids-2/lib/arm/liblua.so native: pc 000000000000d050 /data/app/com.marlustudio.frenchforkids-2/lib/arm/liblua.so native: pc 0000000000005524 /data/app/com.marlustudio.frenchforkids-2/lib/arm/liblua.so (lua\_call+32) native: pc 00000000000126cc /data/app/com.marlustudio.frenchforkids-2/lib/arm/liblua.so native: pc 000000000000cc04 /data/app/com.marlustudio.frenchforkids-2/lib/arm/liblua.so native: pc 000000000001c954 /data/app/com.marlustudio.frenchforkids-2/lib/arm/liblua.so native: pc 000000000000d050 /data/app/com.marlustudio.frenchforkids-2/lib/arm/liblua.so native: pc 000000000000c35c /data/app/com.marlustudio.frenchforkids-2/lib/arm/liblua.so native: pc 000000000000d1c8 /data/app/com.marlustudio.frenchforkids-2/lib/arm/liblua.so native: pc 00000000000055a0 /data/app/com.marlustudio.frenchforkids-2/lib/arm/liblua.so (lua\_pcall+88) native: pc 00000000000f5970 /data/app/com.marlustudio.frenchforkids-2/lib/arm/libcorona.so native: pc 00000000000d7b08 /data/app/com.marlustudio.frenchforkids-2/lib/arm/libcorona.so native: pc 000000000012f4c8 /data/app/com.marlustudio.frenchforkids-2/lib/arm/libcorona.so native: pc 0000000000131478 /data/app/com.marlustudio.frenchforkids-2/lib/arm/libcorona.so native: pc 000000000012f980 /data/app/com.marlustudio.frenchforkids-2/lib/arm/libcorona.so native: pc 00000000001306dc /data/app/com.marlustudio.frenchforkids-2/lib/arm/libcorona.so native: pc 000000000002b530 /data/app/com.marlustudio.frenchforkids-2/lib/arm/libcorona.so native: pc 000000000067f69d /data/app/com.marlustudio.frenchforkids-2/oat/arm/base.odex

It affects various android devices with various android versions. Could someone from the corona team please have a look (@vlad maybe). I can not reproduce the crash. And the above report is all the info that the play console provides. As mentioned in other posts, this is a critical matter since google will soon be punishing apps with high crashes or ANRs.

Many thanks in advance,

Luay

EDIT: my crash is similar to the crash reported by @yogergames in this thread. However, the discussion there shifted to another crash related to the bitmap library and not to the audio library.

Engineering is looking into this.

Rob

@rob: thanks. 

Thank you. That thread is really about all crashes, we’re looking into this particular case at this moment (very similar crash).

It would be really helpful if you could provide a reproducible case of the crash. Backtraces rarely point to specific problems :frowning:

This is OpenAL connected, which means it is related to the sound. Could you try to test your game with sounds enabled, may be sending it to background and back, etc.

In this specific case I can see that crash is coming from doing some sound operations in body of main.lua

This is can be potentially very helpful to pinpoint where crash is coming from.

Basically, I can see from traceback that crash is invoked by something you call directly from main.lua (or subsequent functions). Not timers or events. Do you load/play sounds there or something else sound related? Did you make any related changes?

@vlads: thanks for looking into this.

Near the top of my main.lua, i ‘require’ several modules. One of them has/does sound operations as follows:

. . . . line 7: audio.reserveChannels( 14 ); line 8: audio.setVolume( 0.5 , {channel = 1} ); . . . line 27: bgMusic = audio.loadSound ( "audio/soundTrack.mp3"); . . . .

At the end of my main.lua i ‘goto’ a small scene (kind of a splash screen). That scene lasts for 2 seconds. When that scene triggers the ‘will hide’ event, the following audio code is executed:

bgMusicChannel = audio.play ( bgMusic, { channel=1, loops=-1, onComplete = bgMusicHandler } );

No other audio events occur until a scene or two later where i play various audio files and can switch the ‘bgMusic’ on or off.

Also, regarding reproducing the crash: I can’t. As pointed out by many developers in other posts, the only info i have about this crash I get from the play console. If it weren’t for them (google), i wouldn’t even know this crash existed.

Also, I tried your suggestion regarding sending the app to the background/foreground a few times while various sounds are being played. Guess what? Nothing crashed. Honestly, sometimes i think Google makes this stuff up.  :angry:

Thanks! We’ll try this out.

I hope you have better luck in crashing it.

Hi @vlads, any updates on this issue?

Can you try using audio.loadStream() instead of audio.loadSound()? 

And see if that has any impact?

Rob

We may have identified one of OpenAL issues. Currently working on fixing it.

@vlad: thanks for the update

Great news! Did you come to any resolution?

Any news on this one? Since this is also my top crash report in Google Play Console.

Which one exactly?

My error looks like this:

 

signal 11 (SIGSEGV), code 1 (SEGV_MAPERR)

libopenal.so

*** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** pid: 0, tid: 0 >>> io.torcia.idletraveler <<< backtrace:

#00 pc 00000000000a2f94 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/libopenal.so

#01 pc 0000000000016874 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/libopenal.so (alcCreateContext+436)

#02 pc 0000000000005ff7 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/libalmixer.so (ALmixer_Init+214)

#03 pc 000000000011de04 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/libcorona.so

#04 pc 00000000000fce20 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/libcorona.so

#05 pc 000000000000cc04 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/liblua.so

#06 pc 000000000001ce18 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/liblua.so

#07 pc 000000000000d050 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/liblua.so

#08 pc 0000000000005524 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/liblua.so (lua_call+32)

#09 pc 00000000000126cc /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/liblua.so

#10 pc 000000000000cc04 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/liblua.so

#11 pc 000000000001c954 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/liblua.so

#12 pc 000000000000d050 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/liblua.so

#13 pc 000000000000c35c /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/liblua.so

#14 pc 000000000000d1c8 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/liblua.so

#15 pc 00000000000055a0 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/liblua.so (lua_pcall+88)

#16 pc 00000000000f59e8 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/libcorona.so

#17 pc 00000000000d7b80 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/libcorona.so

#18 pc 000000000012f540 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/libcorona.so

#19 pc 00000000001314f0 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/libcorona.so

#20 pc 000000000012f9f8 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/libcorona.so

#21 pc 0000000000130754 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/libcorona.so

#22 pc 000000000002b530 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/lib/arm/libcorona.so

#23 pc 000000000001e847 /data/app/io.torcia.idletraveler-bxs5TeCZJan9TExzmEuhhA==/oat/arm/base.odex

We are seeing similar error messages, but they only seem to affect a small # of users. Is it possible that some of these errors only occur on rooted devices?

Latest examples:

Feb 17, 9:22 AM on app version 222

Asus ZenFone 2 (ZE551ML) (Z00A), 2048MB RAM, Android 5.0

Report 1 of 1

*** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***

pid: 0, tid: 0 >>> com.gmail.vegasfungames.vegasfun <<<

backtrace:

  #00  pc 000000000014c255  [anon:Mem_0x20000000]

  #01  pc 000000000000302f  [anon:Mem_0x10002002]

Yesterday, 11:51 PM on app version 222

HTC Desire 626s (htc_a32ewhl), 1536MB RAM, Android 6.0

Report 1

*** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***

pid: 0, tid: 0 >>> com.gmail.vegasfungames.vegasfun <<<

backtrace:

  #00  pc 00000000001fd972  /system/lib/libart.so (_ZN3art11interpreter6DoCallILb0ELb1EEEbPNS_9ArtMethodEPNS_6ThreadERNS_11ShadowFrameEPKNS_11InstructionEtPNS_6JValueE+509)

  #01  pc 0000000000201975  /system/lib/libart.so (_ZN3art11interpreterL8DoInvokeILNS_10InvokeTypeE4ELb0ELb1EEEbPNS_6ThreadERNS_11ShadowFrameEPKNS_11InstructionEtPNS_6JValueE+760)

  #02  pc 00000000000afffd  /system/lib/libart.so (_ZN3art11interpreter15ExecuteGotoImplILb1ELb0EEENS_6JValueEPNS_6ThreadEPKNS_7DexFile8CodeItemERNS_11ShadowFrameES2_+25796)

  #03  pc 00000000001e37d5  /system/lib/libart.so (artInterpreterToInterpreterBridge+312)

  #04  pc 00000000001fd36b  /system/lib/libart.so (_ZN3art11interpreter6DoCallILb0ELb0EEEbPNS_9ArtMethodEPNS_6ThreadERNS_11ShadowFrameEPKNS_11InstructionEtPNS_6JValueE+334)

  #05  pc 00000000000c0b87  /system/lib/libart.so (_ZN3art11interpreter15ExecuteGotoImplILb0ELb0EEENS_6JValueEPNS_6ThreadEPKNS_7DexFile8CodeItemERNS_11ShadowFrameES2_+26126)

  #06  pc 00000000001e3715  /system/lib/libart.so (artInterpreterToInterpreterBridge+120)

  #07  pc 00000000001fd36b  /system/lib/libart.so (_ZN3art11interpreter6DoCallILb0ELb0EEEbPNS_9ArtMethodEPNS_6ThreadERNS_11ShadowFrameEPKNS_11InstructionEtPNS_6JValueE+334)

  #08  pc 00000000000c07b3  /system/lib/libart.so (_ZN3art11interpreter15ExecuteGotoImplILb0ELb0EEENS_6JValueEPNS_6ThreadEPKNS_7DexFile8CodeItemERNS_11ShadowFrameES2_+25146)

  #09  pc 00000000001e3715  /system/lib/libart.so (artInterpreterToInterpreterBridge+120)

  #10  pc 00000000001fd36b  /system/lib/libart.so (_ZN3art11interpreter6DoCallILb0ELb0EEEbPNS_9ArtMethodEPNS_6ThreadERNS_11ShadowFrameEPKNS_11InstructionEtPNS_6JValueE+334)

  #11  pc 00000000000c07b3  /system/lib/libart.so (_ZN3art11interpreter15ExecuteGotoImplILb0ELb0EEENS_6JValueEPNS_6ThreadEPKNS_7DexFile8CodeItemERNS_11ShadowFrameES2_+25146)

  #12  pc 00000000001e3715  /system/lib/libart.so (artInterpreterToInterpreterBridge+120)

  #13  pc 00000000001fd36b  /system/lib/libart.so (_ZN3art11interpreter6DoCallILb0ELb0EEEbPNS_9ArtMethodEPNS_6ThreadERNS_11ShadowFrameEPKNS_11InstructionEtPNS_6JValueE+334)

  #14  pc 00000000000c07b3  /system/lib/libart.so (_ZN3art11interpreter15ExecuteGotoImplILb0ELb0EEENS_6JValueEPNS_6ThreadEPKNS_7DexFile8CodeItemERNS_11ShadowFrameES2_+25146)

  #15  pc 00000000001e34ed  /system/lib/libart.so (_ZN3art11interpreter30EnterInterpreterFromEntryPointEPNS_6ThreadEPKNS_7DexFile8CodeItemEPNS_11ShadowFrameE+84)

  #16  pc 00000000003ea3ab  /system/lib/libart.so (artQuickToInterpreterBridge+546)

  #17  pc 00000000000eab93  /system/lib/libart.so (art_quick_to_interpreter_bridge+34)

  #18  pc 00000000000e6421  /system/lib/libart.so (art_quick_invoke_stub_internal+64)

  #19  pc 00000000003ec66f  /system/lib/libart.so (art_quick_invoke_stub+170)

  #20  pc 00000000000ec81b  /system/lib/libart.so (_ZN3art9ArtMethod6InvokeEPNS_6ThreadEPjjPNS_6JValueEPKc+174)

  #21  pc 000000000031dc9b  /system/lib/libart.so (_ZN3art12InvokeMethodERKNS_33ScopedObjectAccessAlreadyRunnableEP8_jobjectS4_S4_j+654)

  #22  pc 00000000002d5d8b  /system/lib/libart.so (_ZN3artL13Method_invokeEP7_JNIEnvP8_jobjectS3_S3_+22)

  #23  pc 00000000024d4ab1  /system/framework/arm/boot.oat

Any update on this. Getting quite a few of these as well:

  #00  pc 00000000000a2f94  /data/app/com.iabuzz.Puzzle4KidsDinos-1/lib/arm/libopenal.so

  #01  pc 0000000000016874  /data/app/com.iabuzz.Puzzle4KidsDinos-1/lib/arm/libopenal.so (alcCreateContext+436)

  #02  pc 0000000000005ff7  /data/app/com.iabuzz.Puzzle4KidsDinos-1/lib/arm/libalmixer.so (ALmixer_Init+214)

  #03  pc 000000000011f78c  /data/app/com.iabuzz.Puzzle4KidsDinos-1/lib/arm/libcorona.so

  #04  pc 00000000000fe03c  /data/app/com.iabuzz.Puzzle4KidsDinos-1/lib/arm/libcorona.so

  #05  pc 000000000000cc04  /data/app/com.iabuzz.Puzzle4KidsDinos-1/lib/arm/liblua.so

  #06  pc 000000000001ce18  /data/app/com.iabuzz.Puzzle4KidsDinos-1/lib/arm/liblua.so

  #07  pc 000000000000d050  /data/app/com.iabuzz.Puzzle4KidsDinos-1/lib/arm/liblua.so

  #08  pc 000000000000c35c  /data/app/com.iabuzz.Puzzle4KidsDinos-1/lib/arm/liblua.so

  #09  pc 000000000000d1c8  /data/app/com.iabuzz.Puzzle4KidsDinos-1/lib/arm/liblua.so

  #10  pc 00000000000055a0  /data/app/com.iabuzz.Puzzle4KidsDinos-1/lib/arm/liblua.so (lua_pcall+88)

  #11  pc 00000000000f5978  /data/app/com.iabuzz.Puzzle4KidsDinos-1/lib/arm/libcorona.so

  #12  pc 00000000000d7b10  /data/app/com.iabuzz.Puzzle4KidsDinos-1/lib/arm/libcorona.so

  #13  pc 000000000012f4d0  /data/app/com.iabuzz.Puzzle4KidsDinos-1/lib/arm/libcorona.so

  #14  pc 0000000000131480  /data/app/com.iabuzz.Puzzle4KidsDinos-1/lib/arm/libcorona.so

  #15  pc 000000000012f988  /data/app/com.iabuzz.Puzzle4KidsDinos-1/lib/arm/libcorona.so

  #16  pc 00000000001306e4  /data/app/com.iabuzz.Puzzle4KidsDinos-1/lib/arm/libcorona.so

  #17  pc 000000000002b540  /data/app/com.iabuzz.Puzzle4KidsDinos-1/lib/arm/libcorona.so

  #18  pc 0000000000d37555  /data/app/com.iabuzz.Puzzle4KidsDinos-1/oat/arm/base.odex

Our engineers are working on a replacement audio library for Android. This is in closed testing now. Hopefully we will have it out soon which should address many of these OpenAL crashes.

Rob

Please give us the tentative release/update date on this.