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.hu...@embedded-brains.de
PGP     : Public key available on request.

Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.

Reply via email to