ncnn Fatal signal 11 (SIGSEGV) 使用GPU加速崩溃

如果你的报错堆栈中包含以下信息,其中的关键信息是 anon:dalvik-classes2.dex extracted in memory

Fatal signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x3c in tid 8619 (eplabv3plusncnn), pid 8619 ()
2023-10-07 15:48:31.395  9793-9793  DEBUG                   crash_dump64                         A  pid: 8619, tid: 8619, name: eplabv3plusncnn  >>> com.tencent.deeplabv3plusncnn <<<
2023-10-07 15:48:31.669  9793-9793  DEBUG                   crash_dump64                         A        #00 pc 000000000017c644  /data/app/com.tencent.deeplabv3plusncnn-1L2ULzYH_2mgLQF9zeq2wA==/base.apk!libdeeplabv3plusncnn.so (offset 0x3c8e000) (BuildId: f7ce76fecaedbe3885c2cbe6ef2143adf91ff757)
2023-10-07 15:48:31.669  9793-9793  DEBUG                   crash_dump64                         A        #01 pc 000000000017c470  /data/app/com.tencent.deeplabv3plusncnn-1L2ULzYH_2mgLQF9zeq2wA==/base.apk!libdeeplabv3plusncnn.so (offset 0x3c8e000) (BuildId: f7ce76fecaedbe3885c2cbe6ef2143adf91ff757)
2023-10-07 15:48:31.669  9793-9793  DEBUG                   crash_dump64                         A        #02 pc 0000000000205b90  /data/app/com.tencent.deeplabv3plusncnn-1L2ULzYH_2mgLQF9zeq2wA==/base.apk!libdeeplabv3plusncnn.so (offset 0x3c8e000) (BuildId: f7ce76fecaedbe3885c2cbe6ef2143adf91ff757)
2023-10-07 15:48:31.669  9793-9793  DEBUG                   crash_dump64                         A        #03 pc 0000000000169f50  /data/app/com.tencent.deeplabv3plusncnn-1L2ULzYH_2mgLQF9zeq2wA==/base.apk!libdeeplabv3plusncnn.so (offset 0x3c8e000) (BuildId: f7ce76fecaedbe3885c2cbe6ef2143adf91ff757)
2023-10-07 15:48:31.669  9793-9793  DEBUG                   crash_dump64                         A        #04 pc 000000000016a074  /data/app/com.tencent.deeplabv3plusncnn-1L2ULzYH_2mgLQF9zeq2wA==/base.apk!libdeeplabv3plusncnn.so (offset 0x3c8e000) (BuildId: f7ce76fecaedbe3885c2cbe6ef2143adf91ff757)
2023-10-07 15:48:31.669  9793-9793  DEBUG                   crash_dump64                         A        #05 pc 000000000016a074  /data/app/com.tencent.deeplabv3plusncnn-1L2ULzYH_2mgLQF9zeq2wA==/base.apk!libdeeplabv3plusncnn.so (offset 0x3c8e000) (BuildId: f7ce76fecaedbe3885c2cbe6ef2143adf91ff757)
2023-10-07 15:48:31.669  9793-9793  DEBUG                   crash_dump64                         A        #06 pc 000000000016a750  /data/app/com.tencent.deeplabv3plusncnn-1L2ULzYH_2mgLQF9zeq2wA==/base.apk!libdeeplabv3plusncnn.so (offset 0x3c8e000) (BuildId: f7ce76fecaedbe3885c2cbe6ef2143adf91ff757)
2023-10-07 15:48:31.669  9793-9793  DEBUG                   crash_dump64                         A        #07 pc 000000000016a750  /data/app/com.tencent.deeplabv3plusncnn-1L2ULzYH_2mgLQF9zeq2wA==/base.apk!libdeeplabv3plusncnn.so (offset 0x3c8e000) (BuildId: f7ce76fecaedbe3885c2cbe6ef2143adf91ff757)
2023-10-07 15:48:31.669  9793-9793  DEBUG                   crash_dump64                         A        #08 pc 000000000016f680  /data/app/com.tencent.deeplabv3plusncnn-1L2ULzYH_2mgLQF9zeq2wA==/base.apk!libdeeplabv3plusncnn.so (offset 0x3c8e000) (BuildId: f7ce76fecaedbe3885c2cbe6ef2143adf91ff757)
2023-10-07 15:48:31.669  9793-9793  DEBUG                   crash_dump64                         A        #09 pc 000000000016eefc  /data/app/com.tencent.deeplabv3plusncnn-1L2ULzYH_2mgLQF9zeq2wA==/base.apk!libdeeplabv3plusncnn.so (offset 0x3c8e000) (BuildId: f7ce76fecaedbe3885c2cbe6ef2143adf91ff757)
2023-10-07 15:48:31.669  9793-9793  DEBUG                   crash_dump64                         A        #10 pc 0000000000137a4c  /data/app/com.tencent.deeplabv3plusncnn-1L2ULzYH_2mgLQF9zeq2wA==/base.apk!libdeeplabv3plusncnn.so (offset 0x3c8e000) (BuildId: f7ce76fecaedbe3885c2cbe6ef2143adf91ff757)
2023-10-07 15:48:31.669  9793-9793  DEBUG                   crash_dump64                         A        #11 pc 00000000001367cc  /data/app/com.tencent.deeplabv3plusncnn-1L2ULzYH_2mgLQF9zeq2wA==/base.apk!libdeeplabv3plusncnn.so (offset 0x3c8e000) (Java_com_tencent_deeplabv3plus_Deeplabv3plusNcnn_YoloFaceDetect+176) (BuildId: f7ce76fecaedbe3885c2cbe6ef2143adf91ff757)
2023-10-07 15:48:31.670  9793-9793  DEBUG                   crash_dump64                         A        #19 pc 0000000000000a92  [anon:dalvik-classes2.dex extracted in memory from /data/app/com.xxx.xxxx-1L2ULzYH_2mgLQF9zeq2wA==/base.apk!classes2.dex]

出现了这个说明是误用了GPU加速,参考 stackoverflow 禁用硬件加速

此时的 opt.use_vulkan_compute应该设置成 false,即使用CPU不使用GPU加速

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值