llvm/lib/CodeGen/AsmPrinter
Peter Collingbourne 5f220beefc DI: Reverse direction of subprogram -> function edge.
Previously, subprograms contained a metadata reference to the function they
described. Because most clients need to get or set a subprogram for a given
function rather than the other way around, this created unneeded inefficiency.

For example, many passes needed to call the function llvm::makeSubprogramMap()
to build a mapping from functions to subprograms, and the IR linker needed to
fix up function references in a way that caused quadratic complexity in the IR
linking phase of LTO.

This change reverses the direction of the edge by storing the subprogram as
function-level metadata and removing DISubprogram's function field.

Since this is an IR change, a bitcode upgrade has been provided.

Fixes PR23367. An upgrade script for textual IR for out-of-tree clients is
attached to the PR.

Differential Revision: http://reviews.llvm.org/D14265

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@252219 91177308-0d34-0410-b5e6-96231b3b80d8
2015-11-05 22:03:56 +00:00
..
AddressPool.cpp
AddressPool.h
ARMException.cpp [EH] Handle non-Function personalities like unknown personalities 2015-08-31 20:02:16 +00:00
AsmPrinter.cpp Delete dead code. 2015-11-03 18:55:58 +00:00
AsmPrinterDwarf.cpp [X86] Generate .cfi_adjust_cfa_offset correctly when pushing arguments 2015-11-03 08:17:25 +00:00
AsmPrinterHandler.h [WinEH] Teach AsmPrinter about funclets 2015-09-29 20:12:33 +00:00
AsmPrinterInlineAsm.cpp
ByteStreamer.h
CMakeLists.txt
DbgValueHistoryCalculator.cpp
DbgValueHistoryCalculator.h
DebugLocEntry.h Replace a forward declaration with an #include. 2015-10-15 20:58:55 +00:00
DebugLocStream.cpp
DebugLocStream.h
DIE.cpp
DIEHash.cpp [AsmPrinter] Prune dead code. NFC. 2015-10-15 17:16:32 +00:00
DIEHash.h [AsmPrinter] Prune dead code. NFC. 2015-10-15 17:16:32 +00:00
DwarfAccelTable.cpp Fix some Clang-tidy modernize warnings, other minor fixes. 2015-11-04 22:32:32 +00:00
DwarfAccelTable.h
DwarfCFIException.cpp [EH] Handle non-Function personalities like unknown personalities 2015-08-31 20:02:16 +00:00
DwarfCompileUnit.cpp Fix indents. It's a follow up to r251353. 2015-10-26 22:35:40 +00:00
DwarfCompileUnit.h Move imported entities into DwarfCompilationUnit to speed up LTO linking. 2015-10-26 21:36:35 +00:00
DwarfDebug.cpp DI: Reverse direction of subprogram -> function edge. 2015-11-05 22:03:56 +00:00
DwarfDebug.h Move imported entities into DwarfCompilationUnit to speed up LTO linking. 2015-10-26 21:36:35 +00:00
DwarfException.h
DwarfExpression.cpp Fix debug info with SafeStack. 2015-09-30 19:55:43 +00:00
DwarfExpression.h
DwarfFile.cpp
DwarfFile.h
DwarfStringPool.cpp
DwarfStringPool.h
DwarfUnit.cpp DebugInfo: Include the decl_line/decl_file in subprogram definitions if they differ from those in the declaration 2015-10-07 00:04:16 +00:00
DwarfUnit.h [AsmPrinter] Prune dead code. NFC. 2015-10-15 17:16:32 +00:00
EHStreamer.cpp
EHStreamer.h [WinEH] Emit __C_specific_handler tables for the new IR 2015-10-01 21:38:24 +00:00
ErlangGCPrinter.cpp
LLVMBuild.txt
Makefile
OcamlGCPrinter.cpp
WinCodeViewLineTables.cpp
WinCodeViewLineTables.h
WinException.cpp [WinEH] Fix funclet prologues with stack realignment 2015-11-05 21:09:49 +00:00
WinException.h [WinEH] Fix funclet prologues with stack realignment 2015-11-05 21:09:49 +00:00