This is the mail archive of the 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: [PATCH] Fix DCE REG_LIBCALL note moving from noop move insns (PR rtl-optimization/33644)

On 10/19/07, Richard Kenner <> wrote:
> > Things like a multiplication can be CSE-ed in tree-ssa, so there
> > should not be any libcalls of this kind to CSE in the generated RTL.
> >
> > But TLS addressing is not exposed in GIMPLE so you can't CSE the TLS
> > addresses either.
> That's true, but we aren't depending *just* on cse'ing stuff at the tree
> level, are we?  We do cse multiplication libcalls at the RTL level and that
> same approach should work for TLS libcalls.


I thought you were referring to my remark that we supposedly only need
libcalls for TLS address calls, but IIUC you in fact reacted to my
remark whether CSE of TLS libcalls actually works, right?

Anyway, yes, if you have libcall notes, then CSE of TLS libcalls should work.

> > Compile with -fpic.  There should only be one call to __tls_get_addr
> > to get a base address.  Without libcalls there will be two calls.  The
> > base address is not exposed in tree-ssa.
> But isn't the function marked const?  (Is that the right flag?)

__tls_get_addr is not const, and not pure either.


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