[PATCH] D38489: TargetMachine: Merge TargetMachine and LLVMTargetMachine

Chandler Carruth via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Oct 12 18:23:03 PDT 2017


chandlerc added a comment.

In https://reviews.llvm.org/D38489#896516, @MatzeB wrote:

> Turns out this doesn't work nice with the current layering. There are some tools that just link libTarget but not libCodeGen. Merging LLVMTargetMachine and TargetMachine however forces us to move TargetMachine into libCodeGen breaking such users.
>
> I think when merging LLVMTargetMachine and TargetMachine we also have to be consequent and merge libTarget into libCodeGen to facilitate that. Not sure how people think about that, and I'm not sure I will find the time to prepare patches for all llvm users linking to libTarget.


FWIW, I think this too would be an improvement. I find the linking of Target vs CodeGen pretty deeply confusing already. But my guess is this would indeed require a bit more work so that layers of the target which really don't require a code generator (and shouldn't) like MC bits can avoid linking with it.


Repository:
  rL LLVM

https://reviews.llvm.org/D38489





More information about the llvm-commits mailing list