On Wed, Dec 15, 2010 at 5:23 PM, Ian Lance Taylor <i...@google.com> wrote:
> On Thu, Dec 9, 2010 at 6:29 PM, H.J. Lu <hjl.to...@gmail.com> wrote:
>
>> The initial implementation of my proposal is available on hjl/lto-mixed
>> branch at
>>
>> http://git.kernel.org/?p=devel/binutils/hjl/x86.git;a=summary
>
> I don't know how to separate this idea from the other work on that branch.

It is implemented on top of 2 stage linking infrastructure.

> I'm concerned that this idea appears to deeply embeds knowledge about
> LTO into the linker
> proper.  One of the goals of the plugin approach was to have a clean
> separation, to give us
> more flexibility going forward.  I say "appears to" because I'm not
> sure I entirely understand
> the proposal.  The text is rather sketchy and I haven't seen the patch.

If you have specific questions, please just ask.

> For example, I think it would be a mistake for the linker to know the
> magic names that
> we currently use for LTO sections, and it would definitely be a
> mistake for the linker to
> know anything about the format of the data they contain.

Linker knows nothing about the magic names.

* Linker action:
  o Classify each input object file:
    * If there is a ".gnu_object_only" section, it is a mixed object file.
    * If there is a IR section, it is an IR object file.

Linker checks if an object is claimed by the plugin. If yes,
it has an IR section.  Otherwise, it has no IR.

    * Otherwise, it is a non-IR object file.



-- 
H.J.

Reply via email to