This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

gcc-3.0.4 ICE for m68k-elf target



The following chunk of code fails to build m68k-elf for -m5200. It
does build for -m68000, -m68020, -m68030, -m68040, -m68060
A bug report has bene filed.

-- 
Peter Barada                                   Peter.Barada@motorola.com
Wizard                                         781-852-2768 (direct)
WaveMark Solutions(wholly owned by Motorola)   781-270-0193 (fax)


[pbarada: /tmp] > /usr/local/wave/cross-test-304/bin/m68k-elf-gcc -v
Reading specs from /usr/local/wave/cross-test-304/lib/gcc-lib/m68k-elf/3.0.4/specs
Configured with: /home/pbarada/work/cvs-wavemark/cross-linux-tools/gcc-3.0.4/configure --target=m68k-elf --prefix=/usr/local/wave/cross-test-304 --enable-languages=c,c++ --with-local-prefix=/usr/local/wave/cross-test-304/m68k-elf --with-newlib
Thread model: single
gcc version 3.0.4

[pbarada: /tmp] > /usr/local/wave/cross-test-304/bin/m68k-elf-gcc -fno-exceptions -S -gstabs -malign-int -Wall -Wno-format -m5200 /tmp/cfprintf4.c -o /tmp/cfprintf4.s -da
/tmp/cfprintf4.c: In function `_vformat':
/tmp/cfprintf4.c:58: Insn does not satisfy its constraints:

(insn 258 38 185 (set (reg:QI 8 %a0)
        (mem/f:QI (plus:SI (reg/f:SI 14 %a6)
                (const_int -1 [0xffffffff])) 0)) 37 {*m68k.md:1060} (nil)
    (nil))
/tmp/cfprintf4.c:58: Internal compiler error in final_scan_insn, at final.c:2876
Please submit a full bug report,

source:

typedef __builtin_va_list va_list;
extern char *_fmtcvt(unsigned int value, int base, char *cp);
extern int strlen(const char *s);
void _vformat (void (*putsub)(char c, char **p),
              char **putbuf, const char *fmt, va_list argp)
{
  char c;
  int i;
  char *cp;
  char s[512];

  cp = s+14;

  for (;;) {
    c = *fmt++;
    if (!c) {
      break;
    }

    s[14] = 0;

    switch (c) {
    case 'o':
      cp = _fmtcvt((unsigned int)(__builtin_va_arg(argp, unsigned int)),
                   8, s+14);
      i = (s+14) - cp;
      break;

    case 'u':
      cp = _fmtcvt((unsigned int)(__builtin_va_arg(argp, unsigned int)),
                   10, s+14);
      i = (s+14) - cp;
      break;

    case 'd':
      cp = _fmtcvt((unsigned int)(__builtin_va_arg(argp, int)), -10, s+14);
      i = (s+14) - cp;
      break;

    case 'p':
      cp = _fmtcvt((unsigned int)(__builtin_va_arg(argp, void*)), 16, s+14);
      i = (s+14) - cp;
      break;

    case 's':
      i = strlen(cp = __builtin_va_arg(argp, char *));
      break;

    default:
      cp = s;
      s[0] = c;
      s[i = 1] = 0;
    }
    if (i == 0) {
      continue;
    }
  }
}


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]