Use the 'count' attribute to calculate the upper bound of an array.
authorBill Wendling <isanbard@gmail.com>
Tue, 4 Dec 2012 21:34:03 +0000 (21:34 +0000)
committerBill Wendling <isanbard@gmail.com>
Tue, 4 Dec 2012 21:34:03 +0000 (21:34 +0000)
commitd7767125d5b8e12db826aa7dd761a82e63ec235b
treeb53f593b8c4cc364bcbb1e7ee12ad122618cdace
parent751afdc3d1583dab43064892c90eb864cd69cd37
Use the 'count' attribute to calculate the upper bound of an array.

The count attribute is more accurate with regards to the size of an array. It
also obviates the upper bound attribute in the subrange. We can also better
handle an unbound array by setting the count to -1 instead of the lower bound to
1 and upper bound to 0.

llvm-svn: 169312
23 files changed:
llvm/include/llvm/DIBuilder.h
llvm/include/llvm/DebugInfo.h
llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
llvm/lib/VMCore/DIBuilder.cpp
llvm/lib/VMCore/DebugInfo.cpp
llvm/test/CodeGen/ARM/debug-info-branch-folding.ll
llvm/test/CodeGen/ARM/debug-info-qreg.ll
llvm/test/CodeGen/Thumb/2010-07-15-debugOrdering.ll
llvm/test/CodeGen/X86/2009-02-12-DebugInfoVLA.ll
llvm/test/CodeGen/X86/2010-07-06-DbgCrash.ll
llvm/test/CodeGen/X86/2012-11-30-misched-dbg.ll
llvm/test/CodeGen/X86/dbg-at-specficiation.ll
llvm/test/CodeGen/X86/dbg-declare.ll
llvm/test/CodeGen/X86/dbg-subrange.ll
llvm/test/DebugInfo/2010-03-30-InvalidDbgInfoCrash.ll
llvm/test/DebugInfo/2010-05-03-OriginDIE.ll
llvm/test/DebugInfo/X86/empty-and-one-elem-array.ll
llvm/test/DebugInfo/X86/empty-array.ll
llvm/test/DebugInfo/X86/op_deref.ll
llvm/test/DebugInfo/array.ll
llvm/test/JitListener/test-common-symbols.ll
llvm/test/JitListener/test-inline.ll
llvm/test/JitListener/test-parameters.ll