[PATCH] D53044: [ELF] Don't warn on undefined symbols if UnresolvedPolicy::Ignore is used

Fangrui Song via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 10 12:11:25 PDT 2018


MaskRay added a comment.

After thinking it over, I decide to sink the `UnresolvedPolicy::Ignore` condition to `elf::warnUnorderedSymbol` to suppress warnings from both 1) `--symbol-ordering-file=` and 2) `.llvm.call-graph-profile`

The test `symbol-ordering-file-warnings.s` uses `--unresolved-symbols=ignore-all` to check warnings of`Sym->isUndefined()`. But I think it makes more sense to just don't warn the unordered symbol case, as the `error: undefined symbol: $symbol` error/warning is also suppressed. If the symbol does not exist, users will still see `warning: symbol ordering file: no such symbol: $symbol`. This change does not make the status worse.


Repository:
  rLLD LLVM Linker

https://reviews.llvm.org/D53044





More information about the llvm-commits mailing list