DI/Verifier: Fix argument bitrot in DILocalVariable
authorDuncan P. N. Exon Smith <dexonsmith@apple.com>
Fri, 24 Jul 2015 23:59:25 +0000 (23:59 +0000)
committerDuncan P. N. Exon Smith <dexonsmith@apple.com>
Fri, 24 Jul 2015 23:59:25 +0000 (23:59 +0000)
Add a verifier check that `DILocalVariable`s of tag
`DW_TAG_arg_variable` always have a non-zero 'arg:' field, and those of
tag `DW_TAG_auto_variable` always have a zero 'arg:' field.  These are
the only configurations that are properly understood by the backend.

(Also, fix the bad examples in LangRef and test/Assembler, and fix the
bug in Kaleidoscope Ch8.)

A large number of testcases seem to have bitrotted their way forward
from some ancient version of the debug info hierarchy that didn't have
`arg:` parameters.  If you have out-of-tree testcases that start failing
in the verifier and you don't care enough to get the `arg:` right, you
may have some luck just calling:

    sed -e 's/, arg: 0/, arg: 1/'

or some such, but I hand-updated the ones in tree.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@243183 91177308-0d34-0410-b5e6-96231b3b80d8

45 files changed:
docs/LangRef.rst
docs/tutorial/LangImpl8.rst
examples/Kaleidoscope/Chapter8/toy.cpp
lib/IR/Verifier.cpp
test/Assembler/dilocalvariable.ll
test/Assembler/invalid-dilocalvariable-arg-negative.ll
test/CodeGen/ARM/2010-04-15-ScavengerDebugValue.ll
test/CodeGen/ARM/2010-06-25-Thumb2ITInvalidIterator.ll
test/CodeGen/ARM/2010-08-04-StackVariable.ll
test/CodeGen/ARM/2011-01-19-MergedGlobalDbg.ll
test/CodeGen/ARM/debug-info-d16-reg.ll
test/CodeGen/Generic/dbg_value.ll
test/CodeGen/X86/2009-02-12-DebugInfoVLA.ll
test/CodeGen/X86/2010-01-18-DbgValue.ll
test/CodeGen/X86/2010-05-25-DotDebugLoc.ll
test/CodeGen/X86/2010-05-26-DotDebugLoc.ll
test/CodeGen/X86/2010-05-28-Crash.ll
test/CodeGen/X86/2010-06-01-DeadArg-DbgInfo.ll
test/CodeGen/X86/2010-08-04-StackVariable.ll
test/CodeGen/X86/2010-11-02-DbgParameter.ll
test/CodeGen/X86/2011-01-24-DbgValue-Before-Use.ll
test/CodeGen/X86/unknown-location.ll
test/DebugInfo/2010-03-12-llc-crash.ll
test/DebugInfo/2010-03-24-MemberFn.ll
test/DebugInfo/2010-04-06-NestedFnDbgInfo.ll
test/DebugInfo/2010-05-03-DisableFramePtr.ll
test/DebugInfo/2010-05-03-OriginDIE.ll
test/DebugInfo/2010-06-29-InlinedFnLocalVar.ll
test/DebugInfo/2010-10-01-crash.ll
test/DebugInfo/Mips/InlinedFnLocalVar.ll
test/DebugInfo/X86/2010-04-13-PubType.ll
test/DebugInfo/X86/InlinedFnLocalVar.ll
test/DebugInfo/X86/dbg-byval-parameter.ll
test/DebugInfo/X86/dbg-merge-loc-entry.ll
test/DebugInfo/X86/dbg-value-dag-combine.ll
test/DebugInfo/X86/dbg-value-isel.ll
test/DebugInfo/X86/dbg-value-location.ll
test/DebugInfo/X86/dbg-value-range.ll
test/DebugInfo/inheritance.ll
test/Transforms/DeadArgElim/2010-04-30-DbgInfo.ll
test/Transforms/GlobalOpt/2009-03-05-dbg.ll
test/Transforms/LoopRotate/dbgvalue.ll
test/Transforms/Mem2Reg/ConvertDebugInfo.ll
test/Transforms/Mem2Reg/ConvertDebugInfo2.ll
test/Transforms/StripSymbols/strip-dead-debug-info.ll

index 17ee4b32bc387ca59ce98f595dca36fb67c60994..c5035984f3b71ccaad737f898d4a01b4dcc16ab5 100644 (file)
@@ -3906,12 +3906,12 @@ specifies the argument position, and this variable will be included in the
 
 .. code-block:: llvm
 
-    !0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", arg: 0,
+    !0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", arg: 1,
                           scope: !3, file: !2, line: 7, type: !3,
                           flags: DIFlagArtificial)
-    !1 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "x", arg: 1,
+    !1 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "x", arg: 2,
                           scope: !4, file: !2, line: 7, type: !3)
-    !1 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "y",
+    !2 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "y",
                           scope: !5, file: !2, line: 7, type: !3)
 
 DIExpression
index 0b9b39c84b754e1d430d44be1cd1a5d67d71800b..88224bb92f07f78263d84ce1ca2a3613ec5736fc 100644 (file)
@@ -397,7 +397,7 @@ argument allocas in ``PrototypeAST::CreateArgumentAllocas``.
                                       KSDbgInfo.TheCU.getDirectory());
   DILocalVariable D = DBuilder->createLocalVariable(
       dwarf::DW_TAG_arg_variable, Scope, Args[Idx], Unit, Line,
-      KSDbgInfo.getDoubleTy(), Idx);
+      KSDbgInfo.getDoubleTy(), true, 0, Idx + 1);
 
   Instruction *Call = DBuilder->insertDeclare(
       Alloca, D, DBuilder->createExpression(), Builder.GetInsertBlock());
index dbc996d4318267344a811f87a73b82d3cbf27a8f..72e5089177b7c3f3ddda22f18a129b382dbdf487 100644 (file)
@@ -1255,7 +1255,7 @@ void PrototypeAST::CreateArgumentAllocas(Function *F) {
                                         KSDbgInfo.TheCU->getDirectory());
     DILocalVariable *D = DBuilder->createLocalVariable(
         dwarf::DW_TAG_arg_variable, Scope, Args[Idx], Unit, Line,
-        KSDbgInfo.getDoubleTy(), Idx);
+        KSDbgInfo.getDoubleTy(), true, 0, Idx + 1);
 
     DBuilder->insertDeclare(Alloca, D, DBuilder->createExpression(),
                             DebugLoc::get(Line, 0, Scope),
index 3b041b088f2d5ce872a2c379206a6cd0a55f34b8..12e4f4ed0565ac15f0ad4a74f07c31683344e60c 100644 (file)
@@ -1063,6 +1063,8 @@ void Verifier::visitDILocalVariable(const DILocalVariable &N) {
          "invalid tag", &N);
   Assert(N.getRawScope() && isa<DILocalScope>(N.getRawScope()),
          "local variable requires a valid scope", &N, N.getRawScope());
+  Assert(bool(N.getArg()) == (N.getTag() == dwarf::DW_TAG_arg_variable),
+         "local variable should have arg iff it's a DW_TAG_arg_variable", &N);
 }
 
 void Verifier::visitDIExpression(const DIExpression &N) {
index 312373ca8623a3968a01df012e75cf52666b7077..affe6105e1cf94d88072fb0c1a94dda4159084d7 100644 (file)
@@ -20,7 +20,7 @@
 !6 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "foo", scope: !0,
                       file: !2, line: 7, type: !3, flags: DIFlagArtificial)
 
-; CHECK: !7 = !DILocalVariable(tag: DW_TAG_arg_variable, arg: 0, scope: !0)
+; CHECK: !7 = !DILocalVariable(tag: DW_TAG_arg_variable, arg: 1, scope: !0)
 ; CHECK: !8 = !DILocalVariable(tag: DW_TAG_auto_variable, scope: !0)
-!7 = !DILocalVariable(tag: DW_TAG_arg_variable, scope: !0)
+!7 = !DILocalVariable(tag: DW_TAG_arg_variable, scope: !0, arg: 1)
 !8 = !DILocalVariable(tag: DW_TAG_auto_variable, scope: !0)
