This is the mail archive of the
java-patches@gcc.gnu.org
mailing list for the Java project.
Re: Java: Local function pointer aliases for method metadata
- From: Richard Henderson <rth at redhat dot com>
- To: Bryce McKinlay <mckinlay at redhat dot com>
- Cc: java-patches at gcc dot gnu dot org, gcc-patches at gcc dot gnu dot org
- Date: Wed, 18 Aug 2004 01:48:12 -0700
- Subject: Re: Java: Local function pointer aliases for method metadata
- References: <4122B238.30508@redhat.com>
On Tue, Aug 17, 2004 at 09:34:48PM -0400, Bryce McKinlay wrote:
> + const char *alias_id = "LALIAS_";
> + int name_len;
> +
> + /* Make the alias name by prepending alias_id. */
> + name_len = IDENTIFIER_LENGTH (DECL_ASSEMBLER_NAME (method));
> + ptr = buf = alloca (strlen (alias_id) + name_len + 1);
> + strcpy (ptr, alias_id);
> + ptr += strlen (alias_id);
> + strcpy (ptr, IDENTIFIER_POINTER (DECL_ASSEMBLER_NAME (method)));
> + ptr += name_len;
> + *ptr = '\0';
You want to use ASM_GENERATE_INTERNAL_LABEL so that the symbol
is of a form that is interpreted by the assembler as a temporary.
This way the symbol isn't retained in the .o file, or copied to
the executable.
This isn't actively wrong, but you can save a bit o space.
r~