This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/20625] [4.0/4.1 regression] ivopts produces code that generates "unaligned access exception"
- From: "rakdver at atrey dot karlin dot mff dot cuni dot cz" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 29 Mar 2005 20:47:33 -0000
- Subject: [Bug target/20625] [4.0/4.1 regression] ivopts produces code that generates "unaligned access exception"
- References: <20050324165328.20625.tsv@solvo.ru>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From rakdver at atrey dot karlin dot mff dot cuni dot cz 2005-03-29 20:47 -------
Subject: Re: [4.0/4.1 regression] ivopts produces code that generates "unaligned access exception"
> This most likely can be reproduced on ia64 too and other targets where alignment is needed for some
> loads.
>
> The tree which we produce looks like:
> <bb 0>:
> if (p->c[0] != 0) goto <L0>; else goto <L2>;
>
> <L0>:;
> D.1133 = *((unsigned char *) p + 5B);
> p = p + 1B;
> if (D.1133 != 0) goto <L0>; else goto <L2>;
The problem seems to be that the expansion assumes that p must be
aligned. Which seems to be reasonable. I will try making ivopts
produce all pointer ivs in (void *) type, that should hopefully
help.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20625