index 08e370a36660ca71a46d28ab399b8cd875f4703d..ff90d66fa112ffd78d7327936a70bdcd8e4ba3e7 100644 (file)
@@ -1,6 +1,7 @@
 ; RUN: not llvm-as < %s 2>&1 | FileCheck %s
 
-!0 = !DILocalVariable(tag: DW_TAG_arg_variable, scope: !{}, arg: 0)
+!0 = !DILocalVariable(tag: DW_TAG_arg_variable, scope: !{}, arg: 1)
+!1 = !DILocalVariable(tag: DW_TAG_auto_variable, scope: !{}, arg: 0)
 
 ; CHECK: <stdin>:[[@LINE+1]]:66: error: expected unsigned integer
-!1 = !DILocalVariable(tag: DW_TAG_arg_variable, scope: !{}, arg: -1)
+!2 = !DILocalVariable(tag: DW_TAG_arg_variable, scope: !{}, arg: -1)
index 638b26c73146d3d772effcfbfc7e751faba641df..86e17205fc9567f7ed03600bd37c2579df571bb6 100644 (file)
@@ -14,7 +14,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
 
 !llvm.dbg.cu = !{!3}
 !llvm.module.flags = !{!15}
-!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "b", line: 93, arg: 0, scope: !1, file: !2, type: !6)
+!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "b", line: 93, arg: 2, scope: !1, file: !2, type: !6)
 !1 = !DISubprogram(name: "__addvsi3", linkageName: "__addvsi3", line: 94, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !12, scope: null, type: !4)
 !2 = !DIFile(filename: "libgcc2.c", directory: "/Users/bwilson/local/nightly/test-2010-04-14/build/llvmgcc.roots/llvmgcc~obj/src/gcc")
 !12 = !DIFile(filename: "libgcc2.c", directory: "/Users/bwilson/local/nightly/test-2010-04-14/build/llvmgcc.roots/llvmgcc~obj/src/gcc")
index 95bb2769759e650b51ddb02842528b70a86e827a..5637d7aa934e868a0fa73964aa190119b25114e3 100644 (file)
@@ -47,7 +47,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
 !llvm.dbg.lv.fn = !{!0, !8, !10, !12}
 !llvm.dbg.gv = !{!14}
 
-!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "buf", line: 4, arg: 0, scope: !1, file: !2, type: !6)
+!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "buf", line: 4, arg: 1, scope: !1, file: !2, type: !6)
 !1 = !DISubprogram(name: "x0", linkageName: "x0", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !26, scope: null, type: !4)
 !2 = !DIFile(filename: "t.c", directory: "/private/tmp")
 !3 = !DICompileUnit(language: DW_LANG_C99, producer: "clang 2.0", isOptimized: true, file: !26)
@@ -55,7 +55,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
 !5 = !{null}
 !6 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 32, align: 32, file: !26, scope: !2, baseType: !7)
 !7 = !DIBasicType(tag: DW_TAG_base_type, name: "unsigned char", size: 8, align: 8, encoding: DW_ATE_unsigned_char)
-!8 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "nbytes", line: 4, arg: 0, scope: !1, file: !2, type: !9)
+!8 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "nbytes", line: 4, arg: 2, scope: !1, file: !2, type: !9)
 !9 = !DIBasicType(tag: DW_TAG_base_type, name: "unsigned long", size: 32, align: 32, encoding: DW_ATE_unsigned)
 !10 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "nread", line: 6, scope: !11, file: !2, type: !9)
 !11 = distinct !DILexicalBlock(line: 5, column: 1, file: !26, scope: !1)
index 953e2bbf291c3f6ba3e9a4a827cb5c8ebe1aa922..f59d9a48a30ba2a8b08efbd1d5621d0470e5f9a6 100644 (file)
@@ -100,15 +100,15 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
 !20 = !DISubprogram(name: "main", linkageName: "main", line: 23, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !48, scope: !2, type: !21, function: i32 ()* @main)
 !21 = !DISubroutineType(types: !22)
 !22 = !{!13}
-!23 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "i", line: 16, arg: 0, scope: !17, file: !2, type: !13)
+!23 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "i", line: 16, arg: 1, scope: !17, file: !2, type: !13)
 !24 = !DILocation(line: 16, scope: !17)
-!25 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "location", line: 16, arg: 0, scope: !17, file: !2, type: !26)
+!25 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "location", line: 16, arg: 2, scope: !17, file: !2, type: !26)
 !26 = !DIDerivedType(tag: DW_TAG_reference_type, name: "SVal", size: 64, align: 64, file: !48, scope: !2, baseType: !1)
 !27 = !DILocation(line: 17, scope: !28)
 !28 = distinct !DILexicalBlock(line: 16, column: 0, file: !2, scope: !17)
 !29 = !DILocation(line: 18, scope: !28)
 !30 = !DILocation(line: 20, scope: !28)
-!31 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", line: 11, arg: 0, scope: !16, file: !2, type: !32)
+!31 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", line: 11, arg: 1, scope: !16, file: !2, type: !32)
 !32 = !DIDerivedType(tag: DW_TAG_const_type, size: 64, align: 64, flags: DIFlagArtificial, file: !48, scope: !2, baseType: !33)
 !33 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, file: !48, scope: !2, baseType: !1)
 !34 = !DILocation(line: 11, scope: !16)
index 9a5baf21b8fbda4123d317302f9ba89fa20975c8..05fd283252512a85f97da487ec8c872f8d889ee1 100644 (file)
@@ -88,7 +88,7 @@ entry:
 !7 = !DISubprogram(name: "get3", linkageName: "get3", line: 10, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 10, file: !47, scope: !1, type: !3, function: i8 (i8)* @get3, variables: !44)
 !8 = !DISubprogram(name: "get4", linkageName: "get4", line: 13, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 13, file: !47, scope: !1, type: !3, function: i8 (i8)* @get4, variables: !45)
 !9 = !DISubprogram(name: "get5", linkageName: "get5", line: 16, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 16, file: !47, scope: !1, type: !3, function: i8 (i8)* @get5, variables: !46)
-!10 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "a", line: 4, arg: 0, scope: !0, file: !1, type: !5)
+!10 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "a", line: 4, arg: 1, scope: !0, file: !1, type: !5)
 !11 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "b", line: 4, scope: !12, file: !1, type: !5)
 !12 = distinct !DILexicalBlock(line: 4, column: 0, file: !47, scope: !0)
 !13 = !DIGlobalVariable(name: "x1", line: 3, isLocal: true, isDefinition: true, scope: !1, file: !1, type: !5, variable: i8* @x1)
@@ -96,16 +96,16 @@ entry:
 !15 = !DIGlobalVariable(name: "x3", line: 9, isLocal: true, isDefinition: true, scope: !1, file: !1, type: !5, variable: i8* @x3)
 !16 = !DIGlobalVariable(name: "x4", line: 12, isLocal: true, isDefinition: true, scope: !1, file: !1, type: !5, variable: i8* @x4)
 !17 = !DIGlobalVariable(name: "x5", line: 15, isLocal: false, isDefinition: true, scope: !1, file: !1, type: !5, variable: i8* @x5)
-!18 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "a", line: 7, arg: 0, scope: !6, file: !1, type: !5)
+!18 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "a", line: 7, arg: 1, scope: !6, file: !1, type: !5)
 !19 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "b", line: 7, scope: !20, file: !1, type: !5)
 !20 = distinct !DILexicalBlock(line: 7, column: 0, file: !47, scope: !6)
-!21 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "a", line: 10, arg: 0, scope: !7, file: !1, type: !5)
+!21 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "a", line: 10, arg: 1, scope: !7, file: !1, type: !5)
 !22 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "b", line: 10, scope: !23, file: !1, type: !5)
 !23 = distinct !DILexicalBlock(line: 10, column: 0, file: !47, scope: !7)
-!24 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "a", line: 13, arg: 0, scope: !8, file: !1, type: !5)
+!24 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "a", line: 13, arg: 1, scope: !8, file: !1, type: !5)
 !25 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "b", line: 13, scope: !26, file: !1, type: !5)
 !26 = distinct !DILexicalBlock(line: 13, column: 0, file: !47, scope: !8)
