llvm-6502/test/DebugInfo
Devang Patel dd9db66882 Each input file is encoded as a separate compile unit in LLVM debugging
information output. However, many target specific tool chains prefer to encode
only one compile unit in an object file. In this situation, the LLVM code
generator will include  debugging information entities in the compile unit 
that is marked as main compile unit. The code generator accepts maximum one main
compile unit per module. If a module does not contain any main compile unit 
then the code generator will emit multiple compile units in the output object 
file.

[Part 1]

Update DebugInfo APIs to accept optional boolean value while creating DICompileUnit  to mark the unit as "main" unit. By defaults all units are considered  non-main.  Update SourceLevelDebugging.html to document "main" compile unit.

Update DebugInfo APIs to not accept and encode separate source file/directory entries while creating various llvm.dbg.* entities. There was a recent, yet to be documented, change to include this additional information so no documentation changes are required here.

Update DwarfDebug to handle "main" compile unit. If "main" compile unit is seen then all DIEs are inserted into "main" compile unit. All other compile units are used to find source location for llvm.dbg.* values. If there is not any "main" compile unit then create unique compile unit DIEs for each llvm.dbg.compile_unit.

[Part 2]

Create separate llvm.dbg.compile_unit for each input file. Mark compile unit create for main_input_filename as "main" compile unit. Use appropriate compile unit, based on source location information collected from the tree node, while creating llvm.dbg.* values using DebugInfo APIs.

---

This is Part 1.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@63400 91177308-0d34-0410-b5e6-96231b3b80d8
2009-01-30 18:20:31 +00:00
..
2008-10-17-C++DebugCrash.ll The Dwarf writer was comparing mangled and unmangled names for C++ code when we 2008-10-17 18:48:57 +00:00
2008-11-05-InlinedFuncStart.ll Emit label for llvm.dbg.func.start of the inlined function. 2008-11-06 21:28:20 +00:00
2008-11-06-Mem2Reg.ll Handle (delete) dbg intrinsics while promoting alloca. 2008-11-07 01:30:07 +00:00
2008-11-19-InstCombine.ll If there are two consecutive llvm.dbg.stoppoint calls then 2008-11-19 18:56:50 +00:00
2009-01-15-dbg_declare.ll Verify Intrinsic::dbg_declare. 2009-01-19 21:00:48 +00:00
2009-01-15-member.ll Fix test case. Use valid file name and directory in global variable's debug info entry. 2009-01-23 21:54:18 +00:00
2009-01-15-RecordVariableCrash.ll Do not use buggy llvm-gcc to generate testcases. 2009-01-22 18:28:11 +00:00
2009-01-28-ArrayType.ll Give this test an explicit target, to make it host-independent. 2009-01-28 22:14:58 +00:00
2009-01-29-HeaderLocation.ll Each input file is encoded as a separate compile unit in LLVM debugging 2009-01-30 18:20:31 +00:00
2009-01-29-MethodDeclaration.ll Enable target tripple. 2009-01-30 01:40:58 +00:00
dataOnly.ll Use DebugInfo interface to lower dbg_* intrinsics. 2009-01-13 00:32:17 +00:00
deaddebuglabel.ll Use DebugInfo interface to lower dbg_* intrinsics. 2009-01-13 00:32:17 +00:00
dg.exp sabre brings to my attention that the 'tr' suffix is also obsolete 2008-05-20 21:00:03 +00:00
forwardDecl.ll Assorted debug info fixes. 2009-01-27 00:45:04 +00:00
funccall.ll Remove llvm-upgrade and update tests. 2008-03-10 07:21:50 +00:00
globalGetElementPtr.ll Need compile unit to find location. 2009-01-20 22:26:11 +00:00
printdbginfo.ll This test passes again, unXFAIL. 2009-01-05 09:30:47 +00:00