This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: Serious code size regression from 3.0.2 to now
- From: tm <tm at mail dot kloo dot net>
- To: Geoff Keating <geoffk at redhat dot com>
- Cc: joern dot rennecke at superh dot com, gcc-bugs at gcc dot gnu dot org,stephen dot clarke at superh dot com, shumpei dot kawasaki at hsa dot hitachi dot com
- Date: Tue, 23 Jul 2002 17:50:05 -0700 (PDT)
- Subject: Re: Serious code size regression from 3.0.2 to now
On Tue, 23 Jul 2002, Geoff Keating wrote:
> > Date: Tue, 23 Jul 2002 16:22:18 -0700 (PDT)
> > From: tm <tm@mail.kloo.net>
> > Cc: Joern Rennecke <joern.rennecke@superh.com>, gcc-bugs@gcc.gnu.org,
> > stephen.clarke@superh.com, shumpei.kawasaki@hsa.hitachi.com, tm@kloo.net
>
> > On 23 Jul 2002, Geoff Keating wrote:
...
>
> > 2) Suppress cache alignment for BBRO-generated blocks
>
> That would also be bad.
>
Why?
The SH4 has critical-word-read-first.
Let's say a BBRO-generated out-of-lined code fragment is 3 instructions or
6 bytes. If it's cache-aligned, it reads one cache line and fetches the
first instruction immediately.
If it's not cache-aligned but starts in the first 27 bytes of a cache
line, e.g. ((address & 31) < 27), then it reads one cache line and still
fetches the first instruction immediately due to critical-word-read-first.
Toshi