使用ASAN编译的进程将打印ASAN:SIGSEGV并冻结在pthread_cond_wait

时间:2018-08-09 13:04:27

标签: gcc address-sanitizer

在Ubuntu 16.04 LTS上,我使用-fsanitize=address使用gcc-4.8.3编译了一个项目(我不能使用其他版本)。在启动过程中, 冻结

==10773== T5: stack [0x7fffd8f37000,0x7fffd9738000) size 0x801000; local=0x7fffd9736eec
==1== Parsed ASAN_OPTIONS: SHADOW_OFFSET=0x7fff0000:verbosity=1:debug=true:legacy_pthread_cond=true
==1== AddressSanitizer: libc interceptors initialized
|| `[0x10007fff8000, 0x7fffffffffff]` || HighMem    ||
|| `[0x02008fff7000, 0x10007fff7fff]` || HighShadow ||
|| `[0x00008fff7000, 0x02008fff6fff]` || ShadowGap  ||
|| `[0x00007fff8000, 0x00008fff6fff]` || LowShadow  ||
|| `[0x000000000000, 0x00007fff7fff]` || LowMem     ||
MemToShadow(shadow): 0x00008fff7000 0x000091ff6dff 0x004091ff6e00 0x02008fff6fff
red_zone=16
malloc_context_size=30
SHADOW_SCALE: 3
SHADOW_GRANULARITY: 8
SHADOW_OFFSET: 7fff8000
==1== Installed the sigaction for signal 11
==1== T0: stack [0x7fffff7ff000,0x7ffffffff000) size 0x800000; local=0x7fffffffd4bc
==1== AddressSanitizer Init done
ASAN:SIGSEGV

在gdb中,我看到我的代码已挂起:

#0  pthread_cond_wait@@GLIBC_2.3.2 () at ../sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S:185

,其余的回溯跟踪已损坏。

可以通过ASAN_OPTIONS修复的附加配置是否存在明显的错误?

0 个答案:

没有答案