This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [patch] Fix a segfault in h8300 port.
- To: Kazu Hirata <kazu at hxi dot com>
- Subject: Re: [patch] Fix a segfault in h8300 port.
- From: law at redhat dot com
- Date: Tue, 30 Oct 2001 07:21:35 -0700
- cc: gcc-patches at gcc dot gnu dot org
- Reply-To: law at redhat dot com
In message <200110292352.PAA07006@cygnus.com>you write:
> Hi,
>
> Attached is a patch to fix the cause of a segfault in h8300 port.
>
> Specifically, with the patch applied, gcc handles the following
> correctly.
>
> char tiny __attribute__ ((tiny_data)) = 0;
>
> char
> foo (void)
> {
> return tiny;
> }
>
> Tested on h8300 port. OK to apply to both branches?
>
> Kazu Hirata
>
> 2001-10-29 Kazu Hirata <kazu@hxi.com>
>
> * config/h8300/h8300.c (h8300_encode_label): Compute a string
> before passing it to ggc_alloc_string.
Err, why do you need to compute the new string before passing it to
ggc_alloc_string.
Wouldn't fixing the length of the desired string passed to ggc_alloc_string
fix this problem?
jeff