[LLVMdev] Can we establish layering for the LLD libraries? Current state is a bit of a mess...

Nick Kledzik kledzik at apple.com
Tue Jan 20 18:53:14 PST 2015


On Jan 20, 2015, at 6:37 PM, Rui Ueyama <ruiu at google.com> wrote:

> If my understanding is correct, the dependencies dependencies between components in LLD should be like this:
> 
> Config: (nothing)
> Core: Config
> Driver: Core Passes ReaderWriter
> Passes: Core ReaderWriter
> ReaderWriter: Core (and Driver?)
> 
> I don't want ReaderWriter to depend on Driver, but it may be unavoidable because of .drectve section in PE/COFF which contains command line options.
> 
> Well, it *can't* depend on Driver if Driver depends on ReaderWriter.
> 
> Oh that's true. Then the only thing we can do is to combine Driver and ReaderWriter to make it one library? It's far from ideal and feels wrong though.

Can we finesse this by having the WinLinkDriver register a “parse” function pointer with PECOFFLinkingContext.  Then have FileCOFF just call the registered parse function in the PECOFFLinkingContext?  

-Nick


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20150120/20b8eabf/attachment.html>


More information about the llvm-dev mailing list