I think I have found a bug. This is in stock gcc 4.8.1...

My backend does not use the 'enabled' attribute; therefore the following
code in insn-attr.h kicks in:

  #ifndef HAVE_ATTR_enabled
  #define HAVE_ATTR_enabled 0
  #endif

Therefore the following code in gcc/lra-constraints.c is enabled:

  #ifdef HAVE_ATTR_enabled
      if (curr_id->alternative_enabled_p != NULL
          && ! curr_id->alternative_enabled_p[nalt])
        continue;
  #endif

->alternative_enabled_p is bogus; therefore segfault.

Elsewhere I see structures of the form:

  #if HAVE_ATTR_enabled
  ...
  #endif

So I think that #ifdef above is a straight typo. Certainly, changing it
to a #if makes the crash go away...

-- 
┌─── dg@cowlark.com ───── http://www.cowlark.com ─────
│ "Every planet is weird. I spent six weeks on a moon where the
│ principal form of recreation was juggling geese. Baby geese. Goslings.
│ They were juggled." --- Firefly, _Our Mrs. Reynolds_

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to