This is the mail archive of the
java-discuss@sources.redhat.com
mailing list for the Java project.
Re: New C++ ABI: patches.
- To: Alexandre Petit-Bianco <apbianco at cygnus dot com>
- Subject: Re: New C++ ABI: patches.
- From: Jeff Sturm <jsturm at detroit dot appnet dot com>
- Date: Sun, 7 Jan 2001 23:35:11 -0500 (EST)
- cc: java-discuss at sources dot redhat dot com, gcc-patches at gcc dot gnu dot org
On Sun, 7 Jan 2001, Alexandre Petit-Bianco wrote:
> This is a first trial at the new C++ ABI, in three patches.
Great! Just a few questions:
> + // required by prims.cc:init_prim_class(), and the prototype of
> + // method to perform a lightweight initialization of a Class object.
> + Class (void) {}
> + Class (const Class& x) : Object () {
> + _Jv_VTable *avtable = x.vtable;
> +
> + name = x.name;
> + accflags = x.accflags;
> + method_count = x.method_count;
> + size_in_bytes = x.size_in_bytes;
> + vtable = x.vtable;
> + vtable = JV_PRIMITIVE_VTABLE;
Is the first vtable assignment bogus?
> -inline jboolean
> +jboolean
> java::lang::Class::isAssignableFrom (jclass klass)
> {
> // Arguments may not have been initialized, given ".class" syntax.
Why not inline? (You didn't mention isAssignableFrom in the
ChangeLog.)
> Index: jvgenmain.c
> ===================================================================
> RCS file: /cvs/gcc/gcc/gcc/java/jvgenmain.c,v
> retrieving revision 1.18
> diff -u -p -r1.18 jvgenmain.c
> --- jvgenmain.c 2000/12/08 03:00:26 1.18
> +++ jvgenmain.c 2001/01/07 15:24:14
[...]
> @@ -156,11 +154,11 @@ main (int argc, const char **argv)
> fprintf (stream, " 0\n};\n\n");
>
> #ifndef NO_DOLLAR_IN_LABEL
> - fprintf (stream, "extern int class __attribute__ ((alias (\"_%s$%s\")));\n",
> - mangled_classname, class_mangling_suffix);
> + fprintf (stream, "extern int class __attribute__ ((alias (\"%s\")));\n",
> + mangled_classname);
> #else
> - fprintf (stream, "extern int class __attribute__ ((alias (\"_%s.%s\")));\n",
> - mangled_classname, class_mangling_suffix);
> + fprintf (stream, "extern int class __attribute__ ((alias (\"%s\")));\n",
> + mangled_classname);
> #endif
Looks like this #ifndef block should just go away? (I never liked that
NO_DOLLAR_IN_LABEL business anyway... it seemed necessary to compile for
BSD.)
Jeff