Skip to content

Commit

Permalink
[ARM] Make empty name symbols SF_FormatSpecific to try appeasing --ta…
Browse files Browse the repository at this point in the history
…rget=armv7-linux-androideabi24 sanitizer symbolization tests

This is similar to D98669 but I don't know whether and why ARM needs it.

I suspect this may fix the sanitizer-x86_64-linux-android bot which runs
--target=armv7-linux-androideabi24 tests
(https://lab.llvm.org/buildbot/#/builders/77)

Someone needs to investigate the root cause and I am not sure this hack
fixes the bot.
  • Loading branch information
MaskRay committed Nov 3, 2021
1 parent f2e8077 commit 2faac77
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion llvm/include/llvm/Object/ELFObjectFile.h
Expand Up @@ -733,7 +733,8 @@ Expected<uint32_t> ELFObjectFile<ELFT>::getSymbolFlags(DataRefImpl Sym) const {
} else if (EF.getHeader().e_machine == ELF::EM_ARM) {
if (Expected<StringRef> NameOrErr = getSymbolName(Sym)) {
StringRef Name = *NameOrErr;
if (Name.startswith("$d") || Name.startswith("$t") ||
// TODO Investigate why empty name symbols need to be marked.
if (Name.empty() || Name.startswith("$d") || Name.startswith("$t") ||
Name.startswith("$a"))
Result |= SymbolRef::SF_FormatSpecific;
} else {
Expand Down

0 comments on commit 2faac77

Please sign in to comment.