llvm / llvm-project

The LLVM Project is a collection of modular and reusable compiler and toolchain technologies.
http://llvm.org
Other
26.41k stars 10.8k forks source link

Core dump occasionally occurs when using llvm-cov merge #92358

Open LittleGarfield opened 3 weeks ago

LittleGarfield commented 3 weeks ago

The backtrace is:

PLEASE submit a bug report to https://bugs.llvm.org/ and include the crash backtrace.

0 0x0000000000500503 llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) (/home/chenxiahui.garfield/env/covdata/tools/llvm-profdata.12.0.0+0x500503)

1 0x00000000004fe85e llvm::sys::RunSignalHandlers() (/home/chenxiahui.garfield/env/covdata/tools/llvm-profdata.12.0.0+0x4fe85e)

2 0x0000000000500c9f SignalHandler(int) (/home/chenxiahui.garfield/env/covdata/tools/llvm-profdata.12.0.0+0x500c9f)

3 0x00007f90378d10e0 __restore_rt (/lib/x86_64-linux-gnu/libpthread.so.0+0x110e0)

4 0x0000000000471cd0 llvm::readPGOFuncNameStrings(llvm::StringRef, llvm::InstrProfSymtab&) (/home/chenxiahui.garfield/env/covdata/tools/llvm-profdata.12.0.0+0x471cd0)

5 0x000000000047985c llvm::RawInstrProfReader::createSymtab(llvm::InstrProfSymtab&) (/home/chenxiahui.garfield/env/covdata/tools/llvm-profdata.12.0.0+0x47985c)

6 0x0000000000479104 llvm::RawInstrProfReader::readHeader(llvm::RawInstrProf::Header const&) (/home/chenxiahui.garfield/env/covdata/tools/llvm-profdata.12.0.0+0x479104)

7 0x0000000000478f1b llvm::RawInstrProfReader::readHeader() (/home/chenxiahui.garfield/env/covdata/tools/llvm-profdata.12.0.0+0x478f1b)

8 0x00000000004771c7 llvm::InstrProfReader::create(std::unique_ptr<llvm::MemoryBuffer, std::default_delete >) (/home/chenxiahui.garfield/env/covdata/tools/llvm-profdata.12.0.0+0x4771c7)

9 0x0000000000476f8c llvm::InstrProfReader::create(llvm::Twine const&) (/home/chenxiahui.garfield/env/covdata/tools/llvm-profdata.12.0.0+0x476f8c)

10 0x000000000041e31d loadInput(WeightedFile const&, (anonymous namespace)::SymbolRemapper, WriterContext) (/home/chenxiahui.garfield/env/covdata/tools/llvm-profdata.12.0.0+0x41e31d)

11 0x00000000004e4bbb std::_Function_handler<std::unique_ptr<std::__future_base::_Result_base, std::future_base::_Result_base::_Deleter> (), std::future_base::_Task_setter<std::unique_ptr<std::future_base::_Result, std::future_base::_Result_base::_Deleter>, std::_Bind_simple<std::reference_wrapper<std::function<void ()> > ()>, void> >::_M_invoke(std::_Any_data const&) (/home/chenxiahui.garfield/env/covdata/tools/llvm-profdata.12.0.0+0x4e4bbb)

12 0x00000000004e4b27 std::future_base::_State_baseV2::_M_do_set(std::function<std::unique_ptr<std::__future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool) (/home/chenxiahui.garfield/env/covdata/tools/llvm-profdata.12.0.0+0x4e4b27)

13 0x00007f90378ce759 __pthread_once_slow (/lib/x86_64-linux-gnu/libpthread.so.0+0xe759)

14 0x00000000004e483d std::__future_base::_Task_state<std::function<void ()>, std::allocator, void ()>::_M_run() (/home/chenxiahui.garfield/env/covdata/tools/llvm-profdata.12.0.0+0x4e483d)

15 0x00000000004e4139 std::thread::_Impl<std::_Bind_simple<llvm::ThreadPool::ThreadPool(llvm::ThreadPoolStrategy)::$_0 ()> >::_M_run() (/home/chenxiahui.garfield/env/covdata/tools/llvm-profdata.12.0.0+0x4e4139)

16 0x00007f9036aa4200 (/usr/local/lib/libstdc++.so.6+0xba200)

17 0x00007f90378c74a4 start_thread (/lib/x86_64-linux-gnu/libpthread.so.0+0x74a4)

