| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
[lld] Add (ignored) /link flag to lld-link for compatibility with MSVC link.exe (#168364) Various build tools may produce command lines invoking clang-cl and lld-link which contain /link twice like so: e.g. clang-cl.exe sanitycheckcpp.cc /Fesanitycheckcpp.exe .... /link /link ... If link.exe is used, it ignores the extra /link and just issues a warning, however lld-link tries to treat /link as a file name. This PR adds a flag which is ignored in order to improve compatibility with link.exe There's some extra context including an "in-the-wild" example and reproducer of the problem here: https://github.com/frankier/meson_clang_win_activation Co-authored-by: Frankie Robertson <frankie@robertson.name> | 8 个月前 | |
ELF: Use index 0 for unversioned undefined symbols (#168189) The GNU documentation is ambiguous about the version index for unversioned undefined symbols. The current specification at https://sourceware.org/gnu-gabi/program-loading-and-dynamic-linking.txt defines VER_NDX_LOCAL (0) as "The symbol is private, and is not available outside this object." However, this naming is misleading for undefined symbols. As suggested in discussions, VER_NDX_LOCAL should conceptually be VER_NDX_NONE and apply to unversioned undefined symbols as well. GNU ld has used index 0 for unversioned undefined symbols both before version 2.35 (see https://sourceware.org/PR26002) and in the upcoming 2.46 release (see https://sourceware.org/PR33577). This change aligns with GNU ld's behavior by switching from index 1 to index 0. While here, add a test to dso-undef-extract-lazy.s that undefined symbols of index 0 in DSO are treated as unversioned symbols. | 8 个月前 | |
[lld:MachO] Allow independent override of weak symbols aliased via .set (#167825) Currently, if multiple external weak symbols are defined at the same address in an object file (e.g., by using the .set assembler directive to alias them to a single weak variable), ld64.lld treats them as a single unit. When any one of these symbols is overridden by a strong definition, all of the original weak symbols resolve to the strong definition. This patch changes the behavior in transplantSymbolsAtOffset. When a weak symbol is being replaced by a strong one, only non-external (local) symbols at the same offset are moved to the new symbol's section. Other *external* symbols are no longer transplanted. This allows each external weak symbol to be overridden independently. This behavior is consistent with Apple's ld-classic, but diverges from ld-prime in one case, as noted on https://github.com/llvm/llvm-project/issues/167262 (this discrepancy has recently been reported to Apple). ### Backward Compatibility This change alters linker behavior for a specific scenario. The creation of multiple external weak symbols aliased to the same address via assembler directives is primarily an advanced technique. It's unlikely that existing builds rely on the current behavior of all aliases being overridden together. If there are concerns, this could be put behind a linker option, but the new default seems more correct, less surprising, and is consistent with ld-classic. ### Testing The new lit test test/MachO/weak-alias-override.s verifies this behavior using llvm-nm. Fixes #167262 | 8 个月前 | |
[LLD][MinGW] Handle MIPS machine (#157742) | 8 个月前 | |
Revert "[lit] cleanup unused imports" (#144054) Reverts llvm/llvm-project#143930 as it causes build failures: https://github.com/llvm/llvm-project/pull/143930#issuecomment-2969115461 | 1 年前 | |
| 8 个月前 | ||
[lld] Reject --read-workers when lld is built without thread support (#163925) Also expand the #ifdef to remove unused code in this configuration. As suggested in https://github.com/llvm/llvm-project/pull/147134#issuecomment-3328612158. I have also: * Expanded the error message to explain why it's not allowed. * Added a test for the error. * Marked the original test as unsupported when threads are disabled. Fixes issues we have had on Armv8 with threading disabled where this test would crash every so often. This change will hopefully be superseded by #157917, but that has been in review a long time and I want to make the bot stable again. I could just disable the test, but I'd like lld to function properly in general in the meantime too. Co-authored-by: John Holdsworth <github@johnholdsworth.com> | 9 个月前 | |
[lld] Reject --read-workers when lld is built without thread support (#163925) Also expand the #ifdef to remove unused code in this configuration. As suggested in https://github.com/llvm/llvm-project/pull/147134#issuecomment-3328612158. I have also: * Expanded the error message to explain why it's not allowed. * Added a test for the error. * Marked the original test as unsupported when threads are disabled. Fixes issues we have had on Armv8 with threading disabled where this test would crash every so often. This change will hopefully be superseded by #157917, but that has been in review a long time and I want to make the bot stable again. I could just disable the test, but I'd like lld to function properly in general in the meantime too. Co-authored-by: John Holdsworth <github@johnholdsworth.com> | 9 个月前 | |
[lld] Reject --read-workers when lld is built without thread support (#163925) Also expand the #ifdef to remove unused code in this configuration. As suggested in https://github.com/llvm/llvm-project/pull/147134#issuecomment-3328612158. I have also: * Expanded the error message to explain why it's not allowed. * Added a test for the error. * Marked the original test as unsupported when threads are disabled. Fixes issues we have had on Armv8 with threading disabled where this test would crash every so often. This change will hopefully be superseded by #157917, but that has been in review a long time and I want to make the bot stable again. I could just disable the test, but I'd like lld to function properly in general in the meantime too. Co-authored-by: John Holdsworth <github@johnholdsworth.com> | 9 个月前 |
| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
| 8 个月前 | ||
| 8 个月前 | ||
| 8 个月前 | ||
| 8 个月前 | ||
| 1 年前 | ||
| 8 个月前 | ||
| 9 个月前 | ||
| 9 个月前 | ||
| 9 个月前 |