-!27 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "a", line: 16, arg: 0, scope: !9, file: !1, type: !5)
+!27 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "a", line: 16, arg: 1, scope: !9, file: !1, type: !5)
 !28 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "b", line: 16, scope: !29, file: !1, type: !5)
 !29 = distinct !DILexicalBlock(line: 16, column: 0, file: !47, scope: !9)
 !30 = !DILocation(line: 4, scope: !0)
index 27bd3b8639c42c28983914f1c3e1575de60a34fc..b0cf4d10337ef5b06228bbc6c98dd57d2347d96d 100644 (file)
@@ -86,8 +86,8 @@ declare i32 @puts(i8* nocapture) nounwind
 !50 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "val", line: 4, arg: 2, scope: !9, file: !1, type: !7)
 !51 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "c", line: 4, arg: 2, scope: !9, file: !1, type: !8)
 
-!22 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "argc", line: 17, arg: 0, scope: !10, file: !1, type: !5)
-!23 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "argv", line: 17, arg: 0, scope: !10, file: !1, type: !13)
+!22 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "argc", line: 17, arg: 1, scope: !10, file: !1, type: !5)
+!23 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "argv", line: 17, arg: 2, scope: !10, file: !1, type: !13)
 !24 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "dval", line: 19, scope: !25, file: !1, type: !7)
 !25 = distinct !DILexicalBlock(line: 18, column: 0, file: !46, scope: !10)
 !26 = !DILocation(line: 4, scope: !9)
index 4038086cbb4e63fc4b3235f24464418cdc9d4728..9fe4bf3308793367b36d5f5b5e15a6366ab89d06 100644 (file)
@@ -11,4 +11,4 @@ define void @t(%0*, i32, i32, i32, i32) nounwind {
 declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnone
 
 ; !0 should conform to the format of DIVariable.
-!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "a", arg: 0, scope: !DISubprogram())
+!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "a", arg: 1, scope: !DISubprogram())
index 6c177e5b5f5abc9a0e4a3c7c895fabe414bb67b4..29086d2cce74f8efaa9a92ddc43fa484c255faaf 100644 (file)
@@ -76,7 +76,7 @@ declare i64 @strlen(i8*) nounwind readonly
 
 declare void @llvm.stackrestore(i8*) nounwind
 
-!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "s1", line: 2, arg: 0, scope: !1, file: !2, type: !6)
+!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "s1", line: 2, arg: 1, scope: !1, file: !2, type: !6)
 !1 = !DISubprogram(name: "foo", linkageName: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scope: !2, type: !3)
 !2 = !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: true, emissionKind: 0, file: !17, enums: !18, retainedTypes: !18)
 !3 = !DISubroutineType(types: !4)
index db56ae65d51e80a54b2a56b2a904efa246ccb66f..a17794336070214edc840df9f078b3bab6687522 100644 (file)
@@ -31,7 +31,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
 !llvm.dbg.cu = !{!3}
 !llvm.module.flags = !{!21}
 
-!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "my_r0", line: 11, arg: 0, scope: !1, file: !2, type: !7)
+!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "my_r0", line: 11, arg: 1, scope: !1, file: !2, type: !7)
 !1 = !DISubprogram(name: "foo", linkageName: "foo", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 11, file: !19, scope: !2, type: !4, function: double (%struct.Rect*)* @foo)
 !2 = !DIFile(filename: "b2.c", directory: "/tmp/")
 !3 = !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: false, emissionKind: 0, file: !19, enums: !20, retainedTypes: !20, subprograms: !18)
index 3b99e91915f06c93a6aa22a87fb17857a2d58053..4e5592f890038032e8511f82f066c3212a243733 100644 (file)
@@ -199,7 +199,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
 !llvm.dbg.cu = !{!3}
 !llvm.module.flags = !{!48}
 
-!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "a", line: 1921, arg: 0, scope: !1, file: !2, type: !9)
+!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "a", line: 1921, arg: 1, scope: !1, file: !2, type: !9)
 !1 = !DISubprogram(name: "__divsc3", linkageName: "__divsc3", line: 1922, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 1922, file: !45, scope: !2, type: !4, function: %0 (float, float, float, float)* @__divsc3, variables: !43)
 !2 = !DIFile(filename: "libgcc2.c", directory: "/Users/yash/clean/LG.D/gcc/../../llvmgcc/gcc")
 !3 = !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: true, emissionKind: 1, file: !45, enums: !47, retainedTypes: !47, subprograms: !44, imports:  null)
@@ -210,9 +210,9 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
 !8 = !DIBasicType(tag: DW_TAG_base_type, name: "complex float", size: 64, align: 32, encoding: DW_ATE_complex_float)
 !9 = !DIDerivedType(tag: DW_TAG_typedef, name: "SFtype", line: 167, file: !46, scope: !7, baseType: !10)
 !10 = !DIBasicType(tag: DW_TAG_base_type, name: "float", size: 32, align: 32, encoding: DW_ATE_float)
-!11 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "b", line: 1921, arg: 0, scope: !1, file: !2, type: !9)
-!12 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "c", line: 1921, arg: 0, scope: !1, file: !2, type: !9)
-!13 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "d", line: 1921, arg: 0, scope: !1, file: !2, type: !9)
+!11 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "b", line: 1921, arg: 2, scope: !1, file: !2, type: !9)
+!12 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "c", line: 1921, arg: 3, scope: !1, file: !2, type: !9)
+!13 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "d", line: 1921, arg: 4, scope: !1, file: !2, type: !9)
 !14 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "denom", line: 1923, scope: !15, file: !2, type: !9)
 !15 = distinct !DILexicalBlock(line: 1922, column: 0, file: !45, scope: !1)
 !16 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "ratio", line: 1923, scope: !15, file: !2, type: !9)
index 3670c556aa79fdeb4b08fbaba9c19ba38c601ed8..a4b94d4b4e2e9742f59840ea519f4e4f4465ce46 100644 (file)
@@ -28,11 +28,11 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
 !1 = !DIFile(filename: "foo.c", directory: "/tmp/")
 !2 = !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: true, emissionKind: 1, file: !36, enums: !37, retainedTypes: !37, subprograms: !32, globals: !31, imports:  !37)
 !3 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed)
-!4 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "x", line: 12, arg: 0, scope: !5, file: !1, type: !3)
+!4 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "x", line: 12, arg: 1, scope: !5, file: !1, type: !3)
 !5 = !DISubprogram(name: "foo", linkageName: "foo", line: 13, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 13, file: !36, scope: !1, type: !6, function: void (i32)* @foo, variables: !33)
 !6 = !DISubroutineType(types: !7)
 !7 = !{null, !3}
-!8 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "myvar", line: 17, arg: 0, scope: !9, file: !1, type: !13)
+!8 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "myvar", line: 17, arg: 1, scope: !9, file: !1, type: !13)
 !9 = !DISubprogram(name: "bar", linkageName: "bar", line: 17, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 17, file: !36, scope: !1, type: !10, function: i8* (%struct.a*)* @bar, variables: !34)
 !10 = !DISubroutineType(types: !11)
 !11 = !{!12, !13}
@@ -42,14 +42,14 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
 !15 = !{!16, !17}
 !16 = !DIDerivedType(tag: DW_TAG_member, name: "c", line: 3, size: 32, align: 32, file: !36, scope: !14, baseType: !3)
 !17 = !DIDerivedType(tag: DW_TAG_member, name: "d", line: 4, size: 64, align: 64, offset: 64, file: !36, scope: !14, baseType: !13)
-!18 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "argc", line: 22, arg: 0, scope: !19, file: !1, type: !3)
+!18 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "argc", line: 22, arg: 1, scope: !19, file: !1, type: !3)
 !19 = !DISubprogram(name: "main", linkageName: "main", line: 22, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 22, file: !36, scope: !1, type: !20, variables: !35)
 !20 = !DISubroutineType(types: !21)
 !21 = !{!3, !3, !22}
 !22 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, file: !36, scope: !1, baseType: !23)
 !23 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, file: !36, scope: !1, baseType: !24)
 !24 = !DIBasicType(tag: DW_TAG_base_type, name: "char", size: 8, align: 8, encoding: DW_ATE_signed_char)