18 0x00007f903651cd0f clone (/lib/x86_64-linux-gnu/libc.so.6+0xe8d0f)

Bus error (core dumped)

The core dump log is:

2024-05-16 15:00:08 [INFO] [main.c:61] [main] --------------coredump start-------------- 2024-05-16 15:00:08 [INFO] [util.c:125] [sync_env] Run Commnad is /home/chenxiahui.garfield/env/covdata/tools/llvm-profdata.12.0.0 merge 19841_1715841287292.profraw 4914_1715838833759.profraw 14814_1715830453203.profraw 2337_1715827832422.profraw 22667_1715830412853.profraw 18260_1715839844884.profraw 13709_1715827921275.profraw 7828_1715831815387.profraw 17828_1715830351967.profraw 20341_1715830406908.profraw 17394_1715836033059.profraw 28914_1715827798472.profraw 26831_1715840370117.profraw all.profdata -o tmp.profdata 2024-05-16 15:00:08 [INFO] [util.c:137] [sync_env] ENV: =/etc/sysop/coredump/bin/coredump_handler 2024-05-16 15:00:08 [INFO] [util.c:137] [sync_env] ENV: COREDUMP_INTER_PID=2189749 2024-05-16 15:00:08 [INFO] [util.c:137] [sync_env] ENV: COREDUMP_INTER_TIMESTAMP=1715842808 2024-05-16 15:00:08 [INFO] [util.c:137] [sync_env] ENV: COREDUMP_INTER_PROC_PATH=!data00!home!chenxiahui.garfield!env!covdata!tools!llvm-profdata.12.0.0 2024-05-16 15:00:08 [INFO] [util.c:137] [sync_env] ENV: HOME=/home/chenxiahui.garfield 2024-05-16 15:00:08 [INFO] [util.c:137] [sync_env] ENV: OLDPWD=/data00/home/chenxiahui.garfield 2024-05-16 15:00:08 [INFO] [util.c:137] [sync_env] ENV: LOGNAME=chenxiahui.garfield 2024-05-16 15:00:08 [INFO] [util.c:137] [sync_env] ENV: PATH=/usr/bin:/bin 2024-05-16 15:00:08 [INFO] [util.c:137] [sync_env] ENV: LANG=en_US.UTF-8 2024-05-16 15:00:08 [INFO] [util.c:137] [sync_env] ENV: SHELL=/bin/sh 2024-05-16 15:00:08 [INFO] [util.c:137] [sync_env] ENV: PWD=/home/chenxiahui.garfield/env/covdata/data/304375/304375android5346823cad 2024-05-16 15:00:08 [INFO] [util.c:137] [sync_env] ENV: COREDUMP_INTER_FNAME_SEXEC=llvm-profdata.12.0.0 2024-05-16 15:00:08 [INFO] [util.c:137] [sync_env] ENV: COREDUMP_INTER_FNAME_EXEC=/opt/tiger/cores/elf.2189749.1715842808569445.llvm-profdata.12.0.0 2024-05-16 15:00:08 [INFO] [util.c:137] [sync_env] ENV: COREDUMP_INTER_FNAME_CORE=/opt/tiger/cores/core.2189749.1715842808569445.llvm-profdata.12.0.0 2024-05-16 15:00:08 [INFO] [disk.c:66] [disk_check] process 2189749 RSS is: 478 MB, core saved disk current avail is 313664 MB, disk min reserve is 5120 MB 2024-05-16 15:00:08 [INFO] [freq_redis.c:28] [redis_freq_ctl] redis connect error: Name or service not known 2024-05-16 15:00:08 [INFO] [freq_sqlite3.c:32] [sqlite3_freq_ctl] COREDUMP_CTL_FREQ_LOCAL_PERIOD is: 600 2024-05-16 15:00:08 [INFO] [core.c:73] [check_dump] coredump control info: mode=local db frequency, ret=0, val=COREDUMP_BEHAVIOR_IGNORE 2024-05-16 15:00:08 [INFO] [main.c:101] [main] ignore write core 2024-05-16 15:00:08 [INFO] [tsdb.c:111] [sendto_tsdb] send to tsdb: prefix: sys.coredump.total, tags: version=3.0.6|exec_file_name=llvm-profdata.12.0.0 2024-05-16 15:00:08 [INFO] [tsdb.c:63] [_sendto_tsdb] send syscall error: Connection refused 2024-05-16 15:00:08 [INFO] [main.c:105] [main] --------------coredump done!--------------

question:

How can I solve this problem?