public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Michael Chastain <mec.gnu@mindspring.com>
To: rakdver@atrey.karlin.mff.cuni.cz, gcc@gcc.gnu.org
Subject: Build failure, HEAD, java/lang/Class.o
Date: Mon, 06 Sep 2004 15:57:00 -0000	[thread overview]
Message-ID: <413C88F4.nailLGW11O4SS@mindspring.com> (raw)

I haven't seen this build failure reported yet.

The new tree-ssa-loop-ivopts.c code is language-independent, but it uses
language-specific type nodes such as unsigned_type_node and
long_unsigned_type_node, which are not available in some languages such
as Java.

My system:

  native i686-pc-linux gnu, red hat 8, 128 megabytes of memory
  building gcc HEAD with gcc 3.3.4.

The build log says:

  /berman/fsf/_today_/berman/build/target/native/gcc/gcc-HEAD-as-2.15-ld-2.15/gcc/gcj -B/berman/fsf/_today_/berman/build/target/native/gcc/gcc-HEAD-as-2.15-ld-2.15/gcc/ -B/berman/fsf/_today_/berman/install/target/native/gcc/gcc-HEAD-as-2.15-ld-2.15/i686-pc-linux-gnu/bin/ -B/berman/fsf/_today_/berman/install/target/native/gcc/gcc-HEAD-as-2.15-ld-2.15/i686-pc-linux-gnu/lib/ -isystem /berman/fsf/_today_/berman/install/target/native/gcc/gcc-HEAD-as-2.15-ld-2.15/i686-pc-linux-gnu/include -isystem /berman/fsf/_today_/berman/install/target/native/gcc/gcc-HEAD-as-2.15-ld-2.15/i686-pc-linux-gnu/sys-include -ffloat-store -fno-omit-frame-pointer -fclasspath= -fbootclasspath=/berman/fsf/_today_/berman/build/target/native/gcc/gcc-HEAD-as-2.15-ld-2.15/i686-pc-linux-gnu/libjava --encoding=UTF-8 -Wno-deprecated -g -O2 -c /berman/fsf/_today_/source/gcc/HEAD/gcc/libjava/java/lang/Class.java -o java/lang/Class.o
  /berman/fsf/_today_/source/gcc/HEAD/gcc/libjava/java/lang/Class.java: In class `java.lang.Class':
  /berman/fsf/_today_/source/gcc/HEAD/gcc/libjava/java/lang/Class.java: In method `java.lang.Class.internalGetFields()':
  /berman/fsf/_today_/source/gcc/HEAD/gcc/libjava/java/lang/Class.java:416: internal compiler error: Segmentation fault
  Please submit a full bug report,
  with preprocessed source if appropriate.
  See <URL:http://gcc.gnu.org/bugs.html> for instructions.
  make[2]: *** [java/lang/Class.lo] Error 1
  make[2]: Leaving directory `/berman/fsf/_today_/berman/build/target/native/gcc/gcc-HEAD-as-2.15-ld-2.15/i686-pc-linux-gnu/libjava'
  make[1]: *** [all-recursive] Error 1
  make[1]: Leaving directory `/berman/fsf/_today_/berman/build/target/native/gcc/gcc-HEAD-as-2.15-ld-2.15/i686-pc-linux-gnu/libjava'
  make: *** [all-target-libjava] Error 2

This worked on:

  :pserver:anoncvs:@gcc.gnu.org:/cvs/gcc
  2004-08-31 16:33:12 UTC

And it fails with:

  :pserver:anoncvs:@gcc.gnu.org:/cvs/gcc
  2004-09-05 22:32:35 UTC

Here is a stack trace:

  #0  0x08237e17 in fold_convert (type=0x0, arg=0x401e46d8)
      at /berman/fsf/_today_/source/gcc/HEAD/gcc/gcc/fold-const.c:1847
  #1  0x08176831 in add_standard_iv_candidates (data=0xbffff330)
      at /berman/fsf/_today_/source/gcc/HEAD/gcc/gcc/tree-ssa-loop-ivopts.c:1563
  #2  0x081773b4 in find_iv_candidates (data=0xbffff330)
      at /berman/fsf/_today_/source/gcc/HEAD/gcc/gcc/tree-ssa-loop-ivopts.c:1757
  #3  0x0817df43 in tree_ssa_iv_optimize_loop (data=0xbffff330, loop=0x8667200)
      at /berman/fsf/_today_/source/gcc/HEAD/gcc/gcc/tree-ssa-loop-ivopts.c:4336
  #4  0x0817e0cc in tree_ssa_iv_optimize (loops=0x8658350)
      at /berman/fsf/_today_/source/gcc/HEAD/gcc/gcc/tree-ssa-loop-ivopts.c:4395
  #5  0x08163d5b in tree_ssa_loop_ivopts ()
      at /berman/fsf/_today_/source/gcc/HEAD/gcc/gcc/tree-ssa-loop.c:267
  #6  0x080fd1f2 in execute_one_pass (pass=0x855bd40)
      at /berman/fsf/_today_/source/gcc/HEAD/gcc/gcc/tree-optimize.c:458

The problem is in add_standard_iv_candidates:

  static void
  add_standard_iv_candidates (struct ivopts_data *data)
  {
    /* Add 0 + 1 * iteration candidate.  */
    add_candidate (data,
		   fold_convert (unsigned_type_node, integer_zero_node),
		   fold_convert (unsigned_type_node, integer_one_node),
		   true, NULL);

    /* The same for a long type.  */
    add_candidate (data,
		   fold_convert (long_unsigned_type_node, integer_zero_node),
		   fold_convert (long_unsigned_type_node, integer_one_node),
		   true, NULL);
  }

unsigned_type_node equals zero when this function is called.
integer_types is initialized in language-specific code.  For java, this
code is java_init_decl_processing in java/decl.c.  unsigned_type_node is
not used by Java.  That causes the seg fault in fold_convert.

  /* tree.h */
  #define unsigned_type_node		integer_types[itk_unsigned_int]

  (gdb) print integer_types
  $21 = {0x401e7e80, 0x0, 0x0, 0x0, 0x0, 0x401e73a0, 0x0, 0x0, 0x0, 0x0, 0x0}

  (gdb) print global_trees
  $22 = {0x401e24c0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
  0x401e46c0, 0x401e46d8, 0x401e4720, 0x401e4810, 0x401e40d8, 0x401e4150,
  0x401e45a0, 0x401e4768, 0x401e4138, 0x0, 0x0, 0x0, 0x401e4888, 0x401e48a0,
  0x0, 0x0, 0x0, 0x0, 0x401f3414, 0x401f34fc, 0x0, 0x0, 0x0, 0x0, 0x0,
  0x401e7c3c, 0x401e7d24, 0x0, 0x401e7910, 0x0, 0x0, 0x0, 0x401e7f68, 0x0,
  0x401f59d8, 0x0}

I don't quite know the right way to fix this.  I can file all this info
with bugzilla if you want.

Michael Chastain
:q

             reply	other threads:[~2004-09-06 15:57 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-09-06 15:57 Michael Chastain [this message]
2004-09-06 16:02 ` Andreas Jaeger
2004-09-06 16:10 ` Steven Bosscher

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=413C88F4.nailLGW11O4SS@mindspring.com \
    --to=mec.gnu@mindspring.com \
    --cc=gcc@gcc.gnu.org \
    --cc=rakdver@atrey.karlin.mff.cuni.cz \
    /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).