-!25 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "argv", line: 22, arg: 0, scope: !19, file: !1, type: !22)
+!25 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "argv", line: 22, arg: 2, scope: !19, file: !1, type: !22)
 !26 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "e", line: 23, scope: !27, file: !1, type: !14)
 !27 = distinct !DILexicalBlock(line: 22, column: 0, file: !36, scope: !19)
 !28 = !DILocation(line: 18, scope: !29)
index c5201614fdd19feb01d3ebceb07023a00cabbc7a..6a6ee6a19aaa357001566d7219a86dd913daf467 100644 (file)
@@ -25,14 +25,14 @@ entry:
 !llvm.dbg.cu = !{!3}
 !llvm.module.flags = !{!20}
 
-!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "y", line: 2, arg: 0, scope: !1, file: !2, type: !6)
+!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "y", line: 2, arg: 1, scope: !1, file: !2, type: !6)
 !1 = !DISubprogram(name: "foo", linkageName: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 2, file: !18, scope: !2, type: !4, function: i32 (i32)* @foo, variables: !15)
 !2 = !DIFile(filename: "f.c", directory: "/tmp")
 !3 = !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: true, emissionKind: 1, file: !18, enums: !19, retainedTypes: !19, subprograms: !17, imports:  null)
 !4 = !DISubroutineType(types: !5)
 !5 = !{!6, !6}
 !6 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed)
-!7 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "x", line: 6, arg: 0, scope: !8, file: !2, type: !6)
+!7 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "x", line: 6, arg: 1, scope: !8, file: !2, type: !6)
 !8 = !DISubprogram(name: "bar", linkageName: "bar", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 6, file: !18, scope: !2, type: !4, function: i32 (i32)* @bar, variables: !16)
 !9 = !DILocation(line: 3, scope: !10)
 !10 = distinct !DILexicalBlock(line: 2, column: 0, file: !18, scope: !1)
index 757c92808e112f656fcb789a99e8013f42e1c30c..be985b8779eb2b0f493050eb0321b016d6f5506e 100644 (file)
@@ -23,7 +23,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
 !llvm.module.flags = !{!34}
 !llvm.dbg.lv = !{!0, !14, !15, !16, !17, !24, !25, !28}
 
-!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", line: 11, arg: 0, scope: !1, file: !3, type: !12)
+!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", line: 11, arg: 1, scope: !1, file: !3, type: !12)
 !1 = !DISubprogram(name: "bar", linkageName: "_ZN3foo3barEi", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 11, file: !31, scope: !2, type: !9, function: i32 (%struct.foo*, i32)* null)
 !2 = !DICompositeType(tag: DW_TAG_structure_type, name: "foo", line: 3, size: 32, align: 32, file: !31, scope: !3, elements: !5)
 !3 = !DIFile(filename: "foo.cp", directory: "/tmp/")
@@ -37,17 +37,17 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
 !11 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial, file: !31, scope: !3, baseType: !2)
 !12 = !DIDerivedType(tag: DW_TAG_const_type, size: 64, align: 64, flags: DIFlagArtificial, file: !31, scope: !3, baseType: !13)
 !13 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, file: !31, scope: !3, baseType: !2)
-!14 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "x", line: 11, arg: 0, scope: !1, file: !3, type: !7)
-!15 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", line: 15, arg: 0, scope: !8, file: !3, type: !12)
-!16 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "x", line: 15, arg: 0, scope: !8, file: !3, type: !7)
-!17 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "argc", line: 19, arg: 0, scope: !18, file: !3, type: !7)
+!14 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "x", line: 11, arg: 2, scope: !1, file: !3, type: !7)
+!15 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", line: 15, arg: 1, scope: !8, file: !3, type: !12)
+!16 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "x", line: 15, arg: 2, scope: !8, file: !3, type: !7)
+!17 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "argc", line: 19, arg: 1, scope: !18, file: !3, type: !7)
 !18 = !DISubprogram(name: "main", linkageName: "main", line: 19, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 19, file: !31, scope: !3, type: !19)
 !19 = !DISubroutineType(types: !20)
 !20 = !{!7, !7, !21}
 !21 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, file: !31, scope: !3, baseType: !22)
 !22 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, file: !31, scope: !3, baseType: !23)
 !23 = !DIBasicType(tag: DW_TAG_base_type, name: "char", size: 8, align: 8, encoding: DW_ATE_signed_char)
-!24 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "argv", line: 19, arg: 0, scope: !18, file: !3, type: !21)
+!24 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "argv", line: 19, arg: 2, scope: !18, file: !3, type: !21)
 !25 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "a", line: 20, scope: !26, file: !3, type: !2)
 !26 = distinct !DILexicalBlock(line: 19, column: 0, file: !31, scope: !27)
 !27 = distinct !DILexicalBlock(line: 19, column: 0, file: !31, scope: !18)
index 6129e78fd348966ba90b7c5708ad32dfe6bb1c81..e2a2884e842bff601016dd3c3e76c2603a175d16 100644 (file)
@@ -101,15 +101,15 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
 !20 = !DISubprogram(name: "main", linkageName: "main", line: 23, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 23, file: !47, scope: !2, type: !21, function: i32 ()* @main)
 !21 = !DISubroutineType(types: !22)
 !22 = !{!13}
-!23 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "i", line: 16, arg: 0, scope: !17, file: !2, type: !13)
+!23 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "i", line: 16, arg: 1, scope: !17, file: !2, type: !13)
 !24 = !DILocation(line: 16, scope: !17)
-!25 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "location", line: 16, arg: 0, scope: !17, file: !2, type: !26)
+!25 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "location", line: 16, arg: 2, scope: !17, file: !2, type: !26)
 !26 = !DIDerivedType(tag: DW_TAG_reference_type, name: "SVal", size: 64, align: 64, file: !47, scope: !2, baseType: !1)
 !27 = !DILocation(line: 17, scope: !28)
 !28 = distinct !DILexicalBlock(line: 16, column: 0, file: !47, scope: !17)
 !29 = !DILocation(line: 18, scope: !28)
 !30 = !DILocation(line: 20, scope: !28)
-!31 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", line: 11, arg: 0, scope: !16, file: !2, type: !32)
+!31 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", line: 11, arg: 1, scope: !16, file: !2, type: !32)
 !32 = !DIDerivedType(tag: DW_TAG_const_type, size: 64, align: 64, flags: DIFlagArtificial, file: !47, scope: !2, baseType: !33)
 !33 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, file: !47, scope: !2, baseType: !1)
 !34 = !DILocation(line: 11, scope: !16)
index 124cc9a430e8323774603eee7f705fc313d72a6c..cc292ccae04edb2e98e19511e8bdcb8e7fe892a6 100644 (file)
@@ -24,7 +24,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
 !3 = !DISubroutineType(types: !4)
 !4 = !{!5}
 !5 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed)
-!6 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "i", line: 3, arg: 0, scope: !0, file: !1, type: !7)
+!6 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "i", line: 3, arg: 1, scope: !0, file: !1, type: !7)
 !7 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 32, align: 32, file: !17, scope: !1, baseType: !8)
 !8 = !DICompositeType(tag: DW_TAG_structure_type, name: "bar", line: 2, size: 64, align: 32, file: !17, scope: !1, elements: !9)
 !9 = !{!10, !11}
index 0ded66fa3bf969157416a1abd2423e5c5b114076..c873915da5a2f40f966897638b8766f8e2f4f087 100644 (file)
@@ -88,8 +88,8 @@ declare i32 @puts(i8* nocapture) nounwind
 !7 = !DISubroutineType(types: !8)
 !8 = !{!9}
 !9 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed)
