This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: libgcc: strange optimization


On Tue, Aug 2, 2011 at 10:48 AM, Mikael Pettersson <mikpe@it.uu.se> wrote:
> Hans-Peter Nilsson writes:
> ?> On Mon, 1 Aug 2011, Richard Henderson wrote:
> ?>
> ?> > On 08/01/2011 01:30 PM, Michael Walle wrote:
> ?> > > ?1) function inlining
> ?> > > ?2) deferred argument evaluation
> ?> > > ?3) because our target has no barrel shifter, (arg >> 10) is emitted as a
> ?> > > function call to libgcc's __ashrsi3 (_in place_!)
> ?> > > ?4) BAM! dead code elimination optimizes r8 assignment away because calli
> ?> > > may clobber r1-r10 (callee saved registers on lm32).
> ?> >
> ?> > I'm afraid the only solution I can think of is to force F1 out-of-line.
> ?>
> ?> Or another temporary - but the parameter should already have
> ?> that effect.
>
> It should, but doesn't. ?See PR48863 for similar breakage on ARM.

On GIMPLE we don't see either the libcall nor those "dependencies".

Don't use register vars.

Richard.

> /Mikael
>


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]