public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jay K <jay.krell@cornell.edu>
To: gcc-help <gcc-help@gcc.gnu.org>
Subject: alpha-dec-vms __sync_lock_test_and_set char/short -O2 fails on all  4.3.x and 4.4.x
Date: Mon, 26 Apr 2010 04:42:00 -0000	[thread overview]
Message-ID: <COL101-W5255A9AF86C84F3B4A424CE6050@phx.gbl> (raw)


For the archives:

void f5( short* a,  short b,  short c)
    {  __sync_lock_test_and_set(a, b, c); }

jbook2:~ jay$  /obj/gcc442/avms/gcc/cc1 4.c -O2
 f5
Analyzing compilation unit
Performing interprocedural optimizations
 <visibility> <early_local_cleanups> <summary generate> <cp> <inline> <static-var> <pure-const>Assembling functions:
 f5
4.c: In function 'f5':
4.c:2: internal compiler error: in emit_move_insn, at expr.c:3405
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.

Seems to occur on all of 4.3.0, 4.3.1, 4.3.2, 4.3.3, 4.3.4, 4.4.0, 4.4.1, 4.4.2, 4.4.3.
  I'm not sure I tried all of them, but I tried many.
It also occurs for char, unsigned short, presumably unsigned char.
This platform is a bit wierd because it has 64bit registers but 32bit long/void*/size_t.
It does not occur without -O2.
It does NOT occur on 4.5.0.
I'll compare 4.4.3 and 4.5.0, try to find a small patch to fix, since I'm using a 4.3.0-based tree.
ChangeLog doesn't make it obvious. I tried patching 4.3.0 with some 4.5.0 changes, before I thought to try the in-between versions.

 /src/gcc-4.3.0/configure -target alpha-dec-vms -disable-multilib -disable-dependency-tracking -disable-shared -enable-static -verbose -enable-sjlj-exceptions

There are also assertion failures and other problems in some of these releases when building libgcc.
e.g.:

/src/gcc-4.4.1/libgcc/../gcc/libgcc2.c: In function ‘__gcc_bcmp’:
/src/gcc-4.4.1/libgcc/../gcc/libgcc2.c:1993: error: unrecognizable insn:
(insn 61 60 62 6 /src/gcc-4.4.1/libgcc/../gcc/libgcc2.c:1987 (set (reg:DI 122)
        (plus:SI (subreg:SI (reg:DI 119) 0)
            (const_int 1 [0x1]))) -1 (nil))
/src/gcc-4.4.1/libgcc/../gcc/libgcc2.c:1993: internal compiler error: in extract_insn, at recog.c:2048
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.
make[2]: *** [__gcc_bcmp.o] Error 1
make[1]: *** [all-target-libgcc] Error 2
make: *** [all] Error 2


Can just remove the __gcc_bcmp function I think.
(I don't have a working-enough cross toolset to know it isn't referenced.)



/src/gcc-4.4.2/gcc/config/alpha/vms-dwarf2eh.asm:31:Unknown pseudo-op: .global
/src/gcc-4.4.2/gcc/config/alpha/vms-dwarf2eh.asm:31:Rest of line ignored. 1st junk character valued 95 (_).m

Fix is to change it to .globl I think.

  - Jay

 		 	   		  

             reply	other threads:[~2010-04-25 15:22 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-26  4:42 Jay K [this message]
2010-04-26  4:47 ` Manuel López-Ibáñez
2010-04-26 13:51   ` Jay K

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=COL101-W5255A9AF86C84F3B4A424CE6050@phx.gbl \
    --to=jay.krell@cornell.edu \
    --cc=gcc-help@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).