-!10 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "a", line: 5, arg: 0, scope: !0, file: !1, type: !5)
-!11 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "b", line: 5, arg: 0, scope: !0, file: !1, type: !5)
+!10 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "a", line: 5, arg: 1, scope: !0, file: !1, type: !5)
+!11 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "b", line: 5, arg: 2, scope: !0, file: !1, type: !5)
 !12 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "c", line: 6, scope: !13, file: !1, type: !5)
 !13 = distinct !DILexicalBlock(line: 5, column: 52, file: !31, scope: !0)
 !14 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "m", line: 26, scope: !15, file: !1, type: !16)
index c018a49d135e2db3697de435d1b2741f32b4f4b5..1b73e6496300ade0bf2eadfbe6d5098f1293c79e 100644 (file)
@@ -21,7 +21,7 @@ entry:
 !llvm.dbg.cu = !{!3}
 !llvm.module.flags = !{!12}
 
-!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "x", line: 1, arg: 0, scope: !1, file: !2, type: !6)
+!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "x", line: 1, arg: 2, scope: !1, file: !2, type: !6)
 !1 = !DISubprogram(name: "foo", linkageName: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 1, file: !10, scope: !2, type: !4, function: i32 (i32, i32, i32, i32)* @foo)
 !2 = !DIFile(filename: "test.c", directory: "/dir")
 !3 = !DICompileUnit(language: DW_LANG_C99, producer: "producer", isOptimized: false, emissionKind: 0, file: !10, enums: !11, retainedTypes: !11, subprograms: !9)
index 60e657ce5ce68919803fc232ea8fb2bd73962318..fcca6c521701662c648c7441bf11bc07908ae47b 100644 (file)
@@ -1,5 +1,5 @@
 ; RUN: llc -O0 < %s -o /dev/null
-; llc should not crash on this invalid input.
+; llc should not crash on this optimized out debug info.
 ; PR6588
 declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
 
@@ -9,7 +9,7 @@ entry:
   ret void
 }
 
-!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "sy", line: 890, arg: 0, scope: !1, file: !2, type: !7)
+!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "sy", line: 890, arg: 1, scope: !1, file: !2, type: !7)
 !1 = !DISubprogram(name: "foo", linkageName: "foo", line: 892, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !8, scope: !3, type: !4)
 !2 = !DIFile(filename: "qpainter.h", directory: "QtGui")
 !3 = !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang 1.1", isOptimized: true, emissionKind: 0, file: !9, enums: !10, retainedTypes: !10)
index 627364ea4f0051e5e1c6ea6095c8c683472db43b..83ff5f97805e6d2654074d3639214519821def82 100644 (file)
@@ -57,7 +57,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
 !15 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial, file: !25, scope: !4, baseType: !9)
 !16 = !DILocation(line: 3, scope: !1)
 !17 = !DILocation(line: 3, scope: !3)
-!18 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", line: 3, arg: 0, scope: !12, file: !10, type: !19)
+!18 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", line: 3, arg: 1, scope: !12, file: !10, type: !19)
 !19 = !DIDerivedType(tag: DW_TAG_const_type, size: 64, align: 64, flags: DIFlagArtificial, file: !25, scope: !4, baseType: !20)
 !20 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, file: !25, scope: !4, baseType: !9)
 !21 = !DILocation(line: 3, scope: !12)
index 45ed4962f7b499cf810e9dcd024cb905f97f64e8..68fd0a93eacc228b4e0cbef6201ad27f700107b3 100644 (file)
@@ -87,7 +87,7 @@ entry:
 !14 = !DILocation(line: 16, column: 5, scope: !1)
 !15 = !DILocation(line: 17, column: 3, scope: !1)
 !16 = !DILocation(line: 18, column: 1, scope: !2)
-!17 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", line: 4, arg: 0, scope: !10, file: !3, type: !13)
+!17 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", line: 4, arg: 1, scope: !10, file: !3, type: !13)
 !18 = !DILocation(line: 4, column: 7, scope: !10)
 !19 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "a", line: 9, scope: !20, file: !3, type: !21)
 !20 = distinct !DILexicalBlock(line: 4, column: 12, file: !38, scope: !10)
@@ -103,7 +103,7 @@ entry:
 !30 = !DILocation(line: 10, column: 5, scope: !20)
 !31 = !DILocation(line: 11, column: 5, scope: !20)
 !32 = !DILocation(line: 12, column: 3, scope: !10)
-!33 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", line: 7, arg: 0, scope: !23, file: !3, type: !26)
+!33 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", line: 7, arg: 1, scope: !23, file: !3, type: !26)
 !34 = !DILocation(line: 7, column: 11, scope: !23)
 !35 = !DILocation(line: 7, column: 19, scope: !36)
 !36 = distinct !DILexicalBlock(line: 7, column: 17, file: !38, scope: !23)
index 660e9dba498b71cf5efb9cee1802e4671679882d..96251596d3a371fe6527514590d548b5e676102b 100644 (file)
@@ -18,7 +18,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
 
 !llvm.dbg.cu = !{!3}
 !llvm.module.flags = !{!19}
-!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "userUPP", line: 7, arg: 0, scope: !1, file: !2, type: !6)
+!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "userUPP", line: 7, arg: 1, scope: !1, file: !2, type: !6)
 !1 = !DISubprogram(name: "DisposeDMNotificationUPP", linkageName: "DisposeDMNotificationUPP", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !16, scope: null, type: !4)
 !2 = !DIFile(filename: "t.c", directory: "/Users/echeng/LLVM/radars/r7937664/")
 !3 = !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build 9999)", isOptimized: true, emissionKind: 0, file: !16, enums: !17, retainedTypes: !17, subprograms: !18)
index da1e57caba14d393ba52e71f2bd170b06ebb7e50..40b29fe31f95bbb3e4f2809d4ce6a190ed29c926 100644 (file)
@@ -58,18 +58,18 @@ declare void @uuid_LtoB(i8*, i8*)
 !5 = !DISubroutineType(types: !6)
 !6 = !{null}
 !7 = !DILocation(line: 810, scope: !1)
-!8 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "data", line: 201, arg: 0, scope: !9, file: !10, type: !11)
+!8 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "data", line: 201, arg: 1, scope: !9, file: !10, type: !11)
 !9 = !DISubprogram(name: "_OSSwapInt64", linkageName: "_OSSwapInt64", line: 202, isLocal: true, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !10, scope: null, type: !5)
 !10 = !DIFile(filename: "OSByteOrder.h", directory: "/usr/include/libkern/ppc")
 !11 = !DIDerivedType(tag: DW_TAG_typedef, name: "uint64_t", line: 59, file: !36, scope: !3, baseType: !13)
 !12 = !DIFile(filename: "stdint.h", directory: "/usr/4.2.1/include")
 !13 = !DIBasicType(tag: DW_TAG_base_type, name: "long long unsigned int", size: 64, align: 64, encoding: DW_ATE_unsigned)
 !14 = !DILocation(line: 202, scope: !9, inlinedAt: !7)
-!15 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "base", line: 92, arg: 0, scope: !16, file: !10, type: !17)
+!15 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "base", line: 92, arg: 2, scope: !16, file: !10, type: !17)
 !16 = !DISubprogram(name: "OSReadSwapInt64", linkageName: "OSReadSwapInt64", line: 95, isLocal: true, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !38, scope: null, type: !5)
 !17 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 32, align: 32, file: !39, scope: !3, baseType: null)
 !18 = !{}
-!19 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "byteOffset", line: 94, arg: 0, scope: !16, file: !10, type: !20)
+!19 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "byteOffset", line: 94, arg: 3, scope: !16, file: !10, type: !20)
 !20 = !DIDerivedType(tag: DW_TAG_typedef, name: "uintptr_t", line: 114, file: !37, scope: !3, baseType: !22)
 !21 = !DIFile(filename: "types.h", directory: "/usr/include/ppc")
 !22 = !DIBasicType(tag: DW_TAG_base_type, name: "long unsigned int", size: 32, align: 32, encoding: DW_ATE_unsigned)
