From mboxrd@z Thu Jan 1 00:00:00 1970 From: jsperri@gmx.net To: gcc-gnats@gcc.gnu.org Subject: java/4510: Compiler seg fault on '(String) ((long) d + "d")' Date: Tue, 09 Oct 2001 00:26:00 -0000 Message-id: <20011009071646.7675.qmail@sourceware.cygnus.com> X-SW-Source: 2001-10/msg00171.html List-Id: >Number: 4510 >Category: java >Synopsis: Compiler seg fault on '(String) ((long) d + "d")' >Confidential: no >Severity: serious >Priority: medium >Responsible: unassigned >State: open >Class: sw-bug >Submitter-Id: net >Arrival-Date: Tue Oct 09 00:26:00 PDT 2001 >Closed-Date: >Last-Modified: >Originator: jsperri@gmx.net >Release: gcc-3.0.1 >Organization: >Environment: gcc version 3.0.1 - Thread model: posix built with ../gcc-3.0.1/configure --enable-threads=posix on Linux Mandrake 8.0-x86 >Description: The attached piece of code generates a segfault when compiled with gcj 3.0.1. Compiler flags used: gcj -v --main=HelloWorld HelloWorld.java --classpath=/usr /local/share/libgcj.jar -o Hello Compiler output: Reading specs from /usr/local/lib/gcc-lib/i686-pc-linux-gnu/3.0.1/specs Reading specs from /usr/local/lib/gcc-lib/i686-pc-linux-gnu/3.0.1/../../../libgc j.spec rename spec lib to liborig rename spec startfile to startfileorig Configured with: ../gcc-3.0.1/configure --enable-threads=posix Thread model: posix gcc version 3.0.1 /usr/local/lib/gcc-lib/i686-pc-linux-gnu/3.0.1/jc1 HelloWorld.java -fuse-divide -subroutine -fuse-boehm-gc -fnon-call-exceptions -quiet -dumpbase HelloWorld.jav a -g1 -version -fclasspath=/usr/local/share/libgcj.jar -o /tmp/ccI7ZYnk.s GNU Java version 3.0.1 (i686-pc-linux-gnu) compiled by GNU C version 3.0.1. HelloWorld.java: In class `HelloWorld': HelloWorld.java: In method `HelloWorld.main(java.lang.String[])': HelloWorld.java:6: Internal error: Segmentation fault Please submit a full bug report, with preprocessed source if appropriate. See for instructions. >How-To-Repeat: Just compile HelloWorld class. GCJ should core with: HelloWorld.java: In class `HelloWorld': HelloWorld.java: In method `HelloWorld.main(java.lang.String[])': HelloWorld.java:6: Internal error: Segmentation fault >Fix: >Release-Note: >Audit-Trail: >Unformatted: ----gnatsweb-attachment---- Content-Type: text/plain; name="HelloWorld.java" Content-Disposition: inline; filename="HelloWorld.java" public class HelloWorld { public static void main (String []args) { double d=1.0; System.out.println ((String) ((long) d + "d")); } }