This is the mail archive of the gcc-patches@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: [LTO] Fix C++ thunks


On Mon, Dec 29, 2008 at 9:57 PM, Jason Merrill <jason@redhat.com> wrote:
> Rafael Espindola wrote:
>>>
>>> But you can simply inline the trunked function in this case.
>>
>> Might be a bit expensive if there are a lot of thunks that call the
>> same function
>
> Quite.  It wouldn't be a thunk at all in that case, it would be a clone.
> The whole point of thunks is to avoid duplicating the virtual function for a
> simple pointer adjustment.

Still better than not supporting the varargs case at all ;)  OTOH - why don't we
use thunks for the "real" clones?  I suppose because of possible optimizations?

Richard.

> Jason
>


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