lockfree on armv7, bus error (core dumped)
- Dominant language
- C++
- Stars
- 160
- Forks
- 99
- PR merge metrics
- No merged PRs in 30d
Description
``` c++
# root at alarmpi in ~ [21:36:15]
$ cat test.cpp
#include
#include
#include
std::atomic_int intcount;
boost::lockfree::queue intpool(100);
int main()
{
return 0;
}
# root at alarmpi in ~ [21:36:53]
$ g++ test.cpp -std=c++11
# root at alarmpi in ~ [21:37:15]
$ ./a.out
[1] 31406 bus error (core dumped) ./a.out
# root at alarmpi in ~ [21:37:27]
$ coredumpctl gdb 31406
PID: 31406 (a.out)
UID: 0 (root)
GID: 0 (root)
Signal: 7 (BUS)
Timestamp: 一 2015-04-27 21:37:27 CST (12s ago)
Command Line: ./a.out
Executable: /root/a.out
Control Group: /user.slice/user-0.slice/session-c6.scope
Unit: session-c6.scope
Slice: user-0.slice
Session: c6
Owner UID: 0 (root)
Boot ID: f2ff2834fe86475d8008560472158aa9
Machine ID: 20d4f52b53de4dd9aa7ac72e93285b0a
Hostname: alarmpi
Coredump: /var/lib/systemd/coredump/core.a\x2eout.0.f2ff2834fe86475d8008560472158aa9.31406.1430141847000000.lz4
Message: Process 31406 (a.out) of user 0 dumped core.
GNU gdb (GDB) 7.9
Copyright (C) 2015 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "armv7l-unknown-linux-gnueabihf".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
.
Find the GDB manual and other documentation resources online at:
.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /root/a.out...(no debugging symbols found)...done.
[New LWP 31406]
Core was generated by `./a.out'.
Program terminated with signal SIGBUS, Bus error.
#0 0x00010ec8 in std::atomic::node, std::allocator::node> >::freelist_node> >::load(std::memory_order) const ()
(gdb) bt
#0 0x00010ec8 in std::atomic::node, std::allocator::node> >::freelist_node> >::load(std::memory_order) const ()
#1 0x0001110c in boost::lockfree::detail::freelist_stack::node, std::allocator::node> >::deallocate_impl_unsafe(boost::lockfree::queue::node*) ()
#2 0x00010e94 in void boost::lockfree::detail::freelist_stack::node, std::allocator::node> >::deallocate(boost::lockfree::queue::node*) ()
#3 0x00010bd0 in boost::lockfree::detail::freelist_stack::node, std::allocator::node> >::freelist_stack::node> >(std::allocator::node> const&, unsigned int) ()
#4 0x00010a34 in boost::lockfree::queue::queue(unsigned int) ()
#5 0x000107e8 in __static_initialization_and_destruction_0(int, int) ()
#6 0x00010820 in _GLOBAL__sub_I_intcount ()
#7 0x000119f4 in __libc_csu_init ()
#8 0x76c22ccc in __libc_start_main () from /usr/lib/libc.so.6
#9 0x0001065c in _start ()
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
(gdb) q
# root at alarmpi in ~ [21:37:47]
$ uname -a
Linux alarmpi 3.18.11-4-ARCH #1 SMP PREEMPT Tue Apr 21 21:52:58 MDT 2015 armv7l GNU/Linux
# root at alarmpi in ~ [21:37:50]
$ g++ -v
使用内建 specs。
COLLECT_GCC=g++
COLLECT_LTO_WRAPPER=/usr/lib/gcc/armv7l-unknown-linux-gnueabihf/4.9.2/lto-wrapper
目标:armv7l-unknown-linux-gnueabihf
配置为:/build/gcc/src/gcc-4.9-20150304/configure --prefix=/usr --libdir=/usr/lib --libexecdir=/usr/lib --mandir=/usr/share/man --infodir=/usr/share/info --with-bugurl=https://github.com/archlinuxarm/PKGBUILDs/issues --enable-languages=c,c++,fortran,go,lto,objc,obj-c++ --enable-shared --enable-threads=posix --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-clocale=gnu --disable-libstdcxx-pch --disable-libssp --enable-gnu-unique-object --enable-linker-build-id --enable-cloog-backend=isl --enable-lto --enable-plugin --enable-install-libiberty --with-linker-hash-style=gnu --disable-multilib --disable-werror --enable-checking=release --host=armv7l-unknown-linux-gnueabihf --build=armv7l-unknown-linux-gnueabihf --with-arch=armv7-a --with-float=hard --with-fpu=vfpv3-d16
线程模型:posix
gcc 版本 4.9.2 20150304 (prerelease) (GCC)
# root at alarmpi in ~ [21:37:58]
$ /lib/libc-2.21.so
GNU C Library (GNU libc) stable release version 2.21, by Roland McGrath et al.
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.
Compiled by GNU CC version 4.9.2 20150304 (prerelease).
Available extensions:
crypt add-on version 2.1 by Michael Glad and others
GNU Libidn by Simon Josefsson
Native POSIX Threads Library by Ulrich Drepper et al
BIND-8.2.3-T5B
libc ABIs: UNIQUE
For bug reporting instructions, please see:
.
```
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.