index 27a0535bc8c3ae0399ea767cea1b022ca85db83e..0d7dae9c8c78c4032a94f480070b746bd8de8b56 100644 (file)
@@ -34,10 +34,10 @@ entry:
 !6 = !DISubprogram(name: "bar", linkageName: "bar", line: 14, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !27, scope: !1, type: !7, function: i32 ()* @bar)
 !7 = !DISubroutineType(types: !8)
 !8 = !{!5}
-!9 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "j", line: 9, arg: 0, scope: !0, file: !1, type: !5)
+!9 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "j", line: 9, arg: 1, scope: !0, file: !1, type: !5)
 !10 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "xyz", line: 10, scope: !11, file: !1, type: !12)
 
-!59 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "j", line: 9, arg: 0, scope: !0, file: !1, type: !5)
+!59 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "j", line: 9, arg: 1, scope: !0, file: !1, type: !5)
 !60 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "xyz", line: 10, scope: !11, file: !1, type: !12)
 
 !11 = distinct !DILexicalBlock(line: 9, column: 0, file: !1, scope: !0)
index 5c736ba85552101daf8f141ae8fd967b073a1a6a..c1d161ce586ab571b9276461deb89b785d46611b 100644 (file)
@@ -17,7 +17,7 @@ declare void @llvm.memcpy.p0i8.p0i8.i32(i8* nocapture, i8* nocapture, i32, i32,
 !1 = !DIFile(filename: "GSFusedSilica.m", directory: "/Volumes/Data/Users/sabre/Desktop")
 !2 = !DICompileUnit(language: DW_LANG_ObjC, producer: "clang version 2.9 (trunk 115292)", isOptimized: true, runtimeVersion: 1, emissionKind: 0, file: !25, enums: !26, retainedTypes: !26)
 !5 = !DIDerivedType(tag: DW_TAG_typedef, name: "CGRect", line: 49, file: !25, baseType: null)
-!23 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "rect", line: 53, arg: 0, scope: !0, file: !1, type: !5)
+!23 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "rect", line: 53, arg: 2, scope: !0, file: !1, type: !5)
 !24 = !DILocation(line: 53, column: 33, scope: !0)
 !25 = !DIFile(filename: "GSFusedSilica.m", directory: "/Volumes/Data/Users/sabre/Desktop")
 !26 = !{}
index 2badeba2f579a42472e465697c0220f10a018008..5c67cc9ea98a0f79dd50f8ad620c315fe4a9a2c1 100644 (file)
@@ -34,10 +34,10 @@ entry:
 !6 = !DISubprogram(name: "bar", linkageName: "bar", line: 14, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !27, scope: !1, type: !7, function: i32 ()* @bar)
 !7 = !DISubroutineType(types: !8)
 !8 = !{!5}
-!9 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "j", line: 9, arg: 0, scope: !0, file: !1, type: !5)
+!9 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "j", line: 9, arg: 1, scope: !0, file: !1, type: !5)
 !10 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "xyz", line: 10, scope: !11, file: !1, type: !12)
 
-!59 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "j", line: 9, arg: 0, scope: !0, file: !1, type: !5)
+!59 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "j", line: 9, arg: 1, scope: !0, file: !1, type: !5)
 !60 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "xyz", line: 10, scope: !11, file: !1, type: !12)
 
 !11 = distinct !DILexicalBlock(line: 9, column: 0, file: !1, scope: !0)
index 85c499d59630d76f44e7d023a8ba3ff76730eb25..aa1bf4aaf5f1b4fe56c53d88ad32201a36a6cb33 100644 (file)
@@ -31,7 +31,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
 !llvm.dbg.cu = !{!3}
 !llvm.module.flags = !{!20}
 
-!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "x", line: 7, arg: 0, scope: !1, file: !2, type: !7)
+!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "x", line: 7, arg: 1, scope: !1, file: !2, type: !7)
 !1 = !DISubprogram(name: "foo", linkageName: "foo", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 7, file: !18, scope: !2, type: !4, function: i32 (%struct.X*, %struct.Y*)* @foo)
 !2 = !DIFile(filename: "a.c", directory: "/tmp/")
 !3 = !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: false, emissionKind: 0, file: !18, enums: !19, retainedTypes: !19, subprograms: !17, imports:  null)
@@ -45,7 +45,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
 !11 = !{!12}
 !12 = !DIDerivedType(tag: DW_TAG_member, name: "x", line: 5, size: 32, align: 32, file: !18, scope: !10, baseType: !6)
 !13 = !DILocation(line: 7, scope: !1)
-!14 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "y", line: 7, arg: 0, scope: !1, file: !2, type: !9)
+!14 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "y", line: 7, arg: 2, scope: !1, file: !2, type: !9)
 !15 = !DILocation(line: 7, scope: !16)
 !16 = distinct !DILexicalBlock(line: 7, column: 0, file: !18, scope: !1)
 !17 = !{!1}
index 74de8b6e6a929b62b606f0bad5095f17e5282452..c73a7b6a421d306dc6f27c11aa441a2110bedd90 100644 (file)
@@ -34,10 +34,10 @@ entry:
 !6 = !DISubprogram(name: "bar", linkageName: "bar", line: 14, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !27, scope: !1, type: !7, function: i32 ()* @bar)
 !7 = !DISubroutineType(types: !8)
 !8 = !{!5}
-!9 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "j", line: 9, arg: 0, scope: !0, file: !1, type: !5)
+!9 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "j", line: 9, arg: 1, scope: !0, file: !1, type: !5)
 !10 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "xyz", line: 10, scope: !11, file: !1, type: !12)
 
-!109 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "j", line: 9, arg: 0, scope: !0, file: !1, type: !5)
+!109 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "j", line: 9, arg: 1, scope: !0, file: !1, type: !5)
 !110 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "xyz", line: 10, scope: !11, file: !1, type: !12)
 
 !11 = distinct !DILexicalBlock(line: 9, column: 0, file: !1, scope: !0)
index e07109e08f937a81d992534eb59b54755a459fba..a592884496afbc8afa4f2b15a3571518ba5298e5 100644 (file)
@@ -28,7 +28,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
 !llvm.dbg.cu = !{!3}
 !llvm.module.flags = !{!21}
 
-!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "my_r0", line: 11, arg: 0, scope: !1, file: !2, type: !7)
+!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "my_r0", line: 11, arg: 1, scope: !1, file: !2, type: !7)
 !1 = !DISubprogram(name: "foo", linkageName: "foo", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !19, scope: !2, type: !4, function: double (%struct.Rect*)* @foo)
 !2 = !DIFile(filename: "b2.c", directory: "/tmp/")
 !3 = !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: false, emissionKind: 0, file: !19, enums: !20, retainedTypes: !20, subprograms: !18, imports:  null)
index 14265139b0fd9555ec64ae584e4556d1fb07bcff..bbcdd59a5b0f9c9dce8899643d962f16c6ce3667 100644 (file)
@@ -54,7 +54,7 @@ declare %0 @llvm.uadd.with.overflow.i64(i64, i64) nounwind readnone
 !11 = !{!12, !12, !12}
 !12 = !DIDerivedType(tag: DW_TAG_typedef, name: "TItype", line: 160, file: !30, scope: !6, baseType: !13)
 !13 = !DIBasicType(tag: DW_TAG_base_type, size: 128, align: 128, encoding: DW_ATE_signed)
-!14 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "u", line: 1093, arg: 0, scope: !9, file: !1, type: !12)
+!14 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "u", line: 1093, arg: 1, scope: !9, file: !1, type: !12)
 !15 = !DILocation(line: 1093, scope: !9)
 !16 = !{i64 0}
 !17 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "c", line: 1095, scope: !18, file: !1, type: !19)
index 4331c6591369b3699a83bb36d20531c46428d3a4..e73d161ecb72aaba9d65c9e0b01ae71a0fe91f4c 100644 (file)
@@ -31,7 +31,7 @@ entry:
 !4 = !{null, !5}
 !5 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 32, align: 32, scope: !2, baseType: !6)
 !6 = !DIBasicType(tag: DW_TAG_base_type, name: "unsigned int", size: 32, align: 32, encoding: DW_ATE_unsigned)
