This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: GCC build failed for native with your patch on 2001-11-30T04:44:42Z.
- From: Bryce McKinlay <bryce at waitaki dot otago dot ac dot nz>
- To: gcc-patches at gcc dot gnu dot org
- Cc: aldyh at redhat dot com, hzoli at hzoli dot 2y dot net, jason at redhat dot com, mark at codesourcery dot com, zack at codesourcery dot com
- Date: Fri, 30 Nov 2001 22:53:17 +1300
- Subject: Re: GCC build failed for native with your patch on 2001-11-30T04:44:42Z.
- References: <200111300724.fAU7OIe31713@maat.cygnus.com>
GCC regression checker wrote:
>With your recent patch, GCC does not compile on:
> native
>Attached is build output for those targets.
>
>The build failures are new.
>
>/maat/heart/tbox/native/build/gcc/gcj -B/maat/heart/tbox/native/build/i686-pc-linux-gnu/libjava/ -B/maat/heart/tbox/native/build/gcc/ --encoding=UTF-8 -fassume-compiled -fclasspath=/maat/heart/tbox/native/build/i686-pc-linux-gnu/libjava -L/maat/heart/tbox/native/build/i686-pc-linux-gnu/libjava -ffloat-store -g -O2 -MD -MT java/lang/Boolean.lo -MF java/lang/Boolean.d -c /maat/heart/tbox/cvs-gcc/gcc/libjava/java/lang/Boolean.java -fPIC -o java/lang/.libs/Boolean.o
>/maat/heart/tbox/cvs-gcc/gcc/libjava/java/lang/Boolean.java:1: Internal error: Segmentation fault
>
This was caused by the dbxout.c change. GCJ sets TREE_VIA_VIRTUAL for
interfaces but did not set BINFO_VPTR_FIELD. Although Java interfaces
are not the same as C++ virtual bases, it is probibly desirable to set
TREE_VIA_VIRTUAL just to distinguish them from superclasses in the
debugging output. So, I'm checking in this patch as obvious.
regards
Bryce.
2001-11-30 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
* class.c (add_interface_do): Set BINFO_VPTR_FIELD.
Index: class.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/java/class.c,v
retrieving revision 1.115
diff -u -r1.115 class.c
--- class.c 2001/09/21 16:58:21 1.115
+++ class.c 2001/11/30 09:23:16
@@ -541,6 +541,7 @@
tree interface_binfo = make_tree_vec (6);
BINFO_TYPE (interface_binfo) = interface_class;
BINFO_OFFSET (interface_binfo) = integer_zero_node;
+ BINFO_VPTR_FIELD (interface_binfo) = integer_zero_node;
TREE_VIA_VIRTUAL (interface_binfo) = 1;
TREE_VIA_PUBLIC (interface_binfo) = 1;
TREE_VEC_ELT (basetype_vec, i) = interface_binfo;