TI中文支持网
TI专业的中文技术问题搜集分享网站

tisdk-rootfs提供的glibc 2.21缺少unwind table,unwind必现crash

downloads.ti.com/…/index_FDS.html

使用tisdk提供的包(gcc5.3 glibc2.21),链接如下

http://downloads.ti.com/infotainment/esd/jacinto6/processor-sdk-linux-automotive/03_01_00_03/exports/tisdk-rootfs-image-dra7xx-evm.tar.xz

由于有内存分析的需求,使用gperftools做内存分析(在每次malloc节点做unwind并记录调用栈)

应用启动必现crash,crash发生在回溯ld-2.21.so的栈

通过readelf -u ld-2.21.so查看unwind table,发现只有19个entries(正常应该有200个左右)

发现问题原因是ld-2.21.so的编译选项没有-funwind-tables,导致缺少栈回溯必须的unwind table

下载了一份来自gnu的glibc 2.21源码,使用ti提供的toolchain加-funwind-tables选项后编译可以正常执行unwind

tisdk内的ld-2.21.so:

Unwind table index '.ARM.exidx' at offset 0x16e24 contains 19 entries

加-funwind-tables选项编译的ld-2.21.so:

Unwind table index '.ARM.exidx' at offset 0x16f0c contains 170 entries:

请问:tisdk提供的glibc库是否有带unwind table版本的?

Shine:

抱歉,e2echina不支持DRA系列的汽车电子芯片,您可以联系TI的销售或者代理,也可以到e2e英文论坛咨询。
e2e.ti.com/…/791

赞(0)
未经允许不得转载:TI中文支持网 » tisdk-rootfs提供的glibc 2.21缺少unwind table,unwind必现crash
分享到: 更多 (0)