-!7 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "ip", line: 1, arg: 0, scope: !0, file: !1, type: !5)
+!7 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "ip", line: 1, arg: 1, scope: !0, file: !1, type: !5)
 !8 = !DILocation(line: 1, column: 42, scope: !0)
 !9 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "gid", line: 3, scope: !10, file: !1, type: !6)
 !10 = distinct !DILexicalBlock(line: 2, column: 1, file: !19, scope: !0)
index 04e4531d1d724ba270f3a0e844a2b78befc7b765..9d5a8b76ac42ceff4a759a33d720d5d835849063 100644 (file)
@@ -89,7 +89,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
 !5 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 32, align: 32, scope: !2, baseType: !6)
 !6 = !DIDerivedType(tag: DW_TAG_typedef, name: "uint", file: !20, scope: !2, baseType: !7)
 !7 = !DIBasicType(tag: DW_TAG_base_type, name: "unsigned int", size: 32, align: 32, encoding: DW_ATE_unsigned)
-!8 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "ip", line: 1, arg: 0, scope: !0, file: !1, type: !5)
+!8 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "ip", line: 1, arg: 1, scope: !0, file: !1, type: !5)
 !9 = !DILocation(line: 1, column: 32, scope: !0)
 !10 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "tid", line: 3, scope: !11, file: !1, type: !6)
 !11 = distinct !DILexicalBlock(line: 2, column: 1, file: !1, scope: !0)
index 219fa7a5ff342f9bcf10565f2e12728f1d95ea62..631c05e18442ef726732e066c48b3948a5c04e59 100644 (file)
@@ -62,7 +62,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
 !9 = !DISubroutineType(types: !10)
 !10 = !{!11}
 !11 = !DIBasicType(tag: DW_TAG_base_type, name: "unsigned char", size: 8, align: 8, encoding: DW_ATE_unsigned_char)
-!12 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "var", line: 19509, arg: 0, scope: !0, file: !1, type: !5)
+!12 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "var", line: 19509, arg: 1, scope: !0, file: !1, type: !5)
 !13 = !DILocation(line: 19509, column: 20, scope: !0)
 !14 = !DILocation(line: 18091, column: 2, scope: !15, inlinedAt: !17)
 !15 = distinct !DILexicalBlock(line: 18086, column: 1, file: !26, scope: !16)
index a8fa9073fa77143a6bdabda2594d7c5b840e7f92..b7d5d520add3a14f93339498d95eeace9bd6ac42 100644 (file)
@@ -26,7 +26,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
 !3 = !DISubroutineType(types: !4)
 !4 = !{!5}
 !5 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed)
-!6 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "b", line: 5, arg: 0, scope: !0, file: !1, type: !7)
+!6 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "b", line: 5, arg: 1, scope: !0, file: !1, type: !7)
 !7 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, scope: !2, baseType: !8)
 !8 = !DICompositeType(tag: DW_TAG_structure_type, name: "a", line: 1, size: 32, align: 32, file: !22, scope: !2, elements: !9)
 !9 = !{!10}
index 8a29d2e576a0e095dc3b801f97a276a0f1f28759..10d799b54f77a09f21732ea95fc04551c3b9f615 100644 (file)
@@ -129,7 +129,7 @@ declare void @_ZdlPv(i8*) nounwind
 !21 = !DILocation(line: 11, scope: !1)
 !22 = !DILocation(line: 13, scope: !1)
 !23 = !DILocation(line: 14, scope: !1)
-!24 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", line: 13, arg: 0, scope: !25, file: !4, type: !26)
+!24 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", line: 13, arg: 1, scope: !25, file: !4, type: !26)
 !25 = !DISubprogram(name: "test1", linkageName: "_ZN5test1C1Ev", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scope: !4, type: !15)
 !26 = !DIDerivedType(tag: DW_TAG_const_type, size: 64, align: 64, flags: DIFlagArtificial, file: !4, baseType: !27)
 !27 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, file: !4, baseType: !8)
@@ -137,13 +137,13 @@ declare void @_ZdlPv(i8*) nounwind
 !29 = !DILocation(line: 1, scope: !30)
 !30 = distinct !DILexicalBlock(line: 0, column: 0, file: !44, scope: !31)
 !31 = distinct !DILexicalBlock(line: 0, column: 0, file: !44, scope: !25)
-!32 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", line: 4, arg: 0, scope: !33, file: !4, type: !26)
+!32 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", line: 4, arg: 1, scope: !33, file: !4, type: !26)
 !33 = !DISubprogram(name: "~test1", linkageName: "_ZN5test1D1Ev", line: 4, isLocal: false, isDefinition: true, virtuality: DW_VIRTUALITY_virtual, virtualIndex: 6, isOptimized: false, scope: !8, type: !15, containingType: !8)
 !34 = !DILocation(line: 4, scope: !33)
 !35 = !DILocation(line: 5, scope: !36)
 !36 = distinct !DILexicalBlock(line: 0, column: 0, file: !44, scope: !33)
 !37 = !DILocation(line: 6, scope: !36)
-!38 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", line: 4, arg: 0, scope: !39, file: !4, type: !26)
+!38 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "this", line: 4, arg: 1, scope: !39, file: !4, type: !26)
 !39 = !DISubprogram(name: "~test1", linkageName: "_ZN5test1D0Ev", line: 4, isLocal: false, isDefinition: true, virtuality: DW_VIRTUALITY_virtual, virtualIndex: 6, isOptimized: false, scope: !8, type: !15, containingType: !8)
 !40 = !DILocation(line: 4, scope: !39)
 !41 = !DILocation(line: 5, scope: !42)
index 5ff05f0d685869cea22d6dc0b5023c2b8d0e115e..bd9704eeef4932d10f530997b27aeef375bdc539 100644 (file)
@@ -45,7 +45,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
 
 !llvm.dbg.cu = !{!3}
 !llvm.module.flags = !{!30}
-!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "name", line: 8, arg: 0, scope: !1, file: !2, type: !6)
+!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "name", line: 8, arg: 1, scope: !1, file: !2, type: !6)
 !1 = !DISubprogram(name: "vfs_addname", linkageName: "vfs_addname", line: 12, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !28, scope: !2, type: !4)
 !2 = !DIFile(filename: "tail.c", directory: "/Users/echeng/LLVM/radars/r7927803/")
 !3 = !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build 9999)", isOptimized: true, emissionKind: 0, file: !28, enums: !29, retainedTypes: !29)
@@ -55,20 +55,20 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
 !7 = !DIDerivedType(tag: DW_TAG_const_type, size: 8, align: 8, file: !28, scope: !2, baseType: !8)
 !8 = !DIBasicType(tag: DW_TAG_base_type, name: "char", size: 8, align: 8, encoding: DW_ATE_signed_char)
 !9 = !DIBasicType(tag: DW_TAG_base_type, name: "unsigned int", size: 32, align: 32, encoding: DW_ATE_unsigned)
-!10 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "len", line: 9, arg: 0, scope: !1, file: !2, type: !9)
-!11 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "hash", line: 10, arg: 0, scope: !1, file: !2, type: !9)
-!12 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "flags", line: 11, arg: 0, scope: !1, file: !2, type: !9)
+!10 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "len", line: 9, arg: 2, scope: !1, file: !2, type: !9)
+!11 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "hash", line: 10, arg: 3, scope: !1, file: !2, type: !9)
+!12 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "flags", line: 11, arg: 4, scope: !1, file: !2, type: !9)
 !13 = !DILocation(line: 13, scope: !14)
 !14 = distinct !DILexicalBlock(line: 12, column: 0, file: !28, scope: !1)
-!15 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "name", line: 17, arg: 0, scope: !16, file: !2, type: !6)
+!15 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "name", line: 17, arg: 1, scope: !16, file: !2, type: !6)
 !16 = !DISubprogram(name: "add_name_internal", linkageName: "add_name_internal", line: 22, isLocal: true, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !28, scope: !2, type: !17)
 !17 = !DISubroutineType(types: !18)
 !18 = !{!6, !6, !9, !9, !19, !9}
 !19 = !DIBasicType(tag: DW_TAG_base_type, name: "unsigned char", size: 8, align: 8, encoding: DW_ATE_unsigned_char)
