[RTEMS Project] #2830: throwing std::runtime on PC BSP fails.
RTEMS trac
trac at rtems.org
Sat Sep 12 07:47:29 UTC 2020
#2830: throwing std::runtime on PC BSP fails.
-------------------------+----------------------------
Reporter: Chris Johns | Owner: Needs Funding
Type: defect | Status: assigned
Priority: normal | Milestone: Indefinite
Component: unspecified | Version: 5
Severity: normal | Resolution:
Keywords: | Blocked By:
Blocking: |
-------------------------+----------------------------
Comment (by Sebastian Huber):
We have two different issues:
1. The i386 BSPs use probably obsolete instruction sets which lead to the
use of libatomic.
2. If libatomic is used, then there is some broken behaviour.
The libatomic seems to work fine on other architectures, e.g. it is also
used by the sparc/erc32 BSP. Here the cdtest.exe test program runs
successfully and executes a similar context:
{{{
Breakpoint 2, libat_fetch_add_4 (mptr=0x203d798, opval=4294967295,
smodel=4) at ../../../gnu-mirror-gcc-c72a1b6/libatomic/fop_n.c:164
164 ../../../gnu-mirror-gcc-c72a1b6/libatomic/fop_n.c: No such file or
directory.
(gdb) bt
#0 libat_fetch_add_4 (mptr=0x203d798, opval=4294967295, smodel=4) at
../../../gnu-mirror-gcc-c72a1b6/libatomic/fop_n.c:164
#1 0x0200eda0 in __gnu_cxx::__exchange_and_add (__val=-1,
__mem=0x203d798) at /home/EB/sebastian_h/src/rtems-source-
builder/rtems/build/sparc-rtems6-gcc-c72a1b6-newlib-ece49e4-x86_64-linux-
gnu-1/build/sparc-rtems6/libstdc++-v3/include/ext/atomicity.h:84
#2 __gnu_cxx::__exchange_and_add_dispatch (__val=-1, __mem=0x203d798) at
/home/EB/sebastian_h/src/rtems-source-builder/rtems/build/sparc-rtems6
-gcc-c72a1b6-newlib-ece49e4-x86_64-linux-gnu-1/build/sparc-
rtems6/libstdc++-v3/include/ext/atomicity.h:84
#3 __gnu_cxx::__eh_atomic_dec (__count=0x203d798) at ../../../../gnu-
mirror-gcc-c72a1b6/libstdc++-v3/libsupc++/eh_atomics.h:72
#4 __gxx_exception_cleanup (code=_URC_FOREIGN_EXCEPTION_CAUGHT,
exc=0x203d7d0) at ../../../../gnu-mirror-gcc-
c72a1b6/libstdc++-v3/libsupc++/eh_throw.cc:46
#5 0x0201e584 in _Unwind_DeleteException (exc=0x203d7d0) at ../../../gnu-
mirror-gcc-c72a1b6/libgcc/unwind.inc:283
#6 0x02001a44 in foo_function () at
../../../testsuites/samples/cdtest/main.cc:198
#7 main_task () at ../../../testsuites/samples/cdtest/main.cc:212
#8 0x02006b8c in _Thread_Entry_adaptor_numeric (executing=0x2032ae8
<_RTEMS_tasks_Objects>) at
../../../cpukit/score/src/threadentryadaptornumeric.c:25
#9 0x02006c64 in _Thread_Handler () at
../../../cpukit/score/src/threadhandler.c:143
#10 0x02006c04 in _Thread_Handler () at
../../../cpukit/score/src/threadhandler.c:87
}}}
--
Ticket URL: <http://devel.rtems.org/ticket/2830#comment:11>
RTEMS Project <http://www.rtems.org/>
RTEMS Project
More information about the bugs
mailing list