This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: __sync_-builtins cause undefined references on some sparc targets
- From: Sebastian Huber <sebastian dot huber at embedded-brains dot de>
- To: Eric Botcazou <ebotcazou at adacore dot com>, Jan dot Sommer at dlr dot de
- Cc: gcc at gcc dot gnu dot org, soja-lists at aries dot uberspace dot de
- Date: Fri, 3 Mar 2017 13:35:11 +0100
- Subject: Re: __sync_-builtins cause undefined references on some sparc targets
- Authentication-results: sourceware.org; auth=none
- References: <DE6CFD2ED4BCD440A2DE18E253A8FDF45A376F@DLREXMBX01.intra.dlr.de> <1808636.TyOe3qnzdO@polaris> <DE6CFD2ED4BCD440A2DE18E253A8FDF45A3FFC@DLREXMBX01.intra.dlr.de> <1661642.r5QBhQYH2J@polaris>
On 03/03/17 13:23, Eric Botcazou wrote:
Is libbacktrace excluded from the build, or is it build but broken?
Neither, it's presumably falls back to __atomic. No big deal in any case,
since you'll presumably never use libbacktrace in practice.
We have (libgcc/config/gthr-rtems.h)
static inline int
__gthread_active_p (void)
{
return 1;
}
and (libgfortran/runtime/backtrace.c)
void
show_backtrace (bool in_signal_handler)
{
struct backtrace_state *lbstate;
struct mystate state = { 0, false, in_signal_handler };
lbstate = backtrace_create_state (NULL, __gthread_active_p (),
error_callback, NULL);
and (libgfortran/runtime/backtrace.c)
struct backtrace_state *
backtrace_create_state (const char *filename, int threaded,
backtrace_error_callback error_callback,
void *data)
{
struct backtrace_state init_state;
struct backtrace_state *state;
#ifndef HAVE_SYNC_FUNCTIONS
if (threaded)
{
error_callback (data, "backtrace library does not support
threads", 0);
return NULL;
}
#endif
So, I doubt this works for RTEMS.
I guess libgfortran needs an option to be a bit less verbose on some
targets.
--
Sebastian Huber, embedded brains GmbH
Address : Dornierstr. 4, D-82178 Puchheim, Germany
Phone : +49 89 189 47 41-16
Fax : +49 89 189 47 41-09
E-Mail : sebastian.huber@embedded-brains.de
PGP : Public key available on request.
Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.