-!20 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "len", line: 18, arg: 0, scope: !16, file: !2, type: !9)
-!21 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "hash", line: 19, arg: 0, scope: !16, file: !2, type: !9)
-!22 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "extra", line: 20, arg: 0, scope: !16, file: !2, type: !19)
-!23 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "flags", line: 21, arg: 0, scope: !16, file: !2, type: !9)
+!20 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "len", line: 18, arg: 2, scope: !16, file: !2, type: !9)
+!21 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "hash", line: 19, arg: 3, scope: !16, file: !2, type: !9)
+!22 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "extra", line: 20, arg: 4, scope: !16, file: !2, type: !19)
+!23 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "flags", line: 21, arg: 5, scope: !16, file: !2, type: !9)
 !24 = !DILocation(line: 23, scope: !25)
 !25 = distinct !DILexicalBlock(line: 22, column: 0, file: !28, scope: !16)
 !26 = !DILocation(line: 24, scope: !25)
index a8d618ae522d321b6642799594304ad911eb885c..07d3979acafa9cac70524c7aec17404c532371cf 100644 (file)
@@ -58,7 +58,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
 !0 = !DIGlobalVariable(name: "Stop", line: 2, isLocal: true, isDefinition: true, scope: !1, file: !1, type: !2, variable: i32* @Stop)
 !1 = !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: true, emissionKind: 0, file: !20, enums: !21, retainedTypes: !21)
 !2 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed)
-!3 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "i", line: 4, arg: 0, scope: !4, file: !1, type: !2)
+!3 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "i", line: 4, arg: 1, scope: !4, file: !1, type: !2)
 !4 = !DISubprogram(name: "foo", linkageName: "foo", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scope: !1, type: !5)
 !5 = !DISubroutineType(types: !6)
 !6 = !{!2, !2}
index 9bcca15ab551f4fdaf07340aa4e5ddc5deb98962..d65884698d457704594c213cbc824c15a457ccbd 100644 (file)
@@ -90,11 +90,11 @@ for.end:
 !3 = !DISubroutineType(types: !4)
 !4 = !{!5}
 !5 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed)
-!6 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "x", line: 32, arg: 0, scope: !0, file: !1, type: !5)
+!6 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "x", line: 32, arg: 1, scope: !0, file: !1, type: !5)
 !7 = !DILocation(line: 32, column: 13, scope: !0)
-!8 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "y", line: 32, arg: 0, scope: !0, file: !1, type: !5)
+!8 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "y", line: 32, arg: 2, scope: !0, file: !1, type: !5)
 !9 = !DILocation(line: 32, column: 20, scope: !0)
-!10 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "z", line: 32, arg: 0, scope: !0, file: !1, type: !5)
+!10 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "z", line: 32, arg: 3, scope: !0, file: !1, type: !5)
 !11 = !DILocation(line: 32, column: 27, scope: !0)
 !12 = !DILocation(line: 33, column: 3, scope: !13)
 !13 = distinct !DILexicalBlock(line: 32, column: 30, file: !18, scope: !0)
index 8a2eedd96baf2cc41f1541dec7c496a4fa72d66c..2a0fee97f24d94cab67ffa26a39bbdc7b874f04e 100644 (file)
@@ -35,7 +35,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
 !llvm.dbg.cu = !{!3}
 !llvm.module.flags = !{!14}
 
-!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "i", line: 2, arg: 0, scope: !1, file: !2, type: !7)
+!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "i", line: 2, arg: 1, scope: !1, file: !2, type: !7)
 !1 = !DISubprogram(name: "testfunc", linkageName: "testfunc", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 2, file: !12, scope: !2, type: !4, function: double (i32, double)* @testfunc)
 !2 = !DIFile(filename: "testfunc.c", directory: "/tmp")
 !3 = !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: true, emissionKind: 0, file: !12, enums: !13, retainedTypes: !13)
@@ -44,7 +44,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
 !6 = !DIBasicType(tag: DW_TAG_base_type, name: "double", size: 64, align: 64, encoding: DW_ATE_float)
 !7 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed)
 !8 = !DILocation(line: 2, scope: !1)
-!9 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "j", line: 2, arg: 0, scope: !1, file: !2, type: !6)
+!9 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "j", line: 2, arg: 2, scope: !1, file: !2, type: !6)
 !10 = !DILocation(line: 3, scope: !11)
 !11 = distinct !DILexicalBlock(line: 2, column: 0, file: !12, scope: !1)
 !12 = !DIFile(filename: "testfunc.c", directory: "/tmp")
index 831221b7f97fe83a65030d7b3171d851e8c00cbb..aff2e608d90ad0afeb4e58d09101f857ebc30306 100644 (file)
@@ -32,7 +32,7 @@ return:                                           ; preds = %entry
 
 !llvm.dbg.cu = !{!3}
 !llvm.module.flags = !{!22}
-!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "a", line: 8, arg: 0, scope: !1, file: !2, type: !6)
+!0 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "a", line: 8, arg: 1, scope: !1, file: !2, type: !6)
 !1 = !DISubprogram(name: "baz", linkageName: "baz", line: 8, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 8, file: !20, scope: !2, type: !4, function: void (i32)* @baz)
 !2 = !DIFile(filename: "bar.c", directory: "/tmp/")
 !3 = !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: true, emissionKind: 0, file: !20, enums: !21, retainedTypes: !21)
@@ -41,15 +41,15 @@ return:                                           ; preds = %entry
 !6 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed)
 !7 = !DILocation(line: 8, scope: !1)
 !8 = !DILocation(line: 9, scope: !1)
-!9 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "x", line: 4, arg: 0, scope: !10, file: !2, type: !6)
+!9 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "x", line: 4, arg: 1, scope: !10, file: !2, type: !6)
 !10 = !DISubprogram(name: "bar", linkageName: "bar", line: 4, isLocal: true, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 4, file: !20, scope: !2, type: !11)
 !11 = !DISubroutineType(types: !12)
 !12 = !{null, !6, !13, !14}
 !13 = !DIBasicType(tag: DW_TAG_base_type, name: "long int", size: 64, align: 64, encoding: DW_ATE_signed)
 !14 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, file: !20, scope: !2, baseType: null)
 !15 = !DILocation(line: 4, scope: !10, inlinedAt: !8)
-!16 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "y", line: 4, arg: 0, scope: !10, file: !2, type: !13)
-!17 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "z", line: 4, arg: 0, scope: !10, file: !2, type: !14)
+!16 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "y", line: 4, arg: 2, scope: !10, file: !2, type: !13)
+!17 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "z", line: 4, arg: 3, scope: !10, file: !2, type: !14)
 !18 = !DILocation(line: 5, scope: !10, inlinedAt: !8)
 !19 = !DILocation(line: 10, scope: !1)
 !20 = !DIFile(filename: "bar.c", directory: "/tmp/")
index 08eff003dfca038191e2e9460f631970fc76b4cc..08a1d507949a8e2b06945ce6d02318551b92f26a 100644 (file)
@@ -45,7 +45,7 @@ attributes #2 = { nounwind readonly ssp }
 !12 = !{!9, !9}
 !13 = !DILocalVariable(tag: DW_TAG_auto_variable, name: "bb", line: 5, scope: !14, file: !5, type: !9)
 !14 = distinct !DILexicalBlock(line: 5, column: 0, file: !1, scope: !3)
-!15 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "i", line: 7, arg: 0, scope: !10, file: !5, type: !9)
+!15 = !DILocalVariable(tag: DW_TAG_arg_variable, name: "i", line: 7, arg: 1, scope: !10, file: !5, type: !9)
 !16 = !DIGlobalVariable(name: "abcd", line: 2, isLocal: true, isDefinition: true, scope: !5, file: !5, type: !9)
 !17 = !DIGlobalVariable(name: "xyz", line: 3, isLocal: false, isDefinition: true, scope: !5, file: !5, type: !9, variable: i32* @xyz)
 !18 = !DILocation(line: 6, scope: !19)