diff options
author | Bill Wendling <isanbard@gmail.com> | 2019-08-09 20:18:30 +0000 |
---|---|---|
committer | Bill Wendling <isanbard@gmail.com> | 2019-08-09 20:18:30 +0000 |
commit | 79176a2542d03107b90613c84f18ccba41ad8fa8 (patch) | |
tree | 59549b071f8e5754906a80005bc24c399c05799a /llvm/lib/CodeGen/MachineModuleInfo.cpp | |
parent | 1b104388752f66191c867380efde7bbf1f13ca80 (diff) | |
download | bcm5719-llvm-79176a2542d03107b90613c84f18ccba41ad8fa8.tar.gz bcm5719-llvm-79176a2542d03107b90613c84f18ccba41ad8fa8.zip |
[CodeGen] Require a name for a block addr target
Summary:
A block address may be used in inline assembly. In which case it
requires a name so that the asm parser has something to parse. Creating
a name for every block address is a large hammer, but is necessary
because at the point when a temp symbol is created we don't necessarily
know if it's used in inline asm. This ensures that it exists regardless.
Reviewers: nickdesaulniers, craig.topper
Subscribers: nathanchance, javed.absar, llvm-commits
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D65352
llvm-svn: 368478
Diffstat (limited to 'llvm/lib/CodeGen/MachineModuleInfo.cpp')
-rw-r--r-- | llvm/lib/CodeGen/MachineModuleInfo.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/MachineModuleInfo.cpp b/llvm/lib/CodeGen/MachineModuleInfo.cpp index 6ac9d3dfc2e..3dca5a619bc 100644 --- a/llvm/lib/CodeGen/MachineModuleInfo.cpp +++ b/llvm/lib/CodeGen/MachineModuleInfo.cpp @@ -121,7 +121,7 @@ ArrayRef<MCSymbol *> MMIAddrLabelMap::getAddrLabelSymbolToEmit(BasicBlock *BB) { BBCallbacks.back().setMap(this); Entry.Index = BBCallbacks.size() - 1; Entry.Fn = BB->getParent(); - Entry.Symbols.push_back(Context.createTempSymbol()); + Entry.Symbols.push_back(Context.createTempSymbol(!BB->hasAddressTaken())); return Entry.Symbols; } |