This patch adds initial support for the hexagon architecture. It will handle the requirements needed to link the Linux kernel.
Diff Detail
- Repository
- rLLD LLVM Linker
Event Timeline
Hi Sid,
Thank you for working on this! However, I'm not very happy to see a single large patch that adds large amount of code at once. It looks like the test doesn't test all the features and relocations you added in this patch, and it looks like the code is written in a pretty different way than those for other targets. It needs to be updated so that it is written in the same style as others. Discussing based on this large patch is perhaps not desirable.
What I'd like to see as a starter is the code that can only link an empty program that doesn't do anything. Could you reduce this patch to that absolute minimal one? After that we can start discussing details.
The two large files, HexagonDepMask and HexagonRelocationInfo could live in llvm/lib/Target/Hexagon. I was kind of on the fence about the location, but since they would only be used by the linker in the public tree I put them with lld.
I can truncate the number of supported relocations to those required for basic static linking.
I can truncate the number of supported relocations to those required for basic static linking.
Please do. In addition to truncating the code, please rewrite code to fill the discrepancies between your code and other files in the same directory. We generally do not define a large table like that, for example.
Also please pay attention to coding style. E.g. trailing empty lines, C/C++-style comment discrepancy, etc.