This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH, libgcc]: Avoid warning: array subscript is above array bounds when compiling crtstuff.c
- From: Jakub Jelinek <jakub at redhat dot com>
- To: Ian Lance Taylor <iant at google dot com>
- Cc: Uros Bizjak <ubizjak at gmail dot com>, "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>
- Date: Mon, 10 Mar 2014 18:54:58 +0100
- Subject: Re: [PATCH, libgcc]: Avoid warning: array subscript is above array bounds when compiling crtstuff.c
- Authentication-results: sourceware.org; auth=none
- References: <CAFULd4Y6p0kCyyE3nEnOFTmWhv785++E4dOh=HWZfX+sjFKkCQ at mail dot gmail dot com> <CAKOQZ8y9KVPSKt+MjrL-YVoq+ZJr93ag7T=E-ZJorKPJ=HYu1g at mail dot gmail dot com> <20140309173142 dot GP22862 at tucnak dot redhat dot com> <CAFULd4apzqyXy+t8uGt=rwR+rQGYxrVDY+-UVWc+wa-3iw3fcw at mail dot gmail dot com> <20140310074932 dot GQ22862 at tucnak dot redhat dot com> <CAFULd4a+pxpUGT8EPv0ZjRO2CROPGiRJ53LM1pFdvtc1h98nBw at mail dot gmail dot com> <20140310101419 dot GS22862 at tucnak dot redhat dot com> <CAFULd4Y4Fyc7=sp8KoifHYRf1Q8WLQOH1vey8fDMGhHZZp04wA at mail dot gmail dot com> <CAFULd4YJqWYkEJjhE0aQOGHzAV496j44qkqy6wtDBvzoXGWLiQ at mail dot gmail dot com> <CAKOQZ8zFvXaTh5vAhjB7dZKmftyh-BwWj7tgkZm+NkEdyS8p1g at mail dot gmail dot com>
- Reply-to: Jakub Jelinek <jakub at redhat dot com>
On Mon, Mar 10, 2014 at 10:53:27AM -0700, Ian Lance Taylor wrote:
> On Mon, Mar 10, 2014 at 10:42 AM, Uros Bizjak <ubizjak@gmail.com> wrote:
> >
> > Attached patch is what I plan to commit to mainline soon. Ian, does it
> > look OK to you?
> >
> > 2014-03-10 Uros Bizjak <ubizjak@gmail.com>
> >
> > * crtstuff.c (frame_dummy): Use void **jcr_list temporary
> > variable to avoid array subscript is above array bounds warnings.
> > Use __builtin_expect when checking *jcr_list for NULL.
>
> This looks OK to me. Thanks.
>
> > Jakub, is it OK for mainline from RMs POV? Shall we backport this
> > patch to other release branches?
>
> I gather that the purpose of this patch is to avoid a warning. I
> don't see a reason to backport this to working release branches.
Yeah. Unless we are aware of miscompilation on some target, I think it
shouldn't be backported.
Jakub
- References:
- Re: [PATCH, libgcc]: Avoid warning: array subscript is above array bounds when compiling crtstuff.c
- Re: [PATCH, libgcc]: Avoid warning: array subscript is above array bounds when compiling crtstuff.c
- Re: [PATCH, libgcc]: Avoid warning: array subscript is above array bounds when compiling crtstuff.c
- Re: [PATCH, libgcc]: Avoid warning: array subscript is above array bounds when compiling crtstuff.c
- Re: [PATCH, libgcc]: Avoid warning: array subscript is above array bounds when compiling crtstuff.c
- Re: [PATCH, libgcc]: Avoid warning: array subscript is above array bounds when compiling crtstuff.c
- Re: [PATCH, libgcc]: Avoid warning: array subscript is above array bounds when compiling crtstuff.c
- Re: [PATCH, libgcc]: Avoid warning: array subscript is above array bounds when compiling crtstuff.c
- Re: [PATCH, libgcc]: Avoid warning: array subscript is above array bounds when compiling crtstuff.c
- Re: [PATCH, libgcc]: Avoid warning: array subscript is above array bounds when compiling crtstuff.c