public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Peter Barada <pbarada@mail.wm.sps.mot.com>
To: gcc@gcc.gnu.org
Subject: gcc-3.0.4 ICE for m68k-elf target
Date: Fri, 22 Feb 2002 14:14:00 -0000	[thread overview]
Message-ID: <200202222154.g1MLspt21016@hyper.wm.sps.mot.com> (raw)


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;
    }
  }
}

                 reply	other threads:[~2002-02-22 21:55 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200202222154.g1MLspt21016@hyper.wm.sps.mot.com \
    --to=pbarada@mail.wm.sps.mot.com \
    --cc=gcc@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).