[Dwarf] early exit to avoid creating dangling DIEs
authorManman Ren <mren@apple.com>
Thu, 31 Jan 2013 20:05:14 +0000 (20:05 +0000)
committerManman Ren <mren@apple.com>
Thu, 31 Jan 2013 20:05:14 +0000 (20:05 +0000)
commit53f3f9f0cbc3688a9ed77b185b70c2ef608d4481
tree3aa43db51b9dd5fcb9239dad46f95a3ebfa1087c
parentdf782d222529e1ed1d81488a32ee8b5958225a12
[Dwarf] early exit to avoid creating dangling DIEs

We used to create children DIEs for a scope, then check whether ScopeDIE is
null. If ScopeDIE is null, the children DIEs will be dangling. Other DIEs can
link to those dangling DIEs, which are not emitted at all, causing dwarf error.

The current testing case is 4k lines, from MultiSource/BenchMark/McCat/09-vor.

rdar://problem/13071959

llvm-svn: 174084
llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp