summaryrefslogtreecommitdiffstats
path: root/llvm/test/DebugInfo
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/test/DebugInfo')
-rw-r--r--llvm/test/DebugInfo/2009-11-05-DeadGlobalVariable.ll2
-rw-r--r--llvm/test/DebugInfo/2009-11-10-CurrentFn.ll6
-rw-r--r--llvm/test/DebugInfo/2010-01-05-DbgScope.ll4
-rw-r--r--llvm/test/DebugInfo/2010-03-19-DbgDeclare.ll2
-rw-r--r--llvm/test/DebugInfo/2010-03-24-MemberFn.ll8
-rw-r--r--llvm/test/DebugInfo/2010-04-06-NestedFnDbgInfo.ll22
-rw-r--r--llvm/test/DebugInfo/2010-04-19-FramePtr.ll4
-rw-r--r--llvm/test/DebugInfo/2010-05-03-DisableFramePtr.ll4
-rw-r--r--llvm/test/DebugInfo/2010-05-03-OriginDIE.ll6
-rw-r--r--llvm/test/DebugInfo/2010-05-10-MultipleCU.ll4
-rw-r--r--llvm/test/DebugInfo/2010-06-29-InlinedFnLocalVar.ll10
-rw-r--r--llvm/test/DebugInfo/2010-07-19-Crash.ll2
-rw-r--r--llvm/test/DebugInfo/2010-10-01-crash.ll2
-rw-r--r--llvm/test/DebugInfo/AArch64/cfi-eof-prologue.ll12
-rw-r--r--llvm/test/DebugInfo/AArch64/coalescing.ll6
-rw-r--r--llvm/test/DebugInfo/AArch64/dwarfdump.ll2
-rw-r--r--llvm/test/DebugInfo/AArch64/struct_by_value.ll4
-rw-r--r--llvm/test/DebugInfo/ARM/PR16736.ll6
-rw-r--r--llvm/test/DebugInfo/ARM/cfi-eof-prologue.ll12
-rw-r--r--llvm/test/DebugInfo/ARM/lowerbdgdeclare_vla.ll14
-rw-r--r--llvm/test/DebugInfo/ARM/s-super-register.ll10
-rw-r--r--llvm/test/DebugInfo/COFF/asan-module-ctor.ll2
-rw-r--r--llvm/test/DebugInfo/COFF/asm.ll6
-rw-r--r--llvm/test/DebugInfo/COFF/cpp-mangling.ll2
-rw-r--r--llvm/test/DebugInfo/COFF/multifile.ll8
-rw-r--r--llvm/test/DebugInfo/COFF/multifunction.ll16
-rw-r--r--llvm/test/DebugInfo/COFF/simple.ll4
-rw-r--r--llvm/test/DebugInfo/COFF/tail-call-without-lexical-scopes.ll8
-rw-r--r--llvm/test/DebugInfo/Inputs/gmlt.ll14
-rw-r--r--llvm/test/DebugInfo/Mips/delay-slot.ll10
-rw-r--r--llvm/test/DebugInfo/PR20038.ll26
-rw-r--r--llvm/test/DebugInfo/Sparc/gnu-window-save.ll4
-rw-r--r--llvm/test/DebugInfo/SystemZ/variable-loc.ll12
-rw-r--r--llvm/test/DebugInfo/X86/2010-04-13-PubType.ll4
-rw-r--r--llvm/test/DebugInfo/X86/2010-08-10-DbgConstant.ll2
-rw-r--r--llvm/test/DebugInfo/X86/2011-09-26-GlobalVarContext.ll6
-rw-r--r--llvm/test/DebugInfo/X86/2011-12-16-BadStructRef.ll38
-rw-r--r--llvm/test/DebugInfo/X86/DW_AT_byte_size.ll4
-rw-r--r--llvm/test/DebugInfo/X86/DW_AT_linkage_name.ll14
-rw-r--r--llvm/test/DebugInfo/X86/DW_AT_location-reference.ll16
-rw-r--r--llvm/test/DebugInfo/X86/DW_AT_object_pointer.ll18
-rw-r--r--llvm/test/DebugInfo/X86/DW_AT_specification.ll2
-rw-r--r--llvm/test/DebugInfo/X86/DW_AT_stmt_list_sec_offset.ll2
-rw-r--r--llvm/test/DebugInfo/X86/aligned_stack_var.ll4
-rw-r--r--llvm/test/DebugInfo/X86/arguments.ll6
-rw-r--r--llvm/test/DebugInfo/X86/array.ll14
-rw-r--r--llvm/test/DebugInfo/X86/array2.ll14
-rw-r--r--llvm/test/DebugInfo/X86/block-capture.ll10
-rw-r--r--llvm/test/DebugInfo/X86/byvalstruct.ll8
-rw-r--r--llvm/test/DebugInfo/X86/coff_debug_info_type.ll2
-rw-r--r--llvm/test/DebugInfo/X86/coff_relative_names.ll2
-rw-r--r--llvm/test/DebugInfo/X86/concrete_out_of_line.ll12
-rw-r--r--llvm/test/DebugInfo/X86/constant-aggregate.ll12
-rw-r--r--llvm/test/DebugInfo/X86/cu-ranges-odr.ll8
-rw-r--r--llvm/test/DebugInfo/X86/cu-ranges.ll4
-rw-r--r--llvm/test/DebugInfo/X86/dbg-byval-parameter.ll4
-rw-r--r--llvm/test/DebugInfo/X86/dbg-const-int.ll4
-rw-r--r--llvm/test/DebugInfo/X86/dbg-const.ll8
-rw-r--r--llvm/test/DebugInfo/X86/dbg-declare-arg.ll30
-rw-r--r--llvm/test/DebugInfo/X86/dbg-declare.ll10
-rw-r--r--llvm/test/DebugInfo/X86/dbg-i128-const.ll2
-rw-r--r--llvm/test/DebugInfo/X86/dbg-merge-loc-entry.ll14
-rw-r--r--llvm/test/DebugInfo/X86/dbg-prolog-end.ll14
-rw-r--r--llvm/test/DebugInfo/X86/dbg-subrange.ll4
-rw-r--r--llvm/test/DebugInfo/X86/dbg-value-const-byref.ll12
-rw-r--r--llvm/test/DebugInfo/X86/dbg-value-dag-combine.ll12
-rw-r--r--llvm/test/DebugInfo/X86/dbg-value-inlined-parameter.ll22
-rw-r--r--llvm/test/DebugInfo/X86/dbg-value-isel.ll12
-rw-r--r--llvm/test/DebugInfo/X86/dbg-value-location.ll10
-rw-r--r--llvm/test/DebugInfo/X86/dbg-value-range.ll8
-rw-r--r--llvm/test/DebugInfo/X86/dbg-value-terminator.ll2
-rw-r--r--llvm/test/DebugInfo/X86/dbg_value_direct.ll4
-rw-r--r--llvm/test/DebugInfo/X86/debug-dead-local-var.ll2
-rw-r--r--llvm/test/DebugInfo/X86/debug-info-access.ll2
-rw-r--r--llvm/test/DebugInfo/X86/debug-info-block-captured-self.ll8
-rw-r--r--llvm/test/DebugInfo/X86/debug-info-blocks.ll32
-rw-r--r--llvm/test/DebugInfo/X86/debug-info-static-member.ll6
-rw-r--r--llvm/test/DebugInfo/X86/debug-loc-asan.ll2
-rw-r--r--llvm/test/DebugInfo/X86/debug-loc-offset.ll18
-rw-r--r--llvm/test/DebugInfo/X86/debug-ranges-offset.ll20
-rw-r--r--llvm/test/DebugInfo/X86/decl-derived-member.ll18
-rw-r--r--llvm/test/DebugInfo/X86/discriminator.ll8
-rw-r--r--llvm/test/DebugInfo/X86/dwarf-aranges-no-dwarf-labels.ll6
-rw-r--r--llvm/test/DebugInfo/X86/dwarf-aranges.ll4
-rw-r--r--llvm/test/DebugInfo/X86/dwarf-public-names.ll14
-rw-r--r--llvm/test/DebugInfo/X86/dwarf-pubnames-split.ll2
-rw-r--r--llvm/test/DebugInfo/X86/elf-names.ll24
-rw-r--r--llvm/test/DebugInfo/X86/empty-and-one-elem-array.ll10
-rw-r--r--llvm/test/DebugInfo/X86/ending-run.ll8
-rw-r--r--llvm/test/DebugInfo/X86/fission-inline.ll10
-rw-r--r--llvm/test/DebugInfo/X86/fission-ranges.ll20
-rw-r--r--llvm/test/DebugInfo/X86/formal_parameter.ll8
-rw-r--r--llvm/test/DebugInfo/X86/generate-odr-hash.ll12
-rw-r--r--llvm/test/DebugInfo/X86/ghost-sdnode-dbgvalues.ll24
-rw-r--r--llvm/test/DebugInfo/X86/gnu-public-names.ll18
-rw-r--r--llvm/test/DebugInfo/X86/inline-member-function.ll6
-rw-r--r--llvm/test/DebugInfo/X86/inline-seldag-test.ll10
-rw-r--r--llvm/test/DebugInfo/X86/instcombine-instrinsics.ll10
-rw-r--r--llvm/test/DebugInfo/X86/lexical_block.ll6
-rw-r--r--llvm/test/DebugInfo/X86/line-info.ll6
-rw-r--r--llvm/test/DebugInfo/X86/linkage-name.ll6
-rw-r--r--llvm/test/DebugInfo/X86/low-pc-cu.ll2
-rw-r--r--llvm/test/DebugInfo/X86/misched-dbg-value.ll28
-rw-r--r--llvm/test/DebugInfo/X86/nodebug_with_debug_loc.ll10
-rw-r--r--llvm/test/DebugInfo/X86/objc-property-void.ll4
-rw-r--r--llvm/test/DebugInfo/X86/op_deref.ll18
-rw-r--r--llvm/test/DebugInfo/X86/parameters.ll12
-rw-r--r--llvm/test/DebugInfo/X86/pieces-1.ll4
-rw-r--r--llvm/test/DebugInfo/X86/pieces-2.ll6
-rw-r--r--llvm/test/DebugInfo/X86/pieces-3.ll6
-rw-r--r--llvm/test/DebugInfo/X86/pr11300.ll10
-rw-r--r--llvm/test/DebugInfo/X86/pr12831.ll28
-rw-r--r--llvm/test/DebugInfo/X86/pr13303.ll2
-rw-r--r--llvm/test/DebugInfo/X86/pr19307.ll16
-rw-r--r--llvm/test/DebugInfo/X86/prologue-stack.ll4
-rw-r--r--llvm/test/DebugInfo/X86/recursive_inlining.ll62
-rw-r--r--llvm/test/DebugInfo/X86/reference-argument.ll22
-rw-r--r--llvm/test/DebugInfo/X86/rvalue-ref.ll6
-rw-r--r--llvm/test/DebugInfo/X86/sret.ll78
-rw-r--r--llvm/test/DebugInfo/X86/stmt-list-multiple-compile-units.ll8
-rw-r--r--llvm/test/DebugInfo/X86/subrange-type.ll4
-rw-r--r--llvm/test/DebugInfo/X86/subreg.ll2
-rw-r--r--llvm/test/DebugInfo/X86/subregisters.ll14
-rw-r--r--llvm/test/DebugInfo/X86/template.ll6
-rw-r--r--llvm/test/DebugInfo/X86/tls.ll2
-rw-r--r--llvm/test/DebugInfo/X86/union-template.ll6
-rw-r--r--llvm/test/DebugInfo/X86/vla.ll14
-rw-r--r--llvm/test/DebugInfo/array.ll4
-rw-r--r--llvm/test/DebugInfo/block-asan.ll8
-rw-r--r--llvm/test/DebugInfo/constant-pointers.ll2
-rw-r--r--llvm/test/DebugInfo/cross-cu-inlining.ll10
-rw-r--r--llvm/test/DebugInfo/cross-cu-linkonce-distinct.ll4
-rw-r--r--llvm/test/DebugInfo/cross-cu-linkonce.ll4
-rw-r--r--llvm/test/DebugInfo/cu-range-hole.ll4
-rw-r--r--llvm/test/DebugInfo/cu-ranges.ll8
-rw-r--r--llvm/test/DebugInfo/dead-argument-order.ll2
-rw-r--r--llvm/test/DebugInfo/debug-info-always-inline.ll14
-rw-r--r--llvm/test/DebugInfo/debug-info-qualifiers.ll8
-rw-r--r--llvm/test/DebugInfo/debuginfofinder-multiple-cu.ll4
-rw-r--r--llvm/test/DebugInfo/duplicate_inline.ll20
-rw-r--r--llvm/test/DebugInfo/dwarf-public-names.ll14
-rw-r--r--llvm/test/DebugInfo/enum-types.ll8
-rw-r--r--llvm/test/DebugInfo/enum.ll4
-rw-r--r--llvm/test/DebugInfo/global.ll2
-rw-r--r--llvm/test/DebugInfo/incorrect-variable-debugloc.ll18
-rw-r--r--llvm/test/DebugInfo/incorrect-variable-debugloc1.ll8
-rw-r--r--llvm/test/DebugInfo/inheritance.ll22
-rw-r--r--llvm/test/DebugInfo/inline-debug-info-multiret.ll30
-rw-r--r--llvm/test/DebugInfo/inline-debug-info.ll30
-rw-r--r--llvm/test/DebugInfo/inline-no-debug-info.ll8
-rw-r--r--llvm/test/DebugInfo/inline-scopes.ll22
-rw-r--r--llvm/test/DebugInfo/inlined-arguments.ll14
-rw-r--r--llvm/test/DebugInfo/inlined-vars.ll10
-rw-r--r--llvm/test/DebugInfo/lto-comp-dir.ll6
-rw-r--r--llvm/test/DebugInfo/member-order.ll4
-rw-r--r--llvm/test/DebugInfo/missing-abstract-variable.ll26
-rw-r--r--llvm/test/DebugInfo/multiline.ll14
-rw-r--r--llvm/test/DebugInfo/namespace.ll24
-rw-r--r--llvm/test/DebugInfo/namespace_function_definition.ll2
-rw-r--r--llvm/test/DebugInfo/namespace_inline_function_definition.ll6
-rw-r--r--llvm/test/DebugInfo/nodebug.ll2
-rw-r--r--llvm/test/DebugInfo/restrict.ll4
-rw-r--r--llvm/test/DebugInfo/sugared-constants.ll14
-rw-r--r--llvm/test/DebugInfo/tu-composite.ll18
-rw-r--r--llvm/test/DebugInfo/two-cus-from-same-file.ll14
-rw-r--r--llvm/test/DebugInfo/unconditional-branch.ll8
-rw-r--r--llvm/test/DebugInfo/varargs.ll8
-rw-r--r--llvm/test/DebugInfo/version.ll2
168 files changed, 878 insertions, 878 deletions
diff --git a/llvm/test/DebugInfo/2009-11-05-DeadGlobalVariable.ll b/llvm/test/DebugInfo/2009-11-05-DeadGlobalVariable.ll
index 50f42d087bc..c73b945a7db 100644
--- a/llvm/test/DebugInfo/2009-11-05-DeadGlobalVariable.ll
+++ b/llvm/test/DebugInfo/2009-11-05-DeadGlobalVariable.ll
@@ -20,7 +20,7 @@ entry:
!9 = !{!"0x24\00int\000\0032\0032\000\000\005", null, null} ; [ DW_TAG_base_type ]
!12 = !{!14}
!14 = !{!"0x34\00bar\00bar\00\002\001\001", !5, !6, !9, null, null} ; [ DW_TAG_variable ]
-!15 = !{i32 3, i32 3, !16, null}
+!15 = !MDLocation(line: 3, column: 3, scope: !16)
!16 = !{!"0xb\001\0011\000", !17, !5} ; [ DW_TAG_lexical_block ]
!17 = !{!"fb.c", !"/private/tmp"}
!18 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/2009-11-10-CurrentFn.ll b/llvm/test/DebugInfo/2009-11-10-CurrentFn.ll
index 189a30b9681..bf237eee23f 100644
--- a/llvm/test/DebugInfo/2009-11-10-CurrentFn.ll
+++ b/llvm/test/DebugInfo/2009-11-10-CurrentFn.ll
@@ -23,9 +23,9 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
!9 = !{!11}
!11 = !{!"0x101\00i\0016777219\000", !17, !5, !12} ; [ DW_TAG_arg_variable ]
!12 = !{!"0x24\00int\000\0032\0032\000\000\005", null, null} ; [ DW_TAG_base_type ]
-!13 = !{i32 3, i32 14, !5, null}
-!14 = !{i32 4, i32 3, !15, null}
+!13 = !MDLocation(line: 3, column: 14, scope: !5)
+!14 = !MDLocation(line: 4, column: 3, scope: !15)
!15 = !{!"0xb\003\0017\000", !17, !5} ; [ DW_TAG_lexical_block ]
-!16 = !{i32 5, i32 1, !15, null}
+!16 = !MDLocation(line: 5, column: 1, scope: !15)
!17 = !{!"cf.c", !"/private/tmp"}
!18 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/2010-01-05-DbgScope.ll b/llvm/test/DebugInfo/2010-01-05-DbgScope.ll
index 53b67ed3488..d55972024dd 100644
--- a/llvm/test/DebugInfo/2010-01-05-DbgScope.ll
+++ b/llvm/test/DebugInfo/2010-01-05-DbgScope.ll
@@ -11,14 +11,14 @@ entry:
!llvm.dbg.cu = !{!3}
!llvm.module.flags = !{!14}
-!0 = !{i32 571, i32 3, !1, null}
+!0 = !MDLocation(line: 571, column: 3, scope: !1)
!1 = !{!"0xb\001\001\000", !11, !2}; [DW_TAG_lexical_block ]
!2 = !{!"0x2e\00foo\00foo\00foo\00561\000\001\000\006\000\000\000", i32 0, !3, !4, null, null, null, null, null}; [DW_TAG_subprogram ]
!3 = !{!"0x11\0012\00clang 1.1\001\00\000\00\000", !11, !12, !12, !13, null, null}; [DW_TAG_compile_unit ]
!4 = !{!"0x15\00\000\000\000\000\000\000", null, !3, null, !5, null, null, null} ; [ DW_TAG_subroutine_type ] [line 0, size 0, align 0, offset 0] [from ]
!5 = !{!6}
!6 = !{!"0x24\00char\000\008\008\000\000\006", null, !3} ; [ DW_TAG_base_type ]
-!10 = !{i32 588, i32 1, !2, null}
+!10 = !MDLocation(line: 588, column: 1, scope: !2)
!11 = !{!"hashtab.c", !"/usr/src/gnu/usr.bin/cc/cc_tools/../../../../contrib/gcclibs/libiberty"}
!12 = !{i32 0}
!13 = !{!2}
diff --git a/llvm/test/DebugInfo/2010-03-19-DbgDeclare.ll b/llvm/test/DebugInfo/2010-03-19-DbgDeclare.ll
index e2b008b23ab..83168016098 100644
--- a/llvm/test/DebugInfo/2010-03-19-DbgDeclare.ll
+++ b/llvm/test/DebugInfo/2010-03-19-DbgDeclare.ll
@@ -11,7 +11,7 @@ entry:
!llvm.module.flags = !{!5}
!2 = !{!"0x11\0032769\00clang version 3.3 \000\00\000\00\001", !4, !3, !3, !3, !3, !3} ; [ DW_TAG_compile_unit ] [/usr/local/google/home/blaikie/dev/scratch/scratch.cpp] [lang 0x8001]
!3 = !{}
-!0 = !{i32 662302, i32 26, !1, null}
+!0 = !MDLocation(line: 662302, column: 26, scope: !1)
!1 = !{i32 4, !"foo"}
!4 = !{!"scratch.cpp", !"/usr/local/google/home/blaikie/dev/scratch"}
diff --git a/llvm/test/DebugInfo/2010-03-24-MemberFn.ll b/llvm/test/DebugInfo/2010-03-24-MemberFn.ll
index c9a3b742efa..7b091095048 100644
--- a/llvm/test/DebugInfo/2010-03-24-MemberFn.ll
+++ b/llvm/test/DebugInfo/2010-03-24-MemberFn.ll
@@ -55,13 +55,13 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
!13 = !{!"0x15\00\000\000\000\000\000\000", !25, null, null, !14, null, null, null} ; [ DW_TAG_subroutine_type ] [line 0, size 0, align 0, offset 0] [from ]
!14 = !{!8, !15}
!15 = !{!"0xf\00\000\0064\0064\000\0064", !25, !4, !9} ; [ DW_TAG_pointer_type ]
-!16 = !{i32 3, i32 0, !1, null}
-!17 = !{i32 3, i32 0, !3, null}
+!16 = !MDLocation(line: 3, scope: !1)
+!17 = !MDLocation(line: 3, scope: !3)
!18 = !{!"0x101\00this\003\000", !12, !10, !19} ; [ DW_TAG_arg_variable ]
!19 = !{!"0x26\00\000\0064\0064\000\0064", !25, !4, !20} ; [ DW_TAG_const_type ]
!20 = !{!"0xf\00\000\0064\0064\000\000", !25, !4, !9} ; [ DW_TAG_pointer_type ]
-!21 = !{i32 3, i32 0, !12, null}
-!22 = !{i32 3, i32 0, !23, null}
+!21 = !MDLocation(line: 3, scope: !12)
+!22 = !MDLocation(line: 3, scope: !23)
!23 = !{!"0xb\003\000\000", !26, !12} ; [ DW_TAG_lexical_block ]
!24 = !{!3, !12}
!25 = !{!"one.cc", !"/tmp/"}
diff --git a/llvm/test/DebugInfo/2010-04-06-NestedFnDbgInfo.ll b/llvm/test/DebugInfo/2010-04-06-NestedFnDbgInfo.ll
index 1d0f9755093..ce52d24aa7f 100644
--- a/llvm/test/DebugInfo/2010-04-06-NestedFnDbgInfo.ll
+++ b/llvm/test/DebugInfo/2010-04-06-NestedFnDbgInfo.ll
@@ -84,11 +84,11 @@ entry:
!11 = !{!"0x15\00\000\000\000\000\000\000", !38, !3, null, !12, null, null, null} ; [ DW_TAG_subroutine_type ] [line 0, size 0, align 0, offset 0] [from ]
!12 = !{!7, !13}
!13 = !{!"0xf\00\000\0064\0064\000\0064", !38, !3, !8} ; [ DW_TAG_pointer_type ]
-!14 = !{i32 16, i32 5, !1, null}
-!15 = !{i32 17, i32 3, !1, null}
-!16 = !{i32 18, i32 1, !2, null}
+!14 = !MDLocation(line: 16, column: 5, scope: !1)
+!15 = !MDLocation(line: 17, column: 3, scope: !1)
+!16 = !MDLocation(line: 18, column: 1, scope: !2)
!17 = !{!"0x101\00this\004\000", !10, !3, !13} ; [ DW_TAG_arg_variable ]
-!18 = !{i32 4, i32 7, !10, null}
+!18 = !MDLocation(line: 4, column: 7, scope: !10)
!19 = !{!"0x100\00a\009\000", !20, !3, !21} ; [ DW_TAG_auto_variable ]
!20 = !{!"0xb\004\0012\000", !38, !10} ; [ DW_TAG_lexical_block ]
!21 = !{!"0x2\00A\005\008\008\000\000\000", !38, !10, null, !22, null, null, null} ; [ DW_TAG_class_type ] [A] [line 5, size 8, align 8, offset 0] [def] [from ]
@@ -97,15 +97,15 @@ entry:
!24 = !{!"0x15\00\000\000\000\000\000\000", !38, !3, null, !25, null, null, null} ; [ DW_TAG_subroutine_type ] [line 0, size 0, align 0, offset 0] [from ]
!25 = !{!7, !26}
!26 = !{!"0xf\00\000\0064\0064\000\0064", !38, !3, !21} ; [ DW_TAG_pointer_type ]
-!27 = !{i32 9, i32 7, !20, null}
+!27 = !MDLocation(line: 9, column: 7, scope: !20)
!28 = !{!"0x100\00i\0010\000", !20, !3, !7} ; [ DW_TAG_auto_variable ]
-!29 = !{i32 10, i32 9, !20, null}
-!30 = !{i32 10, i32 5, !20, null}
-!31 = !{i32 11, i32 5, !20, null}
-!32 = !{i32 12, i32 3, !10, null}
+!29 = !MDLocation(line: 10, column: 9, scope: !20)
+!30 = !MDLocation(line: 10, column: 5, scope: !20)
+!31 = !MDLocation(line: 11, column: 5, scope: !20)
+!32 = !MDLocation(line: 12, column: 3, scope: !10)
!33 = !{!"0x101\00this\007\000", !23, !3, !26} ; [ DW_TAG_arg_variable ]
-!34 = !{i32 7, i32 11, !23, null}
-!35 = !{i32 7, i32 19, !36, null}
+!34 = !MDLocation(line: 7, column: 11, scope: !23)
+!35 = !MDLocation(line: 7, column: 19, scope: !36)
!36 = !{!"0xb\007\0017\000", !38, !23} ; [ DW_TAG_lexical_block ]
!38 = !{!"one.cc", !"/tmp" }
!39 = !{i32 0}
diff --git a/llvm/test/DebugInfo/2010-04-19-FramePtr.ll b/llvm/test/DebugInfo/2010-04-19-FramePtr.ll
index 64eac36c2d1..fe5a1f44855 100644
--- a/llvm/test/DebugInfo/2010-04-19-FramePtr.ll
+++ b/llvm/test/DebugInfo/2010-04-19-FramePtr.ll
@@ -23,14 +23,14 @@ return: ; preds = %entry
!llvm.module.flags = !{!12}
!9 = !{!1}
-!0 = !{i32 2, i32 0, !1, null}
+!0 = !MDLocation(line: 2, scope: !1)
!1 = !{!"0x2e\00foo\00foo\00foo\002\000\001\000\006\000\000\002", !10, null, !4, null, i32 ()* @foo, null, null, null} ; [ DW_TAG_subprogram ]
!2 = !{!"0x29", !10} ; [ DW_TAG_file_type ]
!3 = !{!"0x11\001\004.2.1 (Based on Apple Inc. build 5658) (LLVM build)\000\00\000\00\000", !10, !11, !11, !9, null, null} ; [ DW_TAG_compile_unit ]
!4 = !{!"0x15\00\000\000\000\000\000\000", !10, !2, null, !5, null, null, null} ; [ DW_TAG_subroutine_type ] [line 0, size 0, align 0, offset 0] [from ]
!5 = !{!6}
!6 = !{!"0x24\00int\000\0032\0032\000\000\005", !10, !2} ; [ DW_TAG_base_type ]
-!7 = !{i32 2, i32 0, !8, null}
+!7 = !MDLocation(line: 2, scope: !8)
!8 = !{!"0xb\002\000\000", !10, !1} ; [ DW_TAG_lexical_block ]
!10 = !{!"a.c", !"/tmp"}
!11 = !{i32 0}
diff --git a/llvm/test/DebugInfo/2010-05-03-DisableFramePtr.ll b/llvm/test/DebugInfo/2010-05-03-DisableFramePtr.ll
index c2a7607674c..d767871a276 100644
--- a/llvm/test/DebugInfo/2010-05-03-DisableFramePtr.ll
+++ b/llvm/test/DebugInfo/2010-05-03-DisableFramePtr.ll
@@ -31,8 +31,8 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
!10 = !{!"0xf\00\000\0064\0064\000\000", !16, !2, !11} ; [ DW_TAG_pointer_type ]
!11 = !{!"0x16\00AppleEvent\004\000\000\000\000", !16, !2, !12} ; [ DW_TAG_typedef ]
!12 = !{!"0x13\00AEDesc\001\000\000\000\004\000", !16, !2, null, null, null, null, null} ; [ DW_TAG_structure_type ] [AEDesc] [line 1, size 0, align 0, offset 0] [decl] [from ]
-!13 = !{i32 7, i32 0, !1, null}
-!14 = !{i32 8, i32 0, !15, null}
+!13 = !MDLocation(line: 7, scope: !1)
+!14 = !MDLocation(line: 8, scope: !15)
!15 = !{!"0xb\007\000\000", !16, !1} ; [ DW_TAG_lexical_block ]
!16 = !{!"t.c", !"/Users/echeng/LLVM/radars/r7937664/"}
!17 = !{i32 0}
diff --git a/llvm/test/DebugInfo/2010-05-03-OriginDIE.ll b/llvm/test/DebugInfo/2010-05-03-OriginDIE.ll
index ea2d4af7afb..1caae64967b 100644
--- a/llvm/test/DebugInfo/2010-05-03-OriginDIE.ll
+++ b/llvm/test/DebugInfo/2010-05-03-OriginDIE.ll
@@ -50,21 +50,21 @@ declare void @uuid_LtoB(i8*, i8*)
!llvm.dbg.cu = !{!4}
!llvm.module.flags = !{!41}
-!0 = !{i32 808, i32 0, !1, null}
+!0 = !MDLocation(line: 808, scope: !1)
!1 = !{!"0xb\00807\000\000", !39, !2} ; [ DW_TAG_lexical_block ]
!2 = !{!"0x2e\00gpt2gpm\00gpt2gpm\00gpt2gpm\00807\001\001\000\006\000\000\000", !39, null, !5, null, null, null, null, null} ; [ DW_TAG_subprogram ]
!3 = !{!"0x29", !39} ; [ DW_TAG_file_type ]
!4 = !{!"0x11\001\00llvm-gcc\001\00\000\00\000", !39, !18, !18, !40, null, null} ; [ DW_TAG_compile_unit ]
!5 = !{!"0x15\00\000\000\000\000\000\000", !39, !3, null, !6, null, null, null} ; [ DW_TAG_subroutine_type ] [line 0, size 0, align 0, offset 0] [from ]
!6 = !{null}
-!7 = !{i32 810, i32 0, !1, null}
+!7 = !MDLocation(line: 810, scope: !1)
!8 = !{!"0x101\00data\00201\000", !9, !10, !11} ; [ DW_TAG_arg_variable ]
!9 = !{!"0x2e\00_OSSwapInt64\00_OSSwapInt64\00_OSSwapInt64\00202\001\001\000\006\000\000\000", !10, null, !5, null, null, null, null, null} ; [ DW_TAG_subprogram ]
!10 = !{!"0x29", !"OSByteOrder.h", !"/usr/include/libkern/ppc", !4} ; [ DW_TAG_file_type ]
!11 = !{!"0x16\00uint64_t\0059\000\000\000\000", !36, !3, !13} ; [ DW_TAG_typedef ]
!12 = !{!"0x29", !"stdint.h", !"/usr/4.2.1/include", !4} ; [ DW_TAG_file_type ]
!13 = !{!"0x24\00long long unsigned int\000\0064\0064\000\000\007", !39, !3} ; [ DW_TAG_base_type ]
-!14 = !{i32 202, i32 0, !9, !7}
+!14 = !MDLocation(line: 202, scope: !9, inlinedAt: !7)
!15 = !{!"0x101\00base\0092\000", !16, !10, !17} ; [ DW_TAG_arg_variable ]
!16 = !{!"0x2e\00OSReadSwapInt64\00OSReadSwapInt64\00OSReadSwapInt64\0095\001\001\000\006\000\000\000", !38, null, !5, null, null, null, null, null} ; [ DW_TAG_subprogram ]
!17 = !{!"0xf\00\000\0032\0032\000\000", !39, !3, null} ; [ DW_TAG_pointer_type ]
diff --git a/llvm/test/DebugInfo/2010-05-10-MultipleCU.ll b/llvm/test/DebugInfo/2010-05-10-MultipleCU.ll
index 1789b18efcb..502007c8093 100644
--- a/llvm/test/DebugInfo/2010-05-10-MultipleCU.ll
+++ b/llvm/test/DebugInfo/2010-05-10-MultipleCU.ll
@@ -22,7 +22,7 @@ return:
!16 = !{!2}
!17 = !{!10}
-!0 = !{i32 3, i32 0, !1, null}
+!0 = !MDLocation(line: 3, scope: !1)
!1 = !{!"0xb\002\000\000", !18, !2} ; [ DW_TAG_lexical_block ]
!2 = !{!"0x2e\00foo\00foo\00foo\002\000\001\000\006\000\000\000", !18, !3, !5, null, i32 ()* @foo, null, null, null} ; [ DW_TAG_subprogram ]
!3 = !{!"0x29", !18} ; [ DW_TAG_file_type ]
@@ -30,7 +30,7 @@ return:
!5 = !{!"0x15\00\000\000\000\000\000\000", !18, !3, null, !6, null, null, null} ; [ DW_TAG_subroutine_type ] [line 0, size 0, align 0, offset 0] [from ]
!6 = !{!7}
!7 = !{!"0x24\00int\000\0032\0032\000\000\005", !18, !3} ; [ DW_TAG_base_type ]
-!8 = !{i32 3, i32 0, !9, null}
+!8 = !MDLocation(line: 3, scope: !9)
!9 = !{!"0xb\002\000\000", !20, !10} ; [ DW_TAG_lexical_block ]
!10 = !{!"0x2e\00bar\00bar\00bar\002\000\001\000\006\000\000\000", !20, !11, !13, null, i32 ()* @bar, null, null, null} ; [ DW_TAG_subprogram ]
!11 = !{!"0x29", !20} ; [ DW_TAG_file_type ]
diff --git a/llvm/test/DebugInfo/2010-06-29-InlinedFnLocalVar.ll b/llvm/test/DebugInfo/2010-06-29-InlinedFnLocalVar.ll
index a37385c95b4..9f0f7c37fcc 100644
--- a/llvm/test/DebugInfo/2010-06-29-InlinedFnLocalVar.ll
+++ b/llvm/test/DebugInfo/2010-06-29-InlinedFnLocalVar.ll
@@ -41,13 +41,13 @@ entry:
!14 = !{!"0xd\00a\0010\0032\0032\000\000", !27, !12, !5} ; [ DW_TAG_member ]
!15 = !{!"0xd\00b\0010\0032\0032\0032\000", !27, !12, !5} ; [ DW_TAG_member ]
!16 = !{!"0x34\00i\00i\00\005\000\001", !1, !1, !5, i32* @i, null} ; [ DW_TAG_variable ]
-!17 = !{i32 15, i32 0, !18, null}
+!17 = !MDLocation(line: 15, scope: !18)
!18 = !{!"0xb\0014\000\001", !1, !6} ; [ DW_TAG_lexical_block ]
-!19 = !{i32 9, i32 0, !0, !17}
+!19 = !MDLocation(line: 9, scope: !0, inlinedAt: !17)
!20 = !{}
-!21 = !{i32 9, i32 0, !11, !17}
-!22 = !{i32 11, i32 0, !11, !17}
-!23 = !{i32 16, i32 0, !18, null}
+!21 = !MDLocation(line: 9, scope: !11, inlinedAt: !17)
+!22 = !MDLocation(line: 11, scope: !11, inlinedAt: !17)
+!23 = !MDLocation(line: 16, scope: !18)
!24 = !{!9, !10}
!25 = !{!0, !6}
!26 = !{!16}
diff --git a/llvm/test/DebugInfo/2010-07-19-Crash.ll b/llvm/test/DebugInfo/2010-07-19-Crash.ll
index 0d8ba08f177..8bbe48c33e9 100644
--- a/llvm/test/DebugInfo/2010-07-19-Crash.ll
+++ b/llvm/test/DebugInfo/2010-07-19-Crash.ll
@@ -21,7 +21,7 @@ entry:
!6 = !{!"0x2e\00foo\00foo\00foo\007\001\001\000\006\000\001\000", !12, !1, !3, null, null, null, null, null} ; [ DW_TAG_subprogram ]
!7 = !{!"0x100\00one\008\000", !8, !1, !5} ; [ DW_TAG_auto_variable ]
!8 = !{!"0xb\007\0018\000", !12, !6} ; [ DW_TAG_lexical_block ]
-!9 = !{i32 4, i32 3, !10, null}
+!9 = !MDLocation(line: 4, column: 3, scope: !10)
!10 = !{!"0xb\003\0011\000", !12, !0} ; [ DW_TAG_lexical_block ]
!11 = !{!"0x2e\00foo\00foo\00foo\007\001\000\000\006\000\001\000", !12, !1, !3, null, null, null, null, null} ; [ DW_TAG_subprogram ]
!12 = !{!"one.c", !"/private/tmp"}
diff --git a/llvm/test/DebugInfo/2010-10-01-crash.ll b/llvm/test/DebugInfo/2010-10-01-crash.ll
index 161df5d3e28..5c822e94bec 100644
--- a/llvm/test/DebugInfo/2010-10-01-crash.ll
+++ b/llvm/test/DebugInfo/2010-10-01-crash.ll
@@ -20,7 +20,7 @@ declare void @llvm.memcpy.p0i8.p0i8.i32(i8* nocapture, i8* nocapture, i32, i32,
!2 = !{!"0x11\0016\00clang version 2.9 (trunk 115292)\001\00\001\00\000", !25, !26, !26, null, null, null} ; [ DW_TAG_compile_unit ]
!5 = !{!"0x16\00CGRect\0049\000\000\000\000", !25, null, null} ; [ DW_TAG_typedef ]
!23 = !{!"0x101\00rect\0053\000", !0, !1, !5} ; [ DW_TAG_arg_variable ]
-!24 = !{i32 53, i32 33, !0, null}
+!24 = !MDLocation(line: 53, column: 33, scope: !0)
!25 = !{!"GSFusedSilica.m", !"/Volumes/Data/Users/sabre/Desktop"}
!26 = !{i32 0}
!27 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/AArch64/cfi-eof-prologue.ll b/llvm/test/DebugInfo/AArch64/cfi-eof-prologue.ll
index 65d60e2d094..2d68af629e3 100644
--- a/llvm/test/DebugInfo/AArch64/cfi-eof-prologue.ll
+++ b/llvm/test/DebugInfo/AArch64/cfi-eof-prologue.ll
@@ -100,13 +100,13 @@ attributes #3 = { nounwind }
!36 = !{i32 2, !"Debug Info Version", i32 2}
!37 = !{!"clang version 3.6.0 (trunk 224279) (llvm/trunk 224283)"}
!38 = !{!"0x102"} ; [ DW_TAG_expression ]
-!39 = !{i32 0, i32 0, !28, null}
-!40 = !{i32 9, i32 0, !28, null}
+!39 = !MDLocation(line: 0, scope: !28)
+!40 = !MDLocation(line: 9, scope: !28)
!41 = !{!42, !42, i64 0}
!42 = !{!"vtable pointer", !43, i64 0}
!43 = !{!"Simple C/C++ TBAA"}
-!44 = !{i32 0, i32 0, !32, null}
+!44 = !MDLocation(line: 0, scope: !32)
!45 = !{!"0x101\00this\0016777216\001088", !28, null, !31, !46} ; [ DW_TAG_arg_variable ] [this] [line 0]
-!46 = !{i32 9, i32 0, !32, null}
-!47 = !{i32 0, i32 0, !28, !46}
-!48 = !{i32 9, i32 0, !28, !46}
+!46 = !MDLocation(line: 9, scope: !32)
+!47 = !MDLocation(line: 0, scope: !28, inlinedAt: !46)
+!48 = !MDLocation(line: 9, scope: !28, inlinedAt: !46)
diff --git a/llvm/test/DebugInfo/AArch64/coalescing.ll b/llvm/test/DebugInfo/AArch64/coalescing.ll
index b8e1694dc9e..35bb04138c1 100644
--- a/llvm/test/DebugInfo/AArch64/coalescing.ll
+++ b/llvm/test/DebugInfo/AArch64/coalescing.ll
@@ -59,7 +59,7 @@ attributes #3 = { nounwind optsize }
!12 = !{i32 2, !"Dwarf Version", i32 2}
!13 = !{i32 2, !"Debug Info Version", i32 2}
!14 = !{!"clang version 3.6.0 (trunk 223149) (llvm/trunk 223115)"}
-!15 = !{i32 5, i32 3, !4, null}
+!15 = !MDLocation(line: 5, column: 3, scope: !4)
!16 = !{!"0x102"} ; [ DW_TAG_expression ]
-!17 = !{i32 4, i32 12, !4, null}
-!18 = !{i32 8, i32 1, !4, null}
+!17 = !MDLocation(line: 4, column: 12, scope: !4)
+!18 = !MDLocation(line: 8, column: 1, scope: !4)
diff --git a/llvm/test/DebugInfo/AArch64/dwarfdump.ll b/llvm/test/DebugInfo/AArch64/dwarfdump.ll
index 049428149da..cba18b2b23b 100644
--- a/llvm/test/DebugInfo/AArch64/dwarfdump.ll
+++ b/llvm/test/DebugInfo/AArch64/dwarfdump.ll
@@ -35,6 +35,6 @@ attributes #0 = { nounwind }
!5 = !{!"0x15\00\000\000\000\000\000\000", null, null, null, !6, null, null, null} ; [ DW_TAG_subroutine_type ] [line 0, size 0, align 0, offset 0] [from ]
!6 = !{!7}
!7 = !{!"0x24\00int\000\0032\0032\000\000\005", null, null} ; [ DW_TAG_base_type ] [int] [line 0, size 32, align 32, offset 0, enc DW_ATE_signed]
-!8 = !{i32 2, i32 0, !3, null}
+!8 = !MDLocation(line: 2, scope: !3)
!9 = !{!"tmp.c", !"/home/tim/llvm/build"}
!10 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/AArch64/struct_by_value.ll b/llvm/test/DebugInfo/AArch64/struct_by_value.ll
index b6b636feb64..f66f56cef5b 100644
--- a/llvm/test/DebugInfo/AArch64/struct_by_value.ll
+++ b/llvm/test/DebugInfo/AArch64/struct_by_value.ll
@@ -65,6 +65,6 @@ attributes #1 = { nounwind readnone }
!15 = !{!"0xd\00e\007\0032\0032\00128\000", !1, !9, !8} ; [ DW_TAG_member ] [e] [line 7, size 32, align 32, offset 128] [from int]
!16 = !{i32 2, !"Dwarf Version", i32 2}
!17 = !{!"0x101\00f\0016777229\008192", !4, !5, !9} ; [ DW_TAG_arg_variable ] [f] [line 13]
-!18 = !{i32 13, i32 0, !4, null}
-!19 = !{i32 16, i32 0, !4, null}
+!18 = !MDLocation(line: 13, scope: !4)
+!19 = !MDLocation(line: 16, scope: !4)
!20 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/ARM/PR16736.ll b/llvm/test/DebugInfo/ARM/PR16736.ll
index ef7829a442f..7c99ae20dc6 100644
--- a/llvm/test/DebugInfo/ARM/PR16736.ll
+++ b/llvm/test/DebugInfo/ARM/PR16736.ll
@@ -59,7 +59,7 @@ attributes #3 = { nounwind }
!15 = !{!"0x101\00\0067108867\000", !4, !6, !9} ; [ DW_TAG_arg_variable ] [line 3]
!16 = !{!"0x101\00x\0083886083\000", !4, !6, !10} ; [ DW_TAG_arg_variable ] [x] [line 3]
!17 = !{i32 2, !"Dwarf Version", i32 4}
-!18 = !{i32 3, i32 0, !4, null}
-!19 = !{i32 4, i32 0, !4, null}
-!20 = !{i32 5, i32 0, !4, null}
+!18 = !MDLocation(line: 3, scope: !4)
+!19 = !MDLocation(line: 4, scope: !4)
+!20 = !MDLocation(line: 5, scope: !4)
!21 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/ARM/cfi-eof-prologue.ll b/llvm/test/DebugInfo/ARM/cfi-eof-prologue.ll
index bbd93c94132..599806bf707 100644
--- a/llvm/test/DebugInfo/ARM/cfi-eof-prologue.ll
+++ b/llvm/test/DebugInfo/ARM/cfi-eof-prologue.ll
@@ -103,13 +103,13 @@ attributes #3 = { nounwind }
!38 = !{i32 1, !"min_enum_size", i32 4}
!39 = !{!"clang version 3.6.0 (trunk 224279) (llvm/trunk 224283)"}
!40 = !{!"0x102"} ; [ DW_TAG_expression ]
-!41 = !{i32 0, i32 0, !28, null}
-!42 = !{i32 9, i32 0, !28, null}
+!41 = !MDLocation(line: 0, scope: !28)
+!42 = !MDLocation(line: 9, scope: !28)
!43 = !{!44, !44, i64 0}
!44 = !{!"vtable pointer", !45, i64 0}
!45 = !{!"Simple C/C++ TBAA"}
-!46 = !{i32 0, i32 0, !32, null}
+!46 = !MDLocation(line: 0, scope: !32)
!47 = !{!"0x101\00this\0016777216\001088", !28, null, !31, !48} ; [ DW_TAG_arg_variable ] [this] [line 0]
-!48 = !{i32 9, i32 0, !32, null}
-!49 = !{i32 0, i32 0, !28, !48}
-!50 = !{i32 9, i32 0, !28, !48}
+!48 = !MDLocation(line: 9, scope: !32)
+!49 = !MDLocation(line: 0, scope: !28, inlinedAt: !48)
+!50 = !MDLocation(line: 9, scope: !28, inlinedAt: !48)
diff --git a/llvm/test/DebugInfo/ARM/lowerbdgdeclare_vla.ll b/llvm/test/DebugInfo/ARM/lowerbdgdeclare_vla.ll
index dab14ef2ad8..2e137678e0e 100644
--- a/llvm/test/DebugInfo/ARM/lowerbdgdeclare_vla.ll
+++ b/llvm/test/DebugInfo/ARM/lowerbdgdeclare_vla.ll
@@ -89,15 +89,15 @@ attributes #1 = { nounwind readnone }
!19 = !{!"0xb\006\000\000", !5, !4} ; [ DW_TAG_lexical_block ] [/Volumes/Data/radar/15464571/test.c]
!20 = !{i32 2, !"Dwarf Version", i32 2}
!21 = !{!"clang version 3.4 "}
-!22 = !{i32 1, i32 0, !4, null}
-!23 = !{i32 3, i32 0, !4, null}
-!24 = !{i32 4, i32 0, !4, null}
-!25 = !{i32 5, i32 0, !4, null}
+!22 = !MDLocation(line: 1, scope: !4)
+!23 = !MDLocation(line: 3, scope: !4)
+!24 = !MDLocation(line: 4, scope: !4)
+!25 = !MDLocation(line: 5, scope: !4)
!26 = !{!27, !27, i64 0}
!27 = !{!"float", !28, i64 0}
!28 = !{!"omnipotent char", !29, i64 0}
!29 = !{!"Simple C/C++ TBAA"}
-!30 = !{i32 6, i32 0, !19, null}
-!31 = !{i32 7, i32 0, !19, null}
-!32 = !{i32 8, i32 0, !4, null}
+!30 = !MDLocation(line: 6, scope: !19)
+!31 = !MDLocation(line: 7, scope: !19)
+!32 = !MDLocation(line: 8, scope: !4)
!33 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/ARM/s-super-register.ll b/llvm/test/DebugInfo/ARM/s-super-register.ll
index fddd63226ea..62a315e508a 100644
--- a/llvm/test/DebugInfo/ARM/s-super-register.ll
+++ b/llvm/test/DebugInfo/ARM/s-super-register.ll
@@ -51,11 +51,11 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
!8 = !{!"0x100\00y\008\000", !9, !2, !7} ; [ DW_TAG_auto_variable ]
!9 = !{!"0xb\007\0025\002", !18, !10} ; [ DW_TAG_lexical_block ]
!10 = !{!"0xb\007\003\001", !18, !6} ; [ DW_TAG_lexical_block ]
-!11 = !{i32 6, i32 18, !6, null}
-!12 = !{i32 7, i32 3, !6, null}
-!13 = !{i32 8, i32 20, !9, null}
-!14 = !{i32 7, i32 20, !10, null}
-!15 = !{i32 10, i32 1, !6, null}
+!11 = !MDLocation(line: 6, column: 18, scope: !6)
+!12 = !MDLocation(line: 7, column: 3, scope: !6)
+!13 = !MDLocation(line: 8, column: 20, scope: !9)
+!14 = !MDLocation(line: 7, column: 20, scope: !10)
+!15 = !MDLocation(line: 10, column: 1, scope: !6)
!16 = !{!1}
!17 = !{!5, !8}
!18 = !{!"k.cc", !"/private/tmp"}
diff --git a/llvm/test/DebugInfo/COFF/asan-module-ctor.ll b/llvm/test/DebugInfo/COFF/asan-module-ctor.ll
index 02c2a5810dd..e2c7aef750a 100644
--- a/llvm/test/DebugInfo/COFF/asan-module-ctor.ll
+++ b/llvm/test/DebugInfo/COFF/asan-module-ctor.ll
@@ -91,4 +91,4 @@ attributes #0 = { nounwind sanitize_address "less-precise-fpmad"="false" "no-fra
!7 = !{i32 2, !"Dwarf Version", i32 4}
!8 = !{i32 1, !"Debug Info Version", i32 2}
!9 = !{!"clang version 3.5.0 "}
-!10 = !{i32 2, i32 0, !4, null}
+!10 = !MDLocation(line: 2, scope: !4)
diff --git a/llvm/test/DebugInfo/COFF/asm.ll b/llvm/test/DebugInfo/COFF/asm.ll
index da24b4ed5e5..44ee4f9ce4f 100644
--- a/llvm/test/DebugInfo/COFF/asm.ll
+++ b/llvm/test/DebugInfo/COFF/asm.ll
@@ -251,6 +251,6 @@ attributes #2 = { nounwind }
!9 = !{i32 2, !"Dwarf Version", i32 4}
!10 = !{i32 1, !"Debug Info Version", i32 2}
!11 = !{!"clang version 3.5 "}
-!12 = !{i32 4, i32 0, !4, null}
-!13 = !{i32 5, i32 0, !4, null}
-!14 = !{i32 6, i32 0, !4, null}
+!12 = !MDLocation(line: 4, scope: !4)
+!13 = !MDLocation(line: 5, scope: !4)
+!14 = !MDLocation(line: 6, scope: !4)
diff --git a/llvm/test/DebugInfo/COFF/cpp-mangling.ll b/llvm/test/DebugInfo/COFF/cpp-mangling.ll
index 92e39f92fc3..73c8e1594e6 100644
--- a/llvm/test/DebugInfo/COFF/cpp-mangling.ll
+++ b/llvm/test/DebugInfo/COFF/cpp-mangling.ll
@@ -40,4 +40,4 @@ attributes #0 = { nounwind "less-precise-fpmad"="false" "no-frame-pointer-elim"=
!8 = !{i32 2, !"Dwarf Version", i32 4}
!9 = !{i32 2, !"Debug Info Version", i32 2}
!10 = !{!"clang version 3.6.0 "}
-!11 = !{i32 3, i32 0, !4, null}
+!11 = !MDLocation(line: 3, scope: !4)
diff --git a/llvm/test/DebugInfo/COFF/multifile.ll b/llvm/test/DebugInfo/COFF/multifile.ll
index 9b0efb7ff16..5cdd6dc2e51 100644
--- a/llvm/test/DebugInfo/COFF/multifile.ll
+++ b/llvm/test/DebugInfo/COFF/multifile.ll
@@ -319,11 +319,11 @@ attributes #1 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="false" "
!9 = !{i32 2, !"Dwarf Version", i32 4}
!10 = !{i32 1, !"Debug Info Version", i32 2}
!11 = !{!"clang version 3.5 "}
-!12 = !{i32 1, i32 0, !13, null}
+!12 = !MDLocation(line: 1, scope: !13)
!13 = !{!"0xb\000", !14, !4} ; [ DW_TAG_lexical_block ] [D:\/one.c]
!14 = !{!"one.c", !"D:\5C"}
-!15 = !{i32 2, i32 0, !16, null}
+!15 = !MDLocation(line: 2, scope: !16)
!16 = !{!"0xb\000", !17, !4} ; [ DW_TAG_lexical_block ] [D:\/two.c]
!17 = !{!"two.c", !"D:\5C"}
-!18 = !{i32 7, i32 0, !13, null}
-!19 = !{i32 8, i32 0, !13, null}
+!18 = !MDLocation(line: 7, scope: !13)
+!19 = !MDLocation(line: 8, scope: !13)
diff --git a/llvm/test/DebugInfo/COFF/multifunction.ll b/llvm/test/DebugInfo/COFF/multifunction.ll
index 4649270274c..8f9a3f8b9b7 100644
--- a/llvm/test/DebugInfo/COFF/multifunction.ll
+++ b/llvm/test/DebugInfo/COFF/multifunction.ll
@@ -596,11 +596,11 @@ attributes #1 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="false" "
!11 = !{i32 2, !"Dwarf Version", i32 4}
!12 = !{i32 1, !"Debug Info Version", i32 2}
!13 = !{!"clang version 3.5 "}
-!14 = !{i32 4, i32 0, !4, null}
-!15 = !{i32 5, i32 0, !4, null}
-!16 = !{i32 8, i32 0, !9, null}
-!17 = !{i32 9, i32 0, !9, null}
-!18 = !{i32 12, i32 0, !10, null}
-!19 = !{i32 13, i32 0, !10, null}
-!20 = !{i32 14, i32 0, !10, null}
-!21 = !{i32 15, i32 0, !10, null}
+!14 = !MDLocation(line: 4, scope: !4)
+!15 = !MDLocation(line: 5, scope: !4)
+!16 = !MDLocation(line: 8, scope: !9)
+!17 = !MDLocation(line: 9, scope: !9)
+!18 = !MDLocation(line: 12, scope: !10)
+!19 = !MDLocation(line: 13, scope: !10)
+!20 = !MDLocation(line: 14, scope: !10)
+!21 = !MDLocation(line: 15, scope: !10)
diff --git a/llvm/test/DebugInfo/COFF/simple.ll b/llvm/test/DebugInfo/COFF/simple.ll
index b84df8eaf79..bcb8a695c7f 100644
--- a/llvm/test/DebugInfo/COFF/simple.ll
+++ b/llvm/test/DebugInfo/COFF/simple.ll
@@ -235,5 +235,5 @@ attributes #1 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="false" "
!9 = !{i32 2, !"Dwarf Version", i32 4}
!10 = !{i32 1, !"Debug Info Version", i32 2}
!11 = !{!"clang version 3.5 "}
-!12 = !{i32 4, i32 0, !4, null}
-!13 = !{i32 5, i32 0, !4, null}
+!12 = !MDLocation(line: 4, scope: !4)
+!13 = !MDLocation(line: 5, scope: !4)
diff --git a/llvm/test/DebugInfo/COFF/tail-call-without-lexical-scopes.ll b/llvm/test/DebugInfo/COFF/tail-call-without-lexical-scopes.ll
index a32164e3ac5..181359b905a 100644
--- a/llvm/test/DebugInfo/COFF/tail-call-without-lexical-scopes.ll
+++ b/llvm/test/DebugInfo/COFF/tail-call-without-lexical-scopes.ll
@@ -72,7 +72,7 @@ attributes #2 = { nounwind }
!8 = !{i32 2, !"Dwarf Version", i32 4}
!9 = !{i32 1, !"Debug Info Version", i32 2}
!10 = !{!"clang version 3.5.0 "}
-!11 = !{i32 8, i32 0, !4, null}
-!12 = !{i32 9, i32 0, !4, null}
-!13 = !{i32 4, i32 0, !7, null}
-!14 = !{i32 5, i32 0, !7, null}
+!11 = !MDLocation(line: 8, scope: !4)
+!12 = !MDLocation(line: 9, scope: !4)
+!13 = !MDLocation(line: 4, scope: !7)
+!14 = !MDLocation(line: 5, scope: !7)
diff --git a/llvm/test/DebugInfo/Inputs/gmlt.ll b/llvm/test/DebugInfo/Inputs/gmlt.ll
index d5002eca50e..e43264010bf 100644
--- a/llvm/test/DebugInfo/Inputs/gmlt.ll
+++ b/llvm/test/DebugInfo/Inputs/gmlt.ll
@@ -144,10 +144,10 @@ attributes #2 = { nounwind }
!10 = !{i32 2, !"Dwarf Version", i32 4}
!11 = !{i32 2, !"Debug Info Version", i32 2}
!12 = !{!"clang version 3.6.0 "}
-!13 = !{i32 1, i32 12, !4, null}
-!14 = !{i32 2, i32 53, !7, null}
-!15 = !{i32 3, i32 44, !8, null}
-!16 = !{i32 3, i32 50, !8, null}
-!17 = !{i32 3, i32 44, !8, !18}
-!18 = !{i32 4, i32 13, !9, null}
-!19 = !{i32 4, i32 19, !9, null}
+!13 = !MDLocation(line: 1, column: 12, scope: !4)
+!14 = !MDLocation(line: 2, column: 53, scope: !7)
+!15 = !MDLocation(line: 3, column: 44, scope: !8)
+!16 = !MDLocation(line: 3, column: 50, scope: !8)
+!17 = !MDLocation(line: 3, column: 44, scope: !8, inlinedAt: !18)
+!18 = !MDLocation(line: 4, column: 13, scope: !9)
+!19 = !MDLocation(line: 4, column: 19, scope: !9)
diff --git a/llvm/test/DebugInfo/Mips/delay-slot.ll b/llvm/test/DebugInfo/Mips/delay-slot.ll
index bdf1fb22434..d860cea3210 100644
--- a/llvm/test/DebugInfo/Mips/delay-slot.ll
+++ b/llvm/test/DebugInfo/Mips/delay-slot.ll
@@ -67,9 +67,9 @@ attributes #1 = { nounwind readnone }
!10 = !{i32 2, !"Debug Info Version", i32 2}
!11 = !{!"clang version 3.5.0"}
!12 = !{!"0x101\00x\0016777217\000", !4, !5, !8} ; [ DW_TAG_arg_variable ] [x] [line 1]
-!13 = !{i32 1, i32 0, !4, null}
-!14 = !{i32 2, i32 0, !15, null}
+!13 = !MDLocation(line: 1, scope: !4)
+!14 = !MDLocation(line: 2, scope: !15)
!15 = !{!"0xb\002\000\000", !1, !4} ; [ DW_TAG_lexical_block ] [/tmp/test.c]
-!16 = !{i32 3, i32 0, !15, null}
-!17 = !{i32 4, i32 0, !4, null}
-!18 = !{i32 5, i32 0, !4, null}
+!16 = !MDLocation(line: 3, scope: !15)
+!17 = !MDLocation(line: 4, scope: !4)
+!18 = !MDLocation(line: 5, scope: !4)
diff --git a/llvm/test/DebugInfo/PR20038.ll b/llvm/test/DebugInfo/PR20038.ll
index e545fce40f0..bfee8d2b438 100644
--- a/llvm/test/DebugInfo/PR20038.ll
+++ b/llvm/test/DebugInfo/PR20038.ll
@@ -141,24 +141,24 @@ attributes #2 = { nounwind readnone }
!18 = !{i32 2, !"Dwarf Version", i32 4}
!19 = !{i32 2, !"Debug Info Version", i32 2}
!20 = !{!"clang version 3.5.0 "}
-!21 = !{i32 6, i32 0, !17, !22}
-!22 = !{i32 5, i32 0, !23, null}
+!21 = !MDLocation(line: 6, scope: !17, inlinedAt: !22)
+!22 = !MDLocation(line: 5, scope: !23)
!23 = !{!"0xb\005\000\003", !5, !12} ; [ DW_TAG_lexical_block ] [/tmp/dbginfo/PR20038.cpp]
-!24 = !{i32 5, i32 0, !12, null}
-!25 = !{i32 5, i32 0, !26, null}
+!24 = !MDLocation(line: 5, scope: !12)
+!25 = !MDLocation(line: 5, scope: !26)
!26 = !{!"0xb\005\000\001", !5, !12} ; [ DW_TAG_lexical_block ] [/tmp/dbginfo/PR20038.cpp]
-!27 = !{i32 5, i32 0, !28, null}
+!27 = !MDLocation(line: 5, scope: !28)
!28 = !{!"0xb\005\000\002", !5, !12} ; [ DW_TAG_lexical_block ] [/tmp/dbginfo/PR20038.cpp]
!29 = !{!"0x101\00this\0016777216\001088", !17, null, !30} ; [ DW_TAG_arg_variable ] [this] [line 0]
!30 = !{!"0xf\00\000\0064\0064\000\000", null, null, !"_ZTS1C"} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from _ZTS1C]
-!31 = !{i32 0, i32 0, !17, !22}
+!31 = !MDLocation(line: 0, scope: !17, inlinedAt: !22)
!32 = !{!"0x101\00this\0016777216\001088", !16, null, !30} ; [ DW_TAG_arg_variable ] [this] [line 0]
-!33 = !{i32 0, i32 0, !16, !21}
-!34 = !{i32 5, i32 0, !35, null}
+!33 = !MDLocation(line: 0, scope: !16, inlinedAt: !21)
+!34 = !MDLocation(line: 5, scope: !35)
!35 = !{!"0xb\005\000\005", !5, !36} ; [ DW_TAG_lexical_block ] [/tmp/dbginfo/PR20038.cpp]
!36 = !{!"0xb\005\000\004", !5, !12} ; [ DW_TAG_lexical_block ] [/tmp/dbginfo/PR20038.cpp]
-!37 = !{i32 6, i32 0, !17, null}
-!38 = !{i32 0, i32 0, !17, null}
-!39 = !{i32 0, i32 0, !16, !37}
-!40 = !{i32 0, i32 0, !16, null}
-!41 = !{i32 6, i32 0, !16, null}
+!37 = !MDLocation(line: 6, scope: !17)
+!38 = !MDLocation(line: 0, scope: !17)
+!39 = !MDLocation(line: 0, scope: !16, inlinedAt: !37)
+!40 = !MDLocation(line: 0, scope: !16)
+!41 = !MDLocation(line: 6, scope: !16)
diff --git a/llvm/test/DebugInfo/Sparc/gnu-window-save.ll b/llvm/test/DebugInfo/Sparc/gnu-window-save.ll
index 9c182134bbb..5bf3f02538d 100644
--- a/llvm/test/DebugInfo/Sparc/gnu-window-save.ll
+++ b/llvm/test/DebugInfo/Sparc/gnu-window-save.ll
@@ -67,5 +67,5 @@ attributes #1 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n
!9 = !{i32 2, !"Dwarf Version", i32 4}
!10 = !{i32 1, !"Debug Info Version", i32 2}
!11 = !{!"clang version 3.5 (http://llvm.org/git/clang.git 6a0714fee07fb7c4e32d3972b4fe2ce2f5678cf4) (llvm/ 672e88e934757f76d5c5e5258be41e7615094844)"}
-!12 = !{i32 5, i32 0, !4, null}
-!13 = !{i32 6, i32 0, !4, null}
+!12 = !MDLocation(line: 5, scope: !4)
+!13 = !MDLocation(line: 6, scope: !4)
diff --git a/llvm/test/DebugInfo/SystemZ/variable-loc.ll b/llvm/test/DebugInfo/SystemZ/variable-loc.ll
index ca9edc5e8ac..9e5c6a9e7e6 100644
--- a/llvm/test/DebugInfo/SystemZ/variable-loc.ll
+++ b/llvm/test/DebugInfo/SystemZ/variable-loc.ll
@@ -71,12 +71,12 @@ declare i32 @printf(i8*, ...)
!18 = !{!"0xb\0018\0016\004", !29, !14} ; [ DW_TAG_lexical_block ] [/home/timnor01/a64-trunk/build/simple.c]
!19 = !{!"0x1\00\000\003200\0032\000\000", null, null, !10, !20, i32 0, null, null, null} ; [ DW_TAG_array_type ] [line 0, size 3200, align 32, offset 0] [from int]
!20 = !{!"0x21\000\0099"} ; [ DW_TAG_subrange_type ] [0, 99]
-!22 = !{i32 19, i32 7, !18, null}
+!22 = !MDLocation(line: 19, column: 7, scope: !18)
!23 = !{!"0x100\00val\0020\000", !18, !6, !10} ; [ DW_TAG_auto_variable ] [val] [line 20]
-!24 = !{i32 20, i32 7, !18, null}
-!25 = !{i32 22, i32 3, !18, null}
-!26 = !{i32 23, i32 9, !18, null}
-!27 = !{i32 24, i32 3, !18, null}
-!28 = !{i32 26, i32 3, !18, null}
+!24 = !MDLocation(line: 20, column: 7, scope: !18)
+!25 = !MDLocation(line: 22, column: 3, scope: !18)
+!26 = !MDLocation(line: 23, column: 9, scope: !18)
+!27 = !MDLocation(line: 24, column: 3, scope: !18)
+!28 = !MDLocation(line: 26, column: 3, scope: !18)
!29 = !{!"simple.c", !"/home/timnor01/a64-trunk/build"}
!30 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/2010-04-13-PubType.ll b/llvm/test/DebugInfo/X86/2010-04-13-PubType.ll
index f7071a8d1d6..0aec0361b88 100644
--- a/llvm/test/DebugInfo/X86/2010-04-13-PubType.ll
+++ b/llvm/test/DebugInfo/X86/2010-04-13-PubType.ll
@@ -44,9 +44,9 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
!10 = !{!"0x13\00Y\004\0032\0032\000\000\000", !18, !2, null, !11, null, null, null} ; [ DW_TAG_structure_type ] [Y] [line 4, size 32, align 32, offset 0] [def] [from ]
!11 = !{!12}
!12 = !{!"0xd\00x\005\0032\0032\000\000", !18, !10, !6} ; [ DW_TAG_member ]
-!13 = !{i32 7, i32 0, !1, null}
+!13 = !MDLocation(line: 7, scope: !1)
!14 = !{!"0x101\00y\007\000", !1, !2, !9} ; [ DW_TAG_arg_variable ]
-!15 = !{i32 7, i32 0, !16, null}
+!15 = !MDLocation(line: 7, scope: !16)
!16 = !{!"0xb\007\000\000", !18, !1} ; [ DW_TAG_lexical_block ]
!17 = !{!1}
!18 = !{!"a.c", !"/tmp/"}
diff --git a/llvm/test/DebugInfo/X86/2010-08-10-DbgConstant.ll b/llvm/test/DebugInfo/X86/2010-08-10-DbgConstant.ll
index a876b3eef78..bcaac896f1a 100644
--- a/llvm/test/DebugInfo/X86/2010-08-10-DbgConstant.ll
+++ b/llvm/test/DebugInfo/X86/2010-08-10-DbgConstant.ll
@@ -22,7 +22,7 @@ declare void @bar(i32)
!5 = !{!"0x27\00ro\00ro\00ro\001\001\001", !1, !1, !6, i32 201, null} ; [ DW_TAG_constant ]
!6 = !{!"0x26\00\000\000\000\000\000", !12, !1, !7} ; [ DW_TAG_const_type ]
!7 = !{!"0x24\00unsigned int\000\0032\0032\000\000\007", !12, !1} ; [ DW_TAG_base_type ]
-!8 = !{i32 3, i32 14, !9, null}
+!8 = !MDLocation(line: 3, column: 14, scope: !9)
!9 = !{!"0xb\003\0012\000", !12, !0} ; [ DW_TAG_lexical_block ]
!10 = !{!0}
!11 = !{!5}
diff --git a/llvm/test/DebugInfo/X86/2011-09-26-GlobalVarContext.ll b/llvm/test/DebugInfo/X86/2011-09-26-GlobalVarContext.ll
index a47afddcff9..d1beadcbb0a 100644
--- a/llvm/test/DebugInfo/X86/2011-09-26-GlobalVarContext.ll
+++ b/llvm/test/DebugInfo/X86/2011-09-26-GlobalVarContext.ll
@@ -31,9 +31,9 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
!14 = !{!"0x34\00GLB\00GLB\00\001\000\001", null, !6, !9, i32* @GLB, null} ; [ DW_TAG_variable ]
!15 = !{!"0x100\00LOC\004\000", !16, !6, !9} ; [ DW_TAG_auto_variable ]
!16 = !{!"0xb\003\009\000", !20, !5} ; [ DW_TAG_lexical_block ]
-!17 = !{i32 4, i32 9, !16, null}
-!18 = !{i32 4, i32 23, !16, null}
-!19 = !{i32 5, i32 5, !16, null}
+!17 = !MDLocation(line: 4, column: 9, scope: !16)
+!18 = !MDLocation(line: 4, column: 23, scope: !16)
+!19 = !MDLocation(line: 5, column: 5, scope: !16)
!20 = !{!"test.c", !"/work/llvm/vanilla/test/DebugInfo"}
; CHECK: DW_TAG_variable
diff --git a/llvm/test/DebugInfo/X86/2011-12-16-BadStructRef.ll b/llvm/test/DebugInfo/X86/2011-12-16-BadStructRef.ll
index 0ed4e327249..4880fa49fc5 100644
--- a/llvm/test/DebugInfo/X86/2011-12-16-BadStructRef.ll
+++ b/llvm/test/DebugInfo/X86/2011-12-16-BadStructRef.ll
@@ -130,37 +130,37 @@ entry:
!45 = !{!"0x24"} ; [ DW_TAG_base_type ]
!46 = !{!"0x2e\00baz\00baz\00_ZN3bazC2Ei\006\000\001\000\006\00256\000\000", !82, null, !14, null, void (%struct.baz*, i32)* @_ZN3bazC2Ei, null, !13, null} ; [ DW_TAG_subprogram ] [line 6] [def] [scope 0] [baz]
!49 = !{!"0x101\00argc\0016777232\000", !29, !6, !12} ; [ DW_TAG_arg_variable ]
-!50 = !{i32 16, i32 14, !29, null}
+!50 = !MDLocation(line: 16, column: 14, scope: !29)
!51 = !{!"0x101\00argv\0033554448\000", !29, !6, !32} ; [ DW_TAG_arg_variable ]
-!52 = !{i32 16, i32 27, !29, null}
+!52 = !MDLocation(line: 16, column: 27, scope: !29)
!53 = !{!"0x100\00myBar\0018\000", !54, !6, !5} ; [ DW_TAG_auto_variable ]
!54 = !{!"0xb\0017\001\000", !82, !29} ; [ DW_TAG_lexical_block ]
-!55 = !{i32 18, i32 9, !54, null}
-!56 = !{i32 18, i32 17, !54, null}
-!57 = !{i32 19, i32 5, !54, null}
+!55 = !MDLocation(line: 18, column: 9, scope: !54)
+!56 = !MDLocation(line: 18, column: 17, scope: !54)
+!57 = !MDLocation(line: 19, column: 5, scope: !54)
!58 = !{!"0x101\00this\0016777229\0064", !37, !6, !24} ; [ DW_TAG_arg_variable ]
-!59 = !{i32 13, i32 5, !37, null}
+!59 = !MDLocation(line: 13, column: 5, scope: !37)
!60 = !{!"0x101\00x\0033554445\000", !37, !6, !12} ; [ DW_TAG_arg_variable ]
-!61 = !{i32 13, i32 13, !37, null}
-!62 = !{i32 13, i32 34, !37, null}
+!61 = !MDLocation(line: 13, column: 13, scope: !37)
+!62 = !MDLocation(line: 13, column: 34, scope: !37)
!63 = !{!"0x101\00this\0016777229\0064", !40, !6, !24} ; [ DW_TAG_arg_variable ]
-!64 = !{i32 13, i32 5, !40, null}
+!64 = !MDLocation(line: 13, column: 5, scope: !40)
!65 = !{!"0x101\00x\0033554445\000", !40, !6, !12} ; [ DW_TAG_arg_variable ]
-!66 = !{i32 13, i32 13, !40, null}
-!67 = !{i32 13, i32 33, !40, null}
-!68 = !{i32 13, i32 34, !69, null}
+!66 = !MDLocation(line: 13, column: 13, scope: !40)
+!67 = !MDLocation(line: 13, column: 33, scope: !40)
+!68 = !MDLocation(line: 13, column: 34, scope: !69)
!69 = !{!"0xb\0013\0033\001", !82, !40} ; [ DW_TAG_lexical_block ]
!70 = !{!"0x101\00this\0016777222\0064", !43, !6, !16} ; [ DW_TAG_arg_variable ]
-!71 = !{i32 6, i32 5, !43, null}
+!71 = !MDLocation(line: 6, column: 5, scope: !43)
!72 = !{!"0x101\00a\0033554438\000", !43, !6, !12} ; [ DW_TAG_arg_variable ]
-!73 = !{i32 6, i32 13, !43, null}
-!74 = !{i32 6, i32 24, !43, null}
+!73 = !MDLocation(line: 6, column: 13, scope: !43)
+!74 = !MDLocation(line: 6, column: 24, scope: !43)
!75 = !{!"0x101\00this\0016777222\0064", !46, !6, !16} ; [ DW_TAG_arg_variable ]
-!76 = !{i32 6, i32 5, !46, null}
+!76 = !MDLocation(line: 6, column: 5, scope: !46)
!77 = !{!"0x101\00a\0033554438\000", !46, !6, !12} ; [ DW_TAG_arg_variable ]
-!78 = !{i32 6, i32 13, !46, null}
-!79 = !{i32 6, i32 23, !46, null}
-!80 = !{i32 6, i32 24, !81, null}
+!78 = !MDLocation(line: 6, column: 13, scope: !46)
+!79 = !MDLocation(line: 6, column: 23, scope: !46)
+!80 = !MDLocation(line: 6, column: 24, scope: !81)
!81 = !{!"0xb\006\0023\002", !82, !46} ; [ DW_TAG_lexical_block ]
!82 = !{!"main.cpp", !"/Users/echristo/tmp/bad-struct-ref"}
!83 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/DW_AT_byte_size.ll b/llvm/test/DebugInfo/X86/DW_AT_byte_size.ll
index 13a166635da..8b4f5611c17 100644
--- a/llvm/test/DebugInfo/X86/DW_AT_byte_size.ll
+++ b/llvm/test/DebugInfo/X86/DW_AT_byte_size.ll
@@ -39,8 +39,8 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
!12 = !{!13}
!13 = !{!"0xd\00b\001\0032\0032\000\000", !20, !11, !9} ; [ DW_TAG_member ]
!16 = !{!"0x101\00a\0016777219\000", !5, !6, !10} ; [ DW_TAG_arg_variable ]
-!17 = !{i32 3, i32 13, !5, null}
-!18 = !{i32 4, i32 3, !19, null}
+!17 = !MDLocation(line: 3, column: 13, scope: !5)
+!18 = !MDLocation(line: 4, column: 3, scope: !19)
!19 = !{!"0xb\003\0016\000", !20, !5} ; [ DW_TAG_lexical_block ]
!20 = !{!"foo.cpp", !"/Users/echristo"}
!21 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/DW_AT_linkage_name.ll b/llvm/test/DebugInfo/X86/DW_AT_linkage_name.ll
index 4c9a9b38d2a..e395e061973 100644
--- a/llvm/test/DebugInfo/X86/DW_AT_linkage_name.ll
+++ b/llvm/test/DebugInfo/X86/DW_AT_linkage_name.ll
@@ -105,12 +105,12 @@ attributes #2 = { ssp uwtable }
!25 = !{!"clang version 3.5.0 "}
!26 = !{!"0x101\00this\0016777216\001088", !17, null, !27} ; [ DW_TAG_arg_variable ] [this] [line 0]
!27 = !{!"0xf\00\000\0064\0064\000\000", null, null, !"_ZTS1A"} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from _ZTS1A]
-!28 = !{i32 0, i32 0, !17, null}
-!29 = !{i32 8, i32 0, !17, null}
+!28 = !MDLocation(line: 0, scope: !17)
+!29 = !MDLocation(line: 8, scope: !17)
!30 = !{!"0x101\00this\0016777216\001088", !18, null, !27} ; [ DW_TAG_arg_variable ] [this] [line 0]
-!31 = !{i32 0, i32 0, !18, null}
-!32 = !{i32 6, i32 0, !18, null}
-!33 = !{i32 8, i32 0, !18, null}
+!31 = !MDLocation(line: 0, scope: !18)
+!32 = !MDLocation(line: 6, scope: !18)
+!33 = !MDLocation(line: 8, scope: !18)
!34 = !{!"0x100\00a\0011\000", !19, !20, !"_ZTS1A"} ; [ DW_TAG_auto_variable ] [a] [line 11]
-!35 = !{i32 11, i32 0, !19, null}
-!36 = !{i32 12, i32 0, !19, null}
+!35 = !MDLocation(line: 11, scope: !19)
+!36 = !MDLocation(line: 12, scope: !19)
diff --git a/llvm/test/DebugInfo/X86/DW_AT_location-reference.ll b/llvm/test/DebugInfo/X86/DW_AT_location-reference.ll
index 52f48dbd2c2..a5b5700ca70 100644
--- a/llvm/test/DebugInfo/X86/DW_AT_location-reference.ll
+++ b/llvm/test/DebugInfo/X86/DW_AT_location-reference.ll
@@ -110,16 +110,16 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
!5 = !{!"0x100\00x\005\000", !6, !1, !7} ; [ DW_TAG_auto_variable ]
!6 = !{!"0xb\004\0014\000", !23, !0} ; [ DW_TAG_lexical_block ]
!7 = !{!"0x24\00int\000\0032\0032\000\000\005", null, !2} ; [ DW_TAG_base_type ]
-!8 = !{i32 6, i32 3, !6, null}
+!8 = !MDLocation(line: 6, column: 3, scope: !6)
!12 = !{i32 1}
-!13 = !{i32 7, i32 3, !6, null}
-!14 = !{i32 8, i32 3, !6, null}
-!15 = !{i32 9, i32 3, !6, null}
+!13 = !MDLocation(line: 7, column: 3, scope: !6)
+!14 = !MDLocation(line: 8, column: 3, scope: !6)
+!15 = !MDLocation(line: 9, column: 3, scope: !6)
!16 = !{i32 2}
-!17 = !{i32 10, i32 3, !6, null}
-!18 = !{i32 11, i32 3, !6, null}
-!19 = !{i32 12, i32 3, !6, null}
-!20 = !{i32 13, i32 1, !6, null}
+!17 = !MDLocation(line: 10, column: 3, scope: !6)
+!18 = !MDLocation(line: 11, column: 3, scope: !6)
+!19 = !MDLocation(line: 12, column: 3, scope: !6)
+!20 = !MDLocation(line: 13, column: 1, scope: !6)
!21 = !{!0}
!22 = !{!5}
!23 = !{!"simple.c", !"/home/rengol01/temp/tests/dwarf/relocation"}
diff --git a/llvm/test/DebugInfo/X86/DW_AT_object_pointer.ll b/llvm/test/DebugInfo/X86/DW_AT_object_pointer.ll
index 12695ce8eda..8cff0b87dce 100644
--- a/llvm/test/DebugInfo/X86/DW_AT_object_pointer.ll
+++ b/llvm/test/DebugInfo/X86/DW_AT_object_pointer.ll
@@ -72,19 +72,19 @@ entry:
!20 = !{!"0x2e\00A\00A\00_ZN1AC2Ev\003\000\001\000\006\00256\000\003", !6, null, !11, null, void (%class.A*)* @_ZN1AC2Ev, null, !17, !1} ; [ DW_TAG_subprogram ] [line 3] [def] [A]
!21 = !{!"0x100\00a\008\000", !22, !6, !14} ; [ DW_TAG_auto_variable ] [a] [line 8]
!22 = !{!"0xb\007\0011\000", !6, !5} ; [ DW_TAG_lexical_block ] [/Users/echristo/debug-tests/bar.cpp]
-!23 = !{i32 8, i32 5, !22, null}
-!24 = !{i32 8, i32 6, !22, null}
-!25 = !{i32 9, i32 3, !22, null}
+!23 = !MDLocation(line: 8, column: 5, scope: !22)
+!24 = !MDLocation(line: 8, column: 6, scope: !22)
+!25 = !MDLocation(line: 9, column: 3, scope: !22)
!26 = !{!"0x101\00this\0016777219\001088", !10, !6, !27} ; [ DW_TAG_arg_variable ] [this] [line 3]
!27 = !{!"0xf\00\000\0064\0064\000\000", null, null, !14} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from A]
-!28 = !{i32 3, i32 3, !10, null}
-!29 = !{i32 3, i32 18, !10, null}
+!28 = !MDLocation(line: 3, column: 3, scope: !10)
+!29 = !MDLocation(line: 3, column: 18, scope: !10)
!30 = !{!"0x101\00this\0016777219\001088", !20, !6, !27} ; [ DW_TAG_arg_variable ] [this] [line 3]
-!31 = !{i32 3, i32 3, !20, null}
-!32 = !{i32 3, i32 9, !33, null}
+!31 = !MDLocation(line: 3, column: 3, scope: !20)
+!32 = !MDLocation(line: 3, column: 9, scope: !33)
!33 = !{!"0xb\003\007\001", !6, !20} ; [ DW_TAG_lexical_block ] [/Users/echristo/debug-tests/bar.cpp]
-!34 = !{i32 3, i32 18, !33, null}
-!35 = !{i32 7, i32 0, !5, null}
+!34 = !MDLocation(line: 3, column: 18, scope: !33)
+!35 = !MDLocation(line: 7, scope: !5)
!36 = !{!"0x101\00\0016777223\000", !5, !6, !9} ; [ DW_TAG_arg_variable ] [line 7]
!37 = !{!"bar.cpp", !"/Users/echristo/debug-tests"}
!38 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/DW_AT_specification.ll b/llvm/test/DebugInfo/X86/DW_AT_specification.ll
index 42f42e63b8c..ab2075a879d 100644
--- a/llvm/test/DebugInfo/X86/DW_AT_specification.ll
+++ b/llvm/test/DebugInfo/X86/DW_AT_specification.ll
@@ -36,7 +36,7 @@ entry:
!20 = !{!"0x34\00x\00x\00\005\001\001", !5, !6, !21, i32* @_ZZN3foo3barEvE1x, null} ; [ DW_TAG_variable ]
!21 = !{!"0x26\00\000\000\000\000\000", null, null, !22} ; [ DW_TAG_const_type ]
!22 = !{!"0x24\00int\000\0032\0032\000\000\005", null, null} ; [ DW_TAG_base_type ]
-!25 = !{i32 6, i32 1, !26, null}
+!25 = !MDLocation(line: 6, column: 1, scope: !26)
!26 = !{!"0xb\004\0017\000", !6, !5} ; [ DW_TAG_lexical_block ]
!27 = !{!"nsNativeAppSupportBase.ii", !"/Users/espindola/mozilla-central/obj-x86_64-apple-darwin11.2.0/toolkit/library"}
!28 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/DW_AT_stmt_list_sec_offset.ll b/llvm/test/DebugInfo/X86/DW_AT_stmt_list_sec_offset.ll
index ea3da24d37f..39c33405476 100644
--- a/llvm/test/DebugInfo/X86/DW_AT_stmt_list_sec_offset.ll
+++ b/llvm/test/DebugInfo/X86/DW_AT_stmt_list_sec_offset.ll
@@ -40,5 +40,5 @@ attributes #0 = { nounwind "less-precise-fpmad"="false" "no-frame-pointer-elim"=
!7 = !{!8}
!8 = !{!"0x24\00int\000\0032\0032\000\000\005", null, null} ; [ DW_TAG_base_type ] [int] [line 0, size 32, align 32, offset 0, enc DW_ATE_signed]
!9 = !{i32 2, !"Dwarf Version", i32 4}
-!10 = !{i32 3, i32 0, !4, null}
+!10 = !MDLocation(line: 3, scope: !4)
!11 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/aligned_stack_var.ll b/llvm/test/DebugInfo/X86/aligned_stack_var.ll
index 3d255a8bd5b..32c6f2449aa 100644
--- a/llvm/test/DebugInfo/X86/aligned_stack_var.ll
+++ b/llvm/test/DebugInfo/X86/aligned_stack_var.ll
@@ -37,7 +37,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
!9 = !{!"0x100\00x\002\000", !10, !6, !11} ; [ DW_TAG_auto_variable ]
!10 = !{!"0xb\001\0012\000", !14, !5} ; [ DW_TAG_lexical_block ]
!11 = !{!"0x24\00int\000\0032\0032\000\000\005", null, null} ; [ DW_TAG_base_type ]
-!12 = !{i32 2, i32 7, !10, null}
-!13 = !{i32 3, i32 1, !10, null}
+!12 = !MDLocation(line: 2, column: 7, scope: !10)
+!13 = !MDLocation(line: 3, column: 1, scope: !10)
!14 = !{!"test.cc", !"/home/samsonov/debuginfo"}
!15 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/arguments.ll b/llvm/test/DebugInfo/X86/arguments.ll
index 7880737111b..2bc56b4e4da 100644
--- a/llvm/test/DebugInfo/X86/arguments.ll
+++ b/llvm/test/DebugInfo/X86/arguments.ll
@@ -69,8 +69,8 @@ attributes #1 = { nounwind readnone }
!17 = !{!"0x26\00\000\000\000\000\000", null, null, !8} ; [ DW_TAG_const_type ] [line 0, size 0, align 0, offset 0] [from foo]
!18 = !{i32 786468}
!19 = !{!"0x101\00f\0016777222\000", !4, !5, !8} ; [ DW_TAG_arg_variable ] [f] [line 6]
-!20 = !{i32 6, i32 0, !4, null}
+!20 = !MDLocation(line: 6, scope: !4)
!21 = !{!"0x101\00g\0033554438\000", !4, !5, !8} ; [ DW_TAG_arg_variable ] [g] [line 6]
-!22 = !{i32 7, i32 0, !4, null}
-!23 = !{i32 8, i32 0, !4, null}
+!22 = !MDLocation(line: 7, scope: !4)
+!23 = !MDLocation(line: 8, scope: !4)
!24 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/array.ll b/llvm/test/DebugInfo/X86/array.ll
index f71b0a1264f..e39be5ae0ff 100644
--- a/llvm/test/DebugInfo/X86/array.ll
+++ b/llvm/test/DebugInfo/X86/array.ll
@@ -88,14 +88,14 @@ attributes #2 = { nounwind readnone }
!25 = !{i32 2, !"Dwarf Version", i32 2}
!26 = !{i32 1, !"Debug Info Version", i32 2}
!27 = !{!"clang version 3.5.0 "}
-!28 = !{i32 1, i32 0, !4, null}
-!29 = !{i32 2, i32 0, !4, null}
+!28 = !MDLocation(line: 1, scope: !4)
+!29 = !MDLocation(line: 2, scope: !4)
!30 = !{!31, !31, i64 0}
!31 = !{!"int", !32, i64 0}
!32 = !{!"omnipotent char", !33, i64 0}
!33 = !{!"Simple C/C++ TBAA"}
-!34 = !{i32 3, i32 0, !4, null}
-!35 = !{i32 5, i32 0, !12, null}
-!36 = !{i32 6, i32 0, !12, null}
-!37 = !{i32 7, i32 0, !12, null}
-!38 = !{i32 8, i32 0, !12, null}
+!34 = !MDLocation(line: 3, scope: !4)
+!35 = !MDLocation(line: 5, scope: !12)
+!36 = !MDLocation(line: 6, scope: !12)
+!37 = !MDLocation(line: 7, scope: !12)
+!38 = !MDLocation(line: 8, scope: !12)
diff --git a/llvm/test/DebugInfo/X86/array2.ll b/llvm/test/DebugInfo/X86/array2.ll
index 6dfa8d71783..5b21188c1cf 100644
--- a/llvm/test/DebugInfo/X86/array2.ll
+++ b/llvm/test/DebugInfo/X86/array2.ll
@@ -92,16 +92,16 @@ attributes #2 = { nounwind }
!17 = !{i32 1, !"Debug Info Version", i32 2}
!18 = !{!"clang version 3.5.0 "}
!19 = !{!"0x101\00p\0016777217\000", !4, !5, !8} ; [ DW_TAG_arg_variable ] [p] [line 1]
-!20 = !{i32 1, i32 0, !4, null}
-!21 = !{i32 2, i32 0, !4, null}
-!22 = !{i32 3, i32 0, !4, null}
+!20 = !MDLocation(line: 1, scope: !4)
+!21 = !MDLocation(line: 2, scope: !4)
+!22 = !MDLocation(line: 3, scope: !4)
!23 = !{!"0x101\00argc\0016777221\000", !10, !5, !9} ; [ DW_TAG_arg_variable ] [argc] [line 5]
-!24 = !{i32 5, i32 0, !10, null}
+!24 = !MDLocation(line: 5, scope: !10)
!25 = !{!"0x101\00argv\0033554437\000", !10, !5, !13} ; [ DW_TAG_arg_variable ] [argv] [line 5]
!26 = !{!"0x100\00array\006\000", !10, !5, !27} ; [ DW_TAG_auto_variable ] [array] [line 6]
!27 = !{!"0x1\00\000\00128\0032\000\000", null, null, !9, !28, i32 0, null, null, null} ; [ DW_TAG_array_type ] [line 0, size 128, align 32, offset 0] [from int]
!28 = !{!29}
!29 = !{!"0x21\000\004"} ; [ DW_TAG_subrange_type ] [0, 3]
-!30 = !{i32 6, i32 0, !10, null}
-!31 = !{i32 7, i32 0, !10, null}
-!32 = !{i32 8, i32 0, !10, null}
+!30 = !MDLocation(line: 6, scope: !10)
+!31 = !MDLocation(line: 7, scope: !10)
+!32 = !MDLocation(line: 8, scope: !10)
diff --git a/llvm/test/DebugInfo/X86/block-capture.ll b/llvm/test/DebugInfo/X86/block-capture.ll
index 9eb8912997e..51d575fdfe4 100644
--- a/llvm/test/DebugInfo/X86/block-capture.ll
+++ b/llvm/test/DebugInfo/X86/block-capture.ll
@@ -121,11 +121,11 @@ attributes #3 = { nounwind }
!63 = !{!"0xf\00\000\0064\0064\000\000", null, null, !11} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from ]
!64 = !{!"0xd\00DestroyFuncPtr\002\0064\0064\00192\000", !1, !58, !63} ; [ DW_TAG_member ] [DestroyFuncPtr] [line 2, size 64, align 64, offset 192] [from ]
!65 = !{!"0xd\00block\002\0064\0064\00256\003", !1, !5, !25} ; [ DW_TAG_member ] [block] [line 2, size 64, align 64, offset 256] [public] [from ]
-!66 = !{i32 2, i32 20, !8, null}
-!67 = !{i32 2, i32 21, !8, null}
+!66 = !MDLocation(line: 2, column: 20, scope: !8)
+!67 = !MDLocation(line: 2, column: 21, scope: !8)
!68 = !{!"0x100\00block\002\000", !8, !5, !25} ; [ DW_TAG_auto_variable ] [block] [line 2]
!69 = !{!"0x102\006\0034\0032"} ; [ DW_TAG_expression ] [DW_OP_deref]
-!70 = !{i32 2, i32 9, !8, null}
-!71 = !{i32 2, i32 23, !72, null}
+!70 = !MDLocation(line: 2, column: 9, scope: !8)
+!71 = !MDLocation(line: 2, column: 23, scope: !72)
!72 = !{!"0xb\002\0021\000", !1, !8} ; [ DW_TAG_lexical_block ] [/foo.m]
-!73 = !{i32 2, i32 32, !8, null}
+!73 = !MDLocation(line: 2, column: 32, scope: !8)
diff --git a/llvm/test/DebugInfo/X86/byvalstruct.ll b/llvm/test/DebugInfo/X86/byvalstruct.ll
index d78c08ee237..d89ba3596c5 100644
--- a/llvm/test/DebugInfo/X86/byvalstruct.ll
+++ b/llvm/test/DebugInfo/X86/byvalstruct.ll
@@ -116,13 +116,13 @@ attributes #1 = { nounwind readnone }
!26 = !{i32 1, !"Objective-C Image Info Section", !"__DATA, __objc_imageinfo, regular, no_dead_strip"}
!27 = !{i32 4, !"Objective-C Garbage Collection", i32 0}
!28 = !{!"0x101\00self\0016777225\001088", !7, !5, !14} ; [ DW_TAG_arg_variable ] [self] [line 9]
-!29 = !{i32 9, i32 0, !7, null}
+!29 = !MDLocation(line: 9, scope: !7)
!30 = !{!"0x101\00_cmd\0033554441\0064", !7, !5, !31} ; [ DW_TAG_arg_variable ] [_cmd] [line 9]
!31 = !{!"0x16\00SEL\009\000\000\000\000", !1, null, !12} ; [ DW_TAG_typedef ] [SEL] [line 9, size 0, align 0, offset 0] [from ]
!32 = !{!"0x101\00otherBitmap\0050331657\000", !7, !5, !14} ; [ DW_TAG_arg_variable ] [otherBitmap] [line 9]
!33 = !{!"0x101\00info\0067108874\000", !7, !5, !15} ; [ DW_TAG_arg_variable ] [info] [line 10]
-!34 = !{i32 10, i32 0, !7, null}
+!34 = !MDLocation(line: 10, scope: !7)
!35 = !{!"0x101\00length\0083886091\000", !7, !5, !19} ; [ DW_TAG_arg_variable ] [length] [line 11]
-!36 = !{i32 11, i32 0, !7, null}
-!37 = !{i32 13, i32 0, !7, null}
+!36 = !MDLocation(line: 11, scope: !7)
+!37 = !MDLocation(line: 13, scope: !7)
!38 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/coff_debug_info_type.ll b/llvm/test/DebugInfo/X86/coff_debug_info_type.ll
index 4b9654eb93e..d34f50b7244 100644
--- a/llvm/test/DebugInfo/X86/coff_debug_info_type.ll
+++ b/llvm/test/DebugInfo/X86/coff_debug_info_type.ll
@@ -39,5 +39,5 @@ attributes #0 = { nounwind "less-precise-fpmad"="false" "no-frame-pointer-elim"=
!7 = !{!8}
!8 = !{!"0x24\00int\000\0032\0032\000\000\005", null, null} ; [ DW_TAG_base_type ] [int] [line 0, size 32, align 32, offset 0, enc DW_ATE_signed]
!9 = !{i32 2, !"Dwarf Version", i32 3}
-!10 = !{i32 3, i32 0, !4, null}
+!10 = !MDLocation(line: 3, scope: !4)
!11 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/coff_relative_names.ll b/llvm/test/DebugInfo/X86/coff_relative_names.ll
index b0339e413c4..96e70b1e388 100644
--- a/llvm/test/DebugInfo/X86/coff_relative_names.ll
+++ b/llvm/test/DebugInfo/X86/coff_relative_names.ll
@@ -33,5 +33,5 @@ attributes #0 = { nounwind "less-precise-fpmad"="false" "no-frame-pointer-elim"=
!7 = !{!8}
!8 = !{!"0x24\00int\000\0032\0032\000\000\005", null, null} ; [ DW_TAG_base_type ] [int] [line 0, size 32, align 32, offset 0, enc DW_ATE_signed]
!9 = !{i32 2, !"Dwarf Version", i32 3}
-!10 = !{i32 3, i32 0, !4, null}
+!10 = !MDLocation(line: 3, scope: !4)
!11 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/concrete_out_of_line.ll b/llvm/test/DebugInfo/X86/concrete_out_of_line.ll
index 28343f88152..b5da28ae328 100644
--- a/llvm/test/DebugInfo/X86/concrete_out_of_line.ll
+++ b/llvm/test/DebugInfo/X86/concrete_out_of_line.ll
@@ -118,14 +118,14 @@ declare void @_Z8moz_freePv(i8*)
!46 = !{!"0x101\00aValue\0033554436\000", !31, !6, !9} ; [ DW_TAG_arg_variable ]
!47 = !{!49}
!49 = !{!"0x34\00mRefCnt\00mRefCnt\00\009\000\001", null, !6, !37, i32* null, null} ; [ DW_TAG_variable ]
-!50 = !{i32 5, i32 5, !51, !52}
+!50 = !MDLocation(line: 5, column: 5, scope: !51, inlinedAt: !52)
!51 = !{!"0xb\004\0029\002", !6, !31} ; [ DW_TAG_lexical_block ]
-!52 = !{i32 15, i32 0, !53, null}
+!52 = !MDLocation(line: 15, scope: !53)
!53 = !{!"0xb\0014\0034\000", !6, !5} ; [ DW_TAG_lexical_block ]
-!54 = !{i32 19, i32 3, !55, !56}
+!54 = !MDLocation(line: 19, column: 3, scope: !55, inlinedAt: !56)
!55 = !{!"0xb\0018\0041\001", !6, !27} ; [ DW_TAG_lexical_block ]
-!56 = !{i32 18, i32 41, !23, !52}
-!57 = !{i32 19, i32 3, !55, !58}
-!58 = !{i32 18, i32 41, !23, null}
+!56 = !MDLocation(line: 18, column: 41, scope: !23, inlinedAt: !52)
+!57 = !MDLocation(line: 19, column: 3, scope: !55, inlinedAt: !58)
+!58 = !MDLocation(line: 18, column: 41, scope: !23)
!59 = !{!"nsAutoRefCnt.ii", !"/Users/espindola/mozilla-central/obj-x86_64-apple-darwin11.2.0/netwerk/base/src"}
!60 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/constant-aggregate.ll b/llvm/test/DebugInfo/X86/constant-aggregate.ll
index 2662747fd12..324c8317774 100644
--- a/llvm/test/DebugInfo/X86/constant-aggregate.ll
+++ b/llvm/test/DebugInfo/X86/constant-aggregate.ll
@@ -110,9 +110,9 @@ attributes #1 = { nounwind readnone }
!35 = !{i32 1, !"PIC Level", i32 2}
!36 = !{!"clang version 3.6.0 (trunk 225364) (llvm/trunk 225366)"}
!37 = !{!"0x102"} ; [ DW_TAG_expression ]
-!38 = !{i32 3, i32 16, !12, null}
-!39 = !{i32 5, i32 3, !12, null}
-!40 = !{i32 10, i32 16, !19, null}
-!41 = !{i32 12, i32 3, !19, null}
-!42 = !{i32 16, i32 6, !24, null}
-!43 = !{i32 17, i32 3, !24, null}
+!38 = !MDLocation(line: 3, column: 16, scope: !12)
+!39 = !MDLocation(line: 5, column: 3, scope: !12)
+!40 = !MDLocation(line: 10, column: 16, scope: !19)
+!41 = !MDLocation(line: 12, column: 3, scope: !19)
+!42 = !MDLocation(line: 16, column: 6, scope: !24)
+!43 = !MDLocation(line: 17, column: 3, scope: !24)
diff --git a/llvm/test/DebugInfo/X86/cu-ranges-odr.ll b/llvm/test/DebugInfo/X86/cu-ranges-odr.ll
index 5a14a613e5d..c1f58d7eed7 100644
--- a/llvm/test/DebugInfo/X86/cu-ranges-odr.ll
+++ b/llvm/test/DebugInfo/X86/cu-ranges-odr.ll
@@ -87,10 +87,10 @@ attributes #1 = { nounwind readnone }
!23 = !{i32 2, !"Dwarf Version", i32 4}
!24 = !{i32 1, !"Debug Info Version", i32 2}
!25 = !{!"clang version 3.5 (trunk 199923) (llvm/trunk 199940)"}
-!26 = !{i32 8, i32 0, !14, null}
+!26 = !MDLocation(line: 8, scope: !14)
!27 = !{!"0x101\00this\0016777216\001088", !18, null, !28} ; [ DW_TAG_arg_variable ] [this] [line 0]
!28 = !{!"0xf\00\000\0064\0064\000\000", null, null, !"_ZTS1A"} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from _ZTS1A]
-!29 = !{i32 0, i32 0, !18, null}
+!29 = !MDLocation(line: 0, scope: !18)
!30 = !{!"0x101\00i\0033554435\000", !18, !15, !7} ; [ DW_TAG_arg_variable ] [i] [line 3]
-!31 = !{i32 3, i32 0, !18, null}
-!32 = !{i32 3, i32 0, !19, null}
+!31 = !MDLocation(line: 3, scope: !18)
+!32 = !MDLocation(line: 3, scope: !19)
diff --git a/llvm/test/DebugInfo/X86/cu-ranges.ll b/llvm/test/DebugInfo/X86/cu-ranges.ll
index dc87ec78581..0d872d872f9 100644
--- a/llvm/test/DebugInfo/X86/cu-ranges.ll
+++ b/llvm/test/DebugInfo/X86/cu-ranges.ll
@@ -70,6 +70,6 @@ attributes #1 = { nounwind readnone }
!11 = !{i32 1, !"Debug Info Version", i32 2}
!12 = !{!"clang version 3.5.0 (trunk 204164) (llvm/trunk 204183)"}
!13 = !{!"0x101\00a\0016777217\000", !4, !5, !8} ; [ DW_TAG_arg_variable ] [a] [line 1]
-!14 = !{i32 1, i32 0, !4, null}
+!14 = !MDLocation(line: 1, scope: !4)
!15 = !{!"0x101\00b\0016777218\000", !9, !5, !8} ; [ DW_TAG_arg_variable ] [b] [line 2]
-!16 = !{i32 2, i32 0, !9, null}
+!16 = !MDLocation(line: 2, scope: !9)
diff --git a/llvm/test/DebugInfo/X86/dbg-byval-parameter.ll b/llvm/test/DebugInfo/X86/dbg-byval-parameter.ll
index 9ecdc908d9a..713781f38fb 100644
--- a/llvm/test/DebugInfo/X86/dbg-byval-parameter.ll
+++ b/llvm/test/DebugInfo/X86/dbg-byval-parameter.ll
@@ -43,8 +43,8 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
!12 = !{!"0xd\00x\002\0064\0064\000\000", !19, !10, !6} ; [ DW_TAG_member ]
!13 = !{!"0xd\00y\003\0064\0064\0064\000", !19, !10, !6} ; [ DW_TAG_member ]
!14 = !{!"0xd\00P2\008\00128\0064\00128\000", !19, !7, !10} ; [ DW_TAG_member ]
-!15 = !{i32 11, i32 0, !1, null}
-!16 = !{i32 12, i32 0, !17, null}
+!15 = !MDLocation(line: 11, scope: !1)
+!16 = !MDLocation(line: 12, scope: !17)
!17 = !{!"0xb\0011\000\000", !19, !1} ; [ DW_TAG_lexical_block ]
!18 = !{!1}
!19 = !{!"b2.c", !"/tmp/"}
diff --git a/llvm/test/DebugInfo/X86/dbg-const-int.ll b/llvm/test/DebugInfo/X86/dbg-const-int.ll
index 3daca14735e..18abbdd5c21 100644
--- a/llvm/test/DebugInfo/X86/dbg-const-int.ll
+++ b/llvm/test/DebugInfo/X86/dbg-const-int.ll
@@ -30,8 +30,8 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
!6 = !{!"0x100\00i\002\000", !7, !2, !5} ; [ DW_TAG_auto_variable ]
!7 = !{!"0xb\001\0011\000", !13, !1} ; [ DW_TAG_lexical_block ]
!8 = !{i32 42}
-!9 = !{i32 2, i32 12, !7, null}
-!10 = !{i32 3, i32 2, !7, null}
+!9 = !MDLocation(line: 2, column: 12, scope: !7)
+!10 = !MDLocation(line: 3, column: 2, scope: !7)
!11 = !{!1}
!12 = !{!6}
!13 = !{!"a.c", !"/private/tmp"}
diff --git a/llvm/test/DebugInfo/X86/dbg-const.ll b/llvm/test/DebugInfo/X86/dbg-const.ll
index 90d3ce51a79..755565dbf95 100644
--- a/llvm/test/DebugInfo/X86/dbg-const.ll
+++ b/llvm/test/DebugInfo/X86/dbg-const.ll
@@ -40,10 +40,10 @@ declare i32 @bar() nounwind readnone
!6 = !{!"0x100\00j\0015\000", !7, !1, !5} ; [ DW_TAG_auto_variable ]
!7 = !{!"0xb\0012\0052\000", !15, !0} ; [ DW_TAG_lexical_block ]
!8 = !{i32 42}
-!9 = !{i32 15, i32 12, !7, null}
-!10 = !{i32 23, i32 3, !7, null}
-!11 = !{i32 17, i32 3, !7, null}
-!12 = !{i32 18, i32 3, !7, null}
+!9 = !MDLocation(line: 15, column: 12, scope: !7)
+!10 = !MDLocation(line: 23, column: 3, scope: !7)
+!11 = !MDLocation(line: 17, column: 3, scope: !7)
+!12 = !MDLocation(line: 18, column: 3, scope: !7)
!13 = !{!0}
!14 = !{!6}
!15 = !{!"mu.c", !"/private/tmp"}
diff --git a/llvm/test/DebugInfo/X86/dbg-declare-arg.ll b/llvm/test/DebugInfo/X86/dbg-declare-arg.ll
index 7ad328c63f1..ef975dd9db8 100644
--- a/llvm/test/DebugInfo/X86/dbg-declare-arg.ll
+++ b/llvm/test/DebugInfo/X86/dbg-declare-arg.ll
@@ -99,28 +99,28 @@ entry:
!24 = !{null}
!25 = !{!"0x2e\00~A\00~A\00_ZN1AD2Ev\002\000\001\000\006\00256\000\000", !51, !3, !23, null, void (%class.A*)* @_ZN1AD2Ev, null, null, null} ; [ DW_TAG_subprogram ] [line 2] [def] [scope 0] [~A]
!26 = !{!"0x101\00i\0016777220\000", !19, !3, !6} ; [ DW_TAG_arg_variable ]
-!27 = !{i32 4, i32 11, !19, null}
+!27 = !MDLocation(line: 4, column: 11, scope: !19)
!28 = !{!"0x100\00j\005\000", !29, !3, !6} ; [ DW_TAG_auto_variable ]
!29 = !{!"0xb\004\0014\000", !51, !19} ; [ DW_TAG_lexical_block ]
-!30 = !{i32 5, i32 7, !29, null}
-!31 = !{i32 5, i32 12, !29, null}
-!32 = !{i32 6, i32 3, !29, null}
-!33 = !{i32 7, i32 5, !34, null}
+!30 = !MDLocation(line: 5, column: 7, scope: !29)
+!31 = !MDLocation(line: 5, column: 12, scope: !29)
+!32 = !MDLocation(line: 6, column: 3, scope: !29)
+!33 = !MDLocation(line: 7, column: 5, scope: !34)
!34 = !{!"0xb\006\0016\001", !51, !29} ; [ DW_TAG_lexical_block ]
-!35 = !{i32 8, i32 3, !34, null}
-!36 = !{i32 9, i32 9, !29, null}
+!35 = !MDLocation(line: 8, column: 3, scope: !34)
+!36 = !MDLocation(line: 9, column: 9, scope: !29)
!37 = !{!"0x100\00my_a\009\000", !29, !3, !38} ; [ DW_TAG_auto_variable ]
!38 = !{!"0x10\00\000\000\000\000\000", !2, null, !1} ; [ DW_TAG_reference_type ]
-!39 = !{i32 9, i32 5, !29, null}
-!40 = !{i32 10, i32 3, !29, null}
-!41 = !{i32 11, i32 3, !29, null}
-!42 = !{i32 12, i32 1, !29, null}
+!39 = !MDLocation(line: 9, column: 5, scope: !29)
+!40 = !MDLocation(line: 10, column: 3, scope: !29)
+!41 = !MDLocation(line: 11, column: 3, scope: !29)
+!42 = !MDLocation(line: 12, column: 1, scope: !29)
!43 = !{!"0x101\00this\0016777218\0064", !22, !3, !13} ; [ DW_TAG_arg_variable ]
-!44 = !{i32 2, i32 47, !22, null}
-!45 = !{i32 2, i32 61, !22, null}
+!44 = !MDLocation(line: 2, column: 47, scope: !22)
+!45 = !MDLocation(line: 2, column: 61, scope: !22)
!46 = !{!"0x101\00this\0016777218\0064", !25, !3, !13} ; [ DW_TAG_arg_variable ]
-!47 = !{i32 2, i32 47, !25, null}
-!48 = !{i32 2, i32 54, !49, null}
+!47 = !MDLocation(line: 2, column: 47, scope: !25)
+!48 = !MDLocation(line: 2, column: 54, scope: !49)
!49 = !{!"0xb\002\0052\002", !51, !25} ; [ DW_TAG_lexical_block ]
!50 = !{!19, !22, !25}
!51 = !{!"a.cc", !"/private/tmp"}
diff --git a/llvm/test/DebugInfo/X86/dbg-declare.ll b/llvm/test/DebugInfo/X86/dbg-declare.ll
index 180823582df..2ede97b2202 100644
--- a/llvm/test/DebugInfo/X86/dbg-declare.ll
+++ b/llvm/test/DebugInfo/X86/dbg-declare.ll
@@ -41,16 +41,16 @@ declare void @llvm.stackrestore(i8*) nounwind
!10 = !{!"0xf\00\000\0064\0064\000\000", null, null, !11} ; [ DW_TAG_pointer_type ]
!11 = !{!"0x26\00\000\000\000\000\000", null, null, !9} ; [ DW_TAG_const_type ]
!14 = !{!"0x101\00x\0016777221\000", !5, !6, !10} ; [ DW_TAG_arg_variable ]
-!15 = !{i32 5, i32 21, !5, null}
-!16 = !{i32 7, i32 13, !17, null}
+!15 = !MDLocation(line: 5, column: 21, scope: !5)
+!16 = !MDLocation(line: 7, column: 13, scope: !17)
!17 = !{!"0xb\006\001\000", !26, !5} ; [ DW_TAG_lexical_block ]
!18 = !{!"0x100\00a\007\000", !17, !6, !19} ; [ DW_TAG_auto_variable ]
!19 = !{!"0x1\00\000\000\008\000\000", null, null, !20, !21, i32 0, null, null, null} ; [ DW_TAG_array_type ] [line 0, size 0, align 8, offset 0] [from char]
!20 = !{!"0x24\00char\000\008\008\000\000\006", null, null} ; [ DW_TAG_base_type ]
!21 = !{!22}
!22 = !{!"0x21\000\00-1"} ; [ DW_TAG_subrange_type ]
-!23 = !{i32 7, i32 8, !17, null}
-!24 = !{i32 9, i32 1, !17, null}
-!25 = !{i32 8, i32 3, !17, null}
+!23 = !MDLocation(line: 7, column: 8, scope: !17)
+!24 = !MDLocation(line: 9, column: 1, scope: !17)
+!25 = !MDLocation(line: 8, column: 3, scope: !17)
!26 = !{!"20020104-2.c", !"/Volumes/Sandbox/llvm"}
!27 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/dbg-i128-const.ll b/llvm/test/DebugInfo/X86/dbg-i128-const.ll
index 5a764200641..71654cb56ce 100644
--- a/llvm/test/DebugInfo/X86/dbg-i128-const.ll
+++ b/llvm/test/DebugInfo/X86/dbg-i128-const.ll
@@ -26,7 +26,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
!8 = !{!"0x16\00ti_int\0078\000\000\000\000", !14, !4, !10} ; [ DW_TAG_typedef ]
!9 = !{!"0x29", !14} ; [ DW_TAG_file_type ]
!10 = !{!"0x24\00\000\00128\00128\000\000\005", !13, !4} ; [ DW_TAG_base_type ]
-!11 = !{i32 29, i32 0, !2, null}
+!11 = !MDLocation(line: 29, scope: !2)
!12 = !{!3}
!13 = !{!"foo.c", !"/tmp"}
!14 = !{!"myint.h", !"/tmp"}
diff --git a/llvm/test/DebugInfo/X86/dbg-merge-loc-entry.ll b/llvm/test/DebugInfo/X86/dbg-merge-loc-entry.ll
index 2af4fe74660..0d562223b8c 100644
--- a/llvm/test/DebugInfo/X86/dbg-merge-loc-entry.ll
+++ b/llvm/test/DebugInfo/X86/dbg-merge-loc-entry.ll
@@ -55,19 +55,19 @@ declare %0 @llvm.uadd.with.overflow.i64(i64, i64) nounwind readnone
!12 = !{!"0x16\00TItype\00160\000\000\000\000", !30, !6, !13} ; [ DW_TAG_typedef ]
!13 = !{!"0x24\00\000\00128\00128\000\000\005", !29, !1} ; [ DW_TAG_base_type ]
!14 = !{!"0x101\00u\001093\000", !9, !1, !12} ; [ DW_TAG_arg_variable ]
-!15 = !{i32 1093, i32 0, !9, null}
+!15 = !MDLocation(line: 1093, scope: !9)
!16 = !{i64 0}
!17 = !{!"0x100\00c\001095\000", !18, !1, !19} ; [ DW_TAG_auto_variable ]
!18 = !{!"0xb\001094\000\0013", !29, !9} ; [ DW_TAG_lexical_block ]
!19 = !{!"0x16\00word_type\00424\000\000\000\000", !30, !6, !20} ; [ DW_TAG_typedef ]
!20 = !{!"0x24\00long int\000\0064\0064\000\000\005", !29, !1} ; [ DW_TAG_base_type ]
-!21 = !{i32 1095, i32 0, !18, null}
-!22 = !{i32 1103, i32 0, !18, null}
-!23 = !{i32 1104, i32 0, !18, null}
-!24 = !{i32 1003, i32 0, !25, !26}
+!21 = !MDLocation(line: 1095, scope: !18)
+!22 = !MDLocation(line: 1103, scope: !18)
+!23 = !MDLocation(line: 1104, scope: !18)
+!24 = !MDLocation(line: 1003, scope: !25, inlinedAt: !26)
!25 = !{!"0xb\00879\000\000", !29, !0} ; [ DW_TAG_lexical_block ]
-!26 = !{i32 1107, i32 0, !18, null}
-!27 = !{i32 1111, i32 0, !18, null}
+!26 = !MDLocation(line: 1107, scope: !18)
+!27 = !MDLocation(line: 1111, scope: !18)
!28 = !{!0, !9}
!29 = !{!"foobar.c", !"/tmp"}
!30 = !{!"foobar.h", !"/tmp"}
diff --git a/llvm/test/DebugInfo/X86/dbg-prolog-end.ll b/llvm/test/DebugInfo/X86/dbg-prolog-end.ll
index 70741b4f038..4aaaf4a9b2a 100644
--- a/llvm/test/DebugInfo/X86/dbg-prolog-end.ll
+++ b/llvm/test/DebugInfo/X86/dbg-prolog-end.ll
@@ -44,15 +44,15 @@ entry:
!5 = !{!"0x24\00int\000\0032\0032\000\000\005", null, !0} ; [ DW_TAG_base_type ]
!6 = !{!"0x2e\00main\00main\00\007\000\001\000\006\000\000\007", !19, !2, !3, null, i32 ()* @main, null, null, null} ; [ DW_TAG_subprogram ] [line 7] [def] [main]
!7 = !{!"0x101\00i\0016777217\000", !1, !2, !5} ; [ DW_TAG_arg_variable ]
-!8 = !{i32 1, i32 13, !1, null}
+!8 = !MDLocation(line: 1, column: 13, scope: !1)
!9 = !{!"0x100\00j\002\000", !10, !2, !5} ; [ DW_TAG_auto_variable ]
!10 = !{!"0xb\001\0016\000", !19, !1} ; [ DW_TAG_lexical_block ]
-!11 = !{i32 2, i32 6, !10, null}
-!12 = !{i32 2, i32 11, !10, null}
-!13 = !{i32 3, i32 2, !10, null}
-!14 = !{i32 4, i32 2, !10, null}
-!15 = !{i32 5, i32 2, !10, null}
-!16 = !{i32 8, i32 2, !17, null}
+!11 = !MDLocation(line: 2, column: 6, scope: !10)
+!12 = !MDLocation(line: 2, column: 11, scope: !10)
+!13 = !MDLocation(line: 3, column: 2, scope: !10)
+!14 = !MDLocation(line: 4, column: 2, scope: !10)
+!15 = !MDLocation(line: 5, column: 2, scope: !10)
+!16 = !MDLocation(line: 8, column: 2, scope: !17)
!17 = !{!"0xb\007\0012\001", !19, !6} ; [ DW_TAG_lexical_block ]
!19 = !{!"/tmp/a.c", !"/private/tmp"}
!20 = !{i32 0}
diff --git a/llvm/test/DebugInfo/X86/dbg-subrange.ll b/llvm/test/DebugInfo/X86/dbg-subrange.ll
index 22e1831294b..89754b9b328 100644
--- a/llvm/test/DebugInfo/X86/dbg-subrange.ll
+++ b/llvm/test/DebugInfo/X86/dbg-subrange.ll
@@ -28,8 +28,8 @@ entry:
!15 = !{!"0x24\00char\000\008\008\000\000\006", null, null} ; [ DW_TAG_base_type ]
!16 = !{!17}
!17 = !{!"0x21\000\004294967296"} ; [ DW_TAG_subrange_type ]
-!18 = !{i32 5, i32 3, !19, null}
+!18 = !MDLocation(line: 5, column: 3, scope: !19)
!19 = !{!"0xb\004\001\000", !21, !5} ; [ DW_TAG_lexical_block ]
-!20 = !{i32 6, i32 1, !19, null}
+!20 = !MDLocation(line: 6, column: 1, scope: !19)
!21 = !{!"small.c", !"/private/tmp"}
!22 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/dbg-value-const-byref.ll b/llvm/test/DebugInfo/X86/dbg-value-const-byref.ll
index 26979661a78..c8ffba87135 100644
--- a/llvm/test/DebugInfo/X86/dbg-value-const-byref.ll
+++ b/llvm/test/DebugInfo/X86/dbg-value-const-byref.ll
@@ -93,14 +93,14 @@ attributes #3 = { nounwind }
!12 = !{i32 1, !"Debug Info Version", i32 2}
!13 = !{!"clang version 3.5.0 "}
!14 = !{i32 3}
-!15 = !{i32 6, i32 0, !4, null}
-!16 = !{i32 7, i32 0, !4, null}
+!15 = !MDLocation(line: 6, scope: !4)
+!16 = !MDLocation(line: 7, scope: !4)
!17 = !{i32 7}
-!18 = !{i32 8, i32 0, !4, null}
-!19 = !{i32 9, i32 0, !4, null}
+!18 = !MDLocation(line: 8, scope: !4)
+!19 = !MDLocation(line: 9, scope: !4)
!20 = !{!21, !21, i64 0}
!21 = !{!"int", !22, i64 0}
!22 = !{!"omnipotent char", !23, i64 0}
!23 = !{!"Simple C/C++ TBAA"}
-!24 = !{i32 10, i32 0, !4, null}
-!25 = !{i32 11, i32 0, !4, null}
+!24 = !MDLocation(line: 10, scope: !4)
+!25 = !MDLocation(line: 11, scope: !4)
diff --git a/llvm/test/DebugInfo/X86/dbg-value-dag-combine.ll b/llvm/test/DebugInfo/X86/dbg-value-dag-combine.ll
index 24d6a8ea25f..9392da952f9 100644
--- a/llvm/test/DebugInfo/X86/dbg-value-dag-combine.ll
+++ b/llvm/test/DebugInfo/X86/dbg-value-dag-combine.ll
@@ -32,16 +32,16 @@ entry:
!5 = !{!"0xf\00\000\0032\0032\000\000", null, !2, !6} ; [ DW_TAG_pointer_type ]
!6 = !{!"0x24\00unsigned int\000\0032\0032\000\000\007", null, !2} ; [ DW_TAG_base_type ]
!7 = !{!"0x101\00ip\001\000", !0, !1, !5} ; [ DW_TAG_arg_variable ]
-!8 = !{i32 1, i32 42, !0, null}
+!8 = !MDLocation(line: 1, column: 42, scope: !0)
!9 = !{!"0x100\00gid\003\000", !10, !1, !6} ; [ DW_TAG_auto_variable ]
!10 = !{!"0xb\002\001\000", !19, !0} ; [ DW_TAG_lexical_block ]
-!11 = !{i32 3, i32 41, !10, null}
+!11 = !MDLocation(line: 3, column: 41, scope: !10)
!12 = !{i32 0}
!13 = !{!"0x100\00idx\004\000", !10, !1, !6} ; [ DW_TAG_auto_variable ]
-!14 = !{i32 4, i32 20, !10, null}
-!15 = !{i32 5, i32 15, !10, null}
-!16 = !{i32 6, i32 18, !10, null}
-!17 = !{i32 7, i32 1, !0, null}
+!14 = !MDLocation(line: 4, column: 20, scope: !10)
+!15 = !MDLocation(line: 5, column: 15, scope: !10)
+!16 = !MDLocation(line: 6, column: 18, scope: !10)
+!17 = !MDLocation(line: 7, column: 1, scope: !0)
!18 = !{!0}
!19 = !{!"OCL6368.tmp.cl", !"E:\5CUsers\5Cmvillmow.AMD\5CAppData\5CLocal\5CTemp"}
!20 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/dbg-value-inlined-parameter.ll b/llvm/test/DebugInfo/X86/dbg-value-inlined-parameter.ll
index dd446448914..31833a8edf5 100644
--- a/llvm/test/DebugInfo/X86/dbg-value-inlined-parameter.ll
+++ b/llvm/test/DebugInfo/X86/dbg-value-inlined-parameter.ll
@@ -94,21 +94,21 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
!17 = !{!"0xd\00nums\003\0032\0032\0064\000", !42, !1, !5} ; [ DW_TAG_member ]
!18 = !{!"0x101\00nums\0033554439\000", !0, !1, !5, !32} ; [ DW_TAG_arg_variable ]
!19 = !{!"0x34\00p\00p\00\0014\000\001", !2, !1, !11, %struct.S1* @p, null} ; [ DW_TAG_variable ]
-!20 = !{i32 7, i32 13, !0, null}
-!21 = !{i32 7, i32 21, !0, null}
-!22 = !{i32 9, i32 3, !23, null}
+!20 = !MDLocation(line: 7, column: 13, scope: !0)
+!21 = !MDLocation(line: 7, column: 21, scope: !0)
+!22 = !MDLocation(line: 9, column: 3, scope: !23)
!23 = !{!"0xb\008\001\000", !1, !0} ; [ DW_TAG_lexical_block ]
-!27 = !{i32 10, i32 3, !23, null}
-!29 = !{i32 11, i32 3, !23, null}
+!27 = !MDLocation(line: 10, column: 3, scope: !23)
+!29 = !MDLocation(line: 11, column: 3, scope: !23)
!30 = !{%struct.S1* @p}
-!31 = !{i32 7, i32 13, !0, !32}
-!32 = !{i32 16, i32 3, !33, null}
+!31 = !MDLocation(line: 7, column: 13, scope: !0, inlinedAt: !32)
+!32 = !MDLocation(line: 16, column: 3, scope: !33)
!33 = !{!"0xb\0015\0015\001", !1, !6} ; [ DW_TAG_lexical_block ]
!34 = !{i32 1}
-!35 = !{i32 7, i32 21, !0, !32}
-!36 = !{i32 9, i32 3, !23, !32}
-!37 = !{i32 10, i32 3, !23, !32}
-!38 = !{i32 17, i32 1, !33, null}
+!35 = !MDLocation(line: 7, column: 21, scope: !0, inlinedAt: !32)
+!36 = !MDLocation(line: 9, column: 3, scope: !23, inlinedAt: !32)
+!37 = !MDLocation(line: 10, column: 3, scope: !23, inlinedAt: !32)
+!38 = !MDLocation(line: 17, column: 1, scope: !33)
!39 = !{!0, !6}
!40 = !{!19}
!41 = !{!9, !18}
diff --git a/llvm/test/DebugInfo/X86/dbg-value-isel.ll b/llvm/test/DebugInfo/X86/dbg-value-isel.ll
index 35729513bf3..a908b322d76 100644
--- a/llvm/test/DebugInfo/X86/dbg-value-isel.ll
+++ b/llvm/test/DebugInfo/X86/dbg-value-isel.ll
@@ -90,16 +90,16 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
!6 = !{!"0x16\00uint\000\000\000\000\000", !20, !2, !7} ; [ DW_TAG_typedef ]
!7 = !{!"0x24\00unsigned int\000\0032\0032\000\000\007", null, !2} ; [ DW_TAG_base_type ]
!8 = !{!"0x101\00ip\001\000", !0, !1, !5} ; [ DW_TAG_arg_variable ]
-!9 = !{i32 1, i32 32, !0, null}
+!9 = !MDLocation(line: 1, column: 32, scope: !0)
!10 = !{!"0x100\00tid\003\000", !11, !1, !6} ; [ DW_TAG_auto_variable ]
!11 = !{!"0xb\002\001\001", !1, !0} ; [ DW_TAG_lexical_block ]
-!12 = !{i32 5, i32 24, !11, null}
+!12 = !MDLocation(line: 5, column: 24, scope: !11)
!13 = !{!"0x100\00gid\003\000", !11, !1, !6} ; [ DW_TAG_auto_variable ]
-!14 = !{i32 6, i32 25, !11, null}
+!14 = !MDLocation(line: 6, column: 25, scope: !11)
!15 = !{!"0x100\00lsz\003\000", !11, !1, !6} ; [ DW_TAG_auto_variable ]
-!16 = !{i32 7, i32 26, !11, null}
-!17 = !{i32 9, i32 24, !11, null}
-!18 = !{i32 10, i32 1, !0, null}
+!16 = !MDLocation(line: 7, column: 26, scope: !11)
+!17 = !MDLocation(line: 9, column: 24, scope: !11)
+!18 = !MDLocation(line: 10, column: 1, scope: !0)
!19 = !{!0}
!20 = !{!"OCLlLwTXZ.cl", !"/tmp"}
!21 = !{i32 0}
diff --git a/llvm/test/DebugInfo/X86/dbg-value-location.ll b/llvm/test/DebugInfo/X86/dbg-value-location.ll
index 9365310dac8..015ec89ec4c 100644
--- a/llvm/test/DebugInfo/X86/dbg-value-location.ll
+++ b/llvm/test/DebugInfo/X86/dbg-value-location.ll
@@ -63,14 +63,14 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
!10 = !{!11}
!11 = !{!"0x24\00unsigned char\000\008\008\000\000\008", null, !2} ; [ DW_TAG_base_type ]
!12 = !{!"0x101\00var\0019509\000", !0, !1, !5} ; [ DW_TAG_arg_variable ]
-!13 = !{i32 19509, i32 20, !0, null}
-!14 = !{i32 18091, i32 2, !15, !17}
+!13 = !MDLocation(line: 19509, column: 20, scope: !0)
+!14 = !MDLocation(line: 18091, column: 2, scope: !15, inlinedAt: !17)
!15 = !{!"0xb\0018086\001\00748", !26, !16} ; [ DW_TAG_lexical_block ]
!16 = !{!"0x2e\00foo_bar\00foo_bar\00\0018086\001\001\000\006\00256\001\000", !26, !1, !3, null, null, null, null, null} ; [ DW_TAG_subprogram ] [line 18086] [local] [def] [scope 0] [foo_bar]
-!17 = !{i32 19514, i32 2, !18, null}
+!17 = !MDLocation(line: 19514, column: 2, scope: !18)
!18 = !{!"0xb\0019510\001\0099", !26, !0} ; [ DW_TAG_lexical_block ]
-!22 = !{i32 18094, i32 2, !15, !17}
-!23 = !{i32 19524, i32 1, !18, null}
+!22 = !MDLocation(line: 18094, column: 2, scope: !15, inlinedAt: !17)
+!23 = !MDLocation(line: 19524, column: 1, scope: !18)
!24 = !{!0, !6, !7, !8, !16}
!25 = !{!"0x29", !27} ; [ DW_TAG_file_type ]
!26 = !{!"/tmp/f.c", !"/tmp"}
diff --git a/llvm/test/DebugInfo/X86/dbg-value-range.ll b/llvm/test/DebugInfo/X86/dbg-value-range.ll
index 608b15782f7..727f906e1a2 100644
--- a/llvm/test/DebugInfo/X86/dbg-value-range.ll
+++ b/llvm/test/DebugInfo/X86/dbg-value-range.ll
@@ -33,10 +33,10 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
!10 = !{!"0xd\00c\002\0032\0032\000\000", !22, !1, !5} ; [ DW_TAG_member ]
!11 = !{!"0x100\00x\006\000", !12, !1, !5} ; [ DW_TAG_auto_variable ]
!12 = !{!"0xb\005\0022\000", !22, !0} ; [ DW_TAG_lexical_block ]
-!13 = !{i32 5, i32 19, !0, null}
-!14 = !{i32 6, i32 14, !12, null}
-!18 = !{i32 7, i32 2, !12, null}
-!19 = !{i32 8, i32 2, !12, null}
+!13 = !MDLocation(line: 5, column: 19, scope: !0)
+!14 = !MDLocation(line: 6, column: 14, scope: !12)
+!18 = !MDLocation(line: 7, column: 2, scope: !12)
+!19 = !MDLocation(line: 8, column: 2, scope: !12)
!20 = !{!0}
!21 = !{!6, !11}
!22 = !{!"bar.c", !"/private/tmp"}
diff --git a/llvm/test/DebugInfo/X86/dbg-value-terminator.ll b/llvm/test/DebugInfo/X86/dbg-value-terminator.ll
index 94e9a248f50..0653bde62e9 100644
--- a/llvm/test/DebugInfo/X86/dbg-value-terminator.ll
+++ b/llvm/test/DebugInfo/X86/dbg-value-terminator.ll
@@ -125,7 +125,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
!9 = !{!"0x24\00char\000\008\008\000\000\006", null, !0} ; [ DW_TAG_base_type ]
!10 = !{!"0x100\00a\003\000", !11, !2, !9} ; [ DW_TAG_auto_variable ]
!11 = !{!"0xb\002\0025\000", !20, !1} ; [ DW_TAG_lexical_block ]
-!12 = !{i32 2, i32 13, !1, null}
+!12 = !MDLocation(line: 2, column: 13, scope: !1)
!18 = !{!1}
!19 = !{!6, !7, !10}
!20 = !{!"a.c", !"/private/tmp"}
diff --git a/llvm/test/DebugInfo/X86/dbg_value_direct.ll b/llvm/test/DebugInfo/X86/dbg_value_direct.ll
index 55aabdf351e..69c9e99519b 100644
--- a/llvm/test/DebugInfo/X86/dbg_value_direct.ll
+++ b/llvm/test/DebugInfo/X86/dbg_value_direct.ll
@@ -172,7 +172,7 @@ attributes #2 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n
!22 = !{i32 2, !"Dwarf Version", i32 3}
!23 = !{!"0x101\00\0016777222\000", !4, !5, !21} ; [ DW_TAG_arg_variable ] [line 6]
!24 = !{!"0x100\00a\007\008192", !4, !5, !8} ; [ DW_TAG_auto_variable ] [a] [line 7]
-!25 = !{i32 7, i32 0, !4, null}
-!26 = !{i32 8, i32 0, !4, null}
+!25 = !MDLocation(line: 7, scope: !4)
+!26 = !MDLocation(line: 8, scope: !4)
!27 = !{i32 1, !"Debug Info Version", i32 2}
!28 = !{!"0x102\006"} ; [ DW_TAG_expression ] [DW_OP_deref]
diff --git a/llvm/test/DebugInfo/X86/debug-dead-local-var.ll b/llvm/test/DebugInfo/X86/debug-dead-local-var.ll
index 4867a7fbaee..6733dd86669 100644
--- a/llvm/test/DebugInfo/X86/debug-dead-local-var.ll
+++ b/llvm/test/DebugInfo/X86/debug-dead-local-var.ll
@@ -48,4 +48,4 @@ attributes #0 = { nounwind readnone uwtable "less-precise-fpmad"="false" "no-fra
!18 = !{i32 2, !"Dwarf Version", i32 4}
!19 = !{i32 2, !"Debug Info Version", i32 2}
!20 = !{!"clang version 3.5.0 (trunk 209255) (llvm/trunk 209253)"}
-!21 = !{i32 13, i32 0, !4, null}
+!21 = !MDLocation(line: 13, scope: !4)
diff --git a/llvm/test/DebugInfo/X86/debug-info-access.ll b/llvm/test/DebugInfo/X86/debug-info-access.ll
index dc2f1f05162..7727384d6f7 100644
--- a/llvm/test/DebugInfo/X86/debug-info-access.ll
+++ b/llvm/test/DebugInfo/X86/debug-info-access.ll
@@ -147,4 +147,4 @@ attributes #0 = { nounwind ssp uwtable }
!38 = !{i32 2, !"Dwarf Version", i32 2}
!39 = !{i32 2, !"Debug Info Version", i32 2}
!40 = !{!"clang version 3.6.0 "}
-!41 = !{i32 35, i32 14, !30, null}
+!41 = !MDLocation(line: 35, column: 14, scope: !30)
diff --git a/llvm/test/DebugInfo/X86/debug-info-block-captured-self.ll b/llvm/test/DebugInfo/X86/debug-info-block-captured-self.ll
index 2c5d07c65de..b7d6dd486bc 100644
--- a/llvm/test/DebugInfo/X86/debug-info-block-captured-self.ll
+++ b/llvm/test/DebugInfo/X86/debug-info-block-captured-self.ll
@@ -100,12 +100,12 @@ define internal void @"__24-[Main initWithContext:]_block_invoke_2"(i8* %.block_
!40 = !{null, !41, !27}
!41 = !{!"0xf\00\000\0064\0064\000\000", null, null, null} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from ]
!42 = !{!"0x2e\00__24-[Main initWithContext:]_block_invoke_2\00__24-[Main initWithContext:]_block_invoke_2\00\0035\001\001\000\006\00256\000\0035", !1, !1, !39, null, void (i8*, i8*)* @"__24-[Main initWithContext:]_block_invoke_2", null, null, !15} ; [ DW_TAG_subprogram ] [line 35] [local] [def] [__24-[Main initWithContext:]_block_invoke_2]
-!84 = !{i32 33, i32 0, !38, null}
+!84 = !MDLocation(line: 33, scope: !38)
!86 = !{!"0x100\00self\0041\000", !38, !1, !34} ; [ DW_TAG_auto_variable ] [self] [line 41]
-!87 = !{i32 41, i32 0, !38, null}
-!103 = !{i32 35, i32 0, !42, null}
+!87 = !MDLocation(line: 41, scope: !38)
+!103 = !MDLocation(line: 35, scope: !42)
!105 = !{!"0x100\00self\0040\000", !42, !1, !34} ; [ DW_TAG_auto_variable ] [self] [line 40]
-!106 = !{i32 40, i32 0, !42, null}
+!106 = !MDLocation(line: 40, scope: !42)
!107 = !{!"llvm/tools/clang/test/CodeGenObjC/debug-info-block-captured-self.m", !""}
!108 = !{i32 1, !"Debug Info Version", i32 2}
!109 = !{!"0x102\0034\0032"} ; [ DW_TAG_expression ] [DW_OP_plus 32]
diff --git a/llvm/test/DebugInfo/X86/debug-info-blocks.ll b/llvm/test/DebugInfo/X86/debug-info-blocks.ll
index 6fa8cf96efa..7cba57f6991 100644
--- a/llvm/test/DebugInfo/X86/debug-info-blocks.ll
+++ b/llvm/test/DebugInfo/X86/debug-info-blocks.ll
@@ -332,20 +332,20 @@ attributes #3 = { nounwind }
!59 = !{i32 4, !"Objective-C Garbage Collection", i32 0}
!60 = !{!"0x101\00self\0016777262\001088", !13, !32, !61} ; [ DW_TAG_arg_variable ] [self] [line 46]
!61 = !{!"0xf\00\000\0064\0064\000\000", null, null, !4} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from A]
-!62 = !{i32 46, i32 0, !13, null}
+!62 = !MDLocation(line: 46, scope: !13)
!63 = !{!"0x101\00_cmd\0033554478\0064", !13, !32, !64} ; [ DW_TAG_arg_variable ] [_cmd] [line 46]
!64 = !{!"0x16\00SEL\0046\000\000\000\000", !5, null, !25} ; [ DW_TAG_typedef ] [SEL] [line 46, size 0, align 0, offset 0] [from ]
-!65 = !{i32 48, i32 0, !66, null}
+!65 = !MDLocation(line: 48, scope: !66)
!66 = !{!"0xb\0047\000\000", !5, !13} ; [ DW_TAG_lexical_block ] [llvm/tools/clang/test/CodeGenObjC/debug-info-blocks.m]
!67 = !{}
-!68 = !{i32 49, i32 0, !69, null}
+!68 = !MDLocation(line: 49, scope: !69)
!69 = !{!"0xb\0048\000\001", !5, !66} ; [ DW_TAG_lexical_block ] [llvm/tools/clang/test/CodeGenObjC/debug-info-blocks.m]
-!70 = !{i32 53, i32 0, !69, null}
-!71 = !{i32 54, i32 0, !66, null}
+!70 = !MDLocation(line: 53, scope: !69)
+!71 = !MDLocation(line: 54, scope: !66)
!72 = !{!"0x101\00block\0016777255\000", !39, !6, !42} ; [ DW_TAG_arg_variable ] [block] [line 39]
-!73 = !{i32 39, i32 0, !39, null}
-!74 = !{i32 41, i32 0, !39, null}
-!75 = !{i32 42, i32 0, !39, null}
+!73 = !MDLocation(line: 39, scope: !39)
+!74 = !MDLocation(line: 41, scope: !39)
+!75 = !MDLocation(line: 42, scope: !39)
!76 = !{!"0x101\00.block_descriptor\0016777265\0064", !27, !6, !77} ; [ DW_TAG_arg_variable ] [.block_descriptor] [line 49]
!77 = !{!"0xf\00\000\0064\000\000\000", null, null, !78} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 0, offset 0] [from __block_literal_1]
!78 = !{!"0x13\00__block_literal_1\0049\00320\0064\000\000\000", !5, !6, null, !79, null, null, null} ; [ DW_TAG_structure_type ] [__block_literal_1] [line 49, size 320, align 64, offset 0] [def] [from ]
@@ -358,9 +358,9 @@ attributes #3 = { nounwind }
!85 = !{!"0xf\00\000\0064\0064\000\000", null, null, !86} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from __block_descriptor_withcopydispose]
!86 = !{!"0x13\00__block_descriptor_withcopydispose\0049\000\000\000\004\000", !1, null, null, null, null, null, null} ; [ DW_TAG_structure_type ] [__block_descriptor_withcopydispose] [line 49, size 0, align 0, offset 0] [decl] [from ]
!87 = !{!"0xd\00self\0049\0064\0064\00256\000", !5, !6, !61} ; [ DW_TAG_member ] [self] [line 49, size 64, align 64, offset 256] [from ]
-!88 = !{i32 49, i32 0, !27, null}
+!88 = !MDLocation(line: 49, scope: !27)
!89 = !{!"0x100\00self\0052\000", !27, !32, !23} ; [ DW_TAG_auto_variable ] [self] [line 52]
-!90 = !{i32 52, i32 0, !27, null}
+!90 = !MDLocation(line: 52, scope: !27)
!91 = !{!"0x100\00d\0050\000", !92, !6, !93} ; [ DW_TAG_auto_variable ] [d] [line 50]
!92 = !{!"0xb\0049\000\002", !5, !27} ; [ DW_TAG_lexical_block ] [llvm/tools/clang/test/CodeGenObjC/debug-info-blocks.m]
!93 = !{!"0xf\00\000\0064\0064\000\000", null, null, !94} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from NSMutableDictionary]
@@ -370,15 +370,15 @@ attributes #3 = { nounwind }
!97 = !{!"0x13\00NSDictionary\0026\000\008\000\000\0016", !5, !6, null, !98, null, null, null} ; [ DW_TAG_structure_type ] [NSDictionary] [line 26, size 0, align 8, offset 0] [def] [from ]
!98 = !{!99}
!99 = !{!"0x1c\00\000\000\000\000\000", null, !97, !9} ; [ DW_TAG_inheritance ] [line 0, size 0, align 0, offset 0] [from NSObject]
-!100 = !{i32 50, i32 0, !92, null}
-!101 = !{i32 51, i32 0, !92, null}
+!100 = !MDLocation(line: 50, scope: !92)
+!101 = !MDLocation(line: 51, scope: !92)
!102 = !{!"0x101\00\0016777268\001088", !31, !32, !30} ; [ DW_TAG_arg_variable ] [line 52]
-!103 = !{i32 52, i32 0, !31, null}
+!103 = !MDLocation(line: 52, scope: !31)
!104 = !{!"0x101\00\0033554484\0064", !31, !32, !30} ; [ DW_TAG_arg_variable ] [line 52]
!105 = !{!"0x101\00\0016777268\001088", !35, !32, !30} ; [ DW_TAG_arg_variable ] [line 52]
-!106 = !{i32 52, i32 0, !35, null}
+!106 = !MDLocation(line: 52, scope: !35)
!107 = !{!"0x100\00a\0061\000", !36, !6, !61} ; [ DW_TAG_auto_variable ] [a] [line 61]
-!108 = !{i32 61, i32 0, !36, null}
-!109 = !{i32 62, i32 0, !36, null}
+!108 = !MDLocation(line: 61, scope: !36)
+!109 = !MDLocation(line: 62, scope: !36)
!110 = !{i32 1, !"Debug Info Version", i32 2}
!111 = !{!"0x102\006\0034\0032"} ; [ DW_TAG_expression ] [DW_OP_deref DW_OP_plus 32]
diff --git a/llvm/test/DebugInfo/X86/debug-info-static-member.ll b/llvm/test/DebugInfo/X86/debug-info-static-member.ll
index 129027d21ba..8a14b6ad19c 100644
--- a/llvm/test/DebugInfo/X86/debug-info-static-member.ll
+++ b/llvm/test/DebugInfo/X86/debug-info-static-member.ll
@@ -86,9 +86,9 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
!27 = !{!"0x34\00b\00b\00_ZN1C1bE\0015\000\001", null, !6, !9, i32* @_ZN1C1bE, !19} ; [ DW_TAG_variable ] [b] [line 15] [def]
!28 = !{!"0x34\00c\00c\00_ZN1C1cE\0016\000\001", null, !6, !9, i32* @_ZN1C1cE, !23} ; [ DW_TAG_variable ] [c] [line 16] [def]
!29 = !{!"0x100\00instance_C\0020\000", !5, !6, !13} ; [ DW_TAG_auto_variable ] [instance_C] [line 20]
-!30 = !{i32 20, i32 0, !5, null}
-!31 = !{i32 21, i32 0, !5, null}
-!32 = !{i32 22, i32 0, !5, null}
+!30 = !MDLocation(line: 20, scope: !5)
+!31 = !MDLocation(line: 21, scope: !5)
+!32 = !MDLocation(line: 22, scope: !5)
!33 = !{!"/usr/local/google/home/blaikie/Development/llvm/src/tools/clang/test/CodeGenCXX/debug-info-static-member.cpp", !"/home/blaikie/local/Development/llvm/build/clang/x86-64/Debug/llvm"}
; PRESENT verifies that static member declarations have these attributes:
; external, declaration, accessibility, and either DW_AT_MIPS_linkage_name
diff --git a/llvm/test/DebugInfo/X86/debug-loc-asan.ll b/llvm/test/DebugInfo/X86/debug-loc-asan.ll
index 0e7ebca7a38..13e193bdf11 100644
--- a/llvm/test/DebugInfo/X86/debug-loc-asan.ll
+++ b/llvm/test/DebugInfo/X86/debug-loc-asan.ll
@@ -178,5 +178,5 @@ attributes #1 = { nounwind readnone }
!10 = !{i32 2, !"Debug Info Version", i32 2}
!11 = !{!"clang version 3.5.0 (209308)"}
!12 = !{!"0x101\00y\0016777217\000", !4, !5, !8} ; [ DW_TAG_arg_variable ] [y] [line 1]
-!13 = !{i32 2, i32 0, !4, null}
+!13 = !MDLocation(line: 2, scope: !4)
!14 = !{!"0x102\006"} ; [ DW_TAG_expression ] [DW_OP_deref]
diff --git a/llvm/test/DebugInfo/X86/debug-loc-offset.ll b/llvm/test/DebugInfo/X86/debug-loc-offset.ll
index 5d387326f66..9022891e06f 100644
--- a/llvm/test/DebugInfo/X86/debug-loc-offset.ll
+++ b/llvm/test/DebugInfo/X86/debug-loc-offset.ll
@@ -138,16 +138,16 @@ attributes #2 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n
!19 = !{i32 2, !"Debug Info Version", i32 2}
!20 = !{!"clang version 3.5.0 (210479)"}
!21 = !{!"0x101\00b\0016777217\000", !4, !5, !8} ; [ DW_TAG_arg_variable ] [b] [line 1]
-!22 = !{i32 1, i32 0, !4, null}
-!23 = !{i32 2, i32 0, !4, null}
+!22 = !MDLocation(line: 1, scope: !4)
+!23 = !MDLocation(line: 2, scope: !4)
!24 = !{!"0x101\00a\0016777222\008192", !14, !15, !"_ZTS1A"} ; [ DW_TAG_arg_variable ] [a] [line 6]
-!25 = !{i32 6, i32 0, !14, null}
+!25 = !MDLocation(line: 6, scope: !14)
!26 = !{!"0x100\00z\007\000", !14, !15, !8} ; [ DW_TAG_auto_variable ] [z] [line 7]
-!27 = !{i32 7, i32 0, !14, null}
-!28 = !{i32 8, i32 0, !29, null}
+!27 = !MDLocation(line: 7, scope: !14)
+!28 = !MDLocation(line: 8, scope: !29)
!29 = !{!"0xb\008\000\000", !10, !14} ; [ DW_TAG_lexical_block ] [/llvm_cmake_gcc/debug-loc-offset2.cc]
-!30 = !{i32 9, i32 0, !29, null}
-!31 = !{i32 10, i32 0, !32, null}
+!30 = !MDLocation(line: 9, scope: !29)
+!31 = !MDLocation(line: 10, scope: !32)
!32 = !{!"0xb\0010\000\000", !10, !14} ; [ DW_TAG_lexical_block ] [/llvm_cmake_gcc/debug-loc-offset2.cc]
-!33 = !{i32 11, i32 0, !32, null}
-!34 = !{i32 12, i32 0, !14, null}
+!33 = !MDLocation(line: 11, scope: !32)
+!34 = !MDLocation(line: 12, scope: !14)
diff --git a/llvm/test/DebugInfo/X86/debug-ranges-offset.ll b/llvm/test/DebugInfo/X86/debug-ranges-offset.ll
index 9adf7f07b79..fd8fe0e11f3 100644
--- a/llvm/test/DebugInfo/X86/debug-ranges-offset.ll
+++ b/llvm/test/DebugInfo/X86/debug-ranges-offset.ll
@@ -221,8 +221,8 @@ attributes #4 = { builtin }
!16 = !{i32 2, !"Dwarf Version", i32 4}
!17 = !{i32 1, !"Debug Info Version", i32 2}
!18 = !{!"clang version 3.5.0 (trunk 207243) (llvm/trunk 207259)"}
-!19 = !{i32 4, i32 0, !4, null}
-!20 = !{i32 5, i32 0, !21, null}
+!19 = !MDLocation(line: 4, scope: !4)
+!20 = !MDLocation(line: 5, scope: !21)
!21 = !{!"0xb\005\000\000", !1, !4} ; [ DW_TAG_lexical_block ] [/usr/local/google/home/echristo/tmp/foo.cpp]
!22 = !{!"branch_weights", i32 1000, i32 1}
!23 = !{!24, !24, i64 0}
@@ -230,12 +230,12 @@ attributes #4 = { builtin }
!25 = !{!"omnipotent char", !26, i64 0}
!26 = !{!"Simple C/C++ TBAA"}
!27 = !{!"branch_weights", i32 1, i32 1000}
-!28 = !{i32 6, i32 0, !21, null}
-!29 = !{i32 7, i32 0, !4, null}
-!30 = !{i32 4, i32 0, !4, !31}
-!31 = !{i32 10, i32 0, !13, null}
+!28 = !MDLocation(line: 6, scope: !21)
+!29 = !MDLocation(line: 7, scope: !4)
+!30 = !MDLocation(line: 4, scope: !4, inlinedAt: !31)
+!31 = !MDLocation(line: 10, scope: !13)
!32 = !{!"0x100\00p\004\000", !4, !5, !10, !31} ; [ DW_TAG_auto_variable ] [p] [line 4]
-!33 = !{i32 5, i32 0, !21, !31}
-!34 = !{i32 6, i32 0, !21, !31}
-!35 = !{i32 7, i32 0, !4, !31}
-!36 = !{i32 11, i32 0, !13, null}
+!33 = !MDLocation(line: 5, scope: !21, inlinedAt: !31)
+!34 = !MDLocation(line: 6, scope: !21, inlinedAt: !31)
+!35 = !MDLocation(line: 7, scope: !4, inlinedAt: !31)
+!36 = !MDLocation(line: 11, scope: !13)
diff --git a/llvm/test/DebugInfo/X86/decl-derived-member.ll b/llvm/test/DebugInfo/X86/decl-derived-member.ll
index 495c938188c..8c15c53e814 100644
--- a/llvm/test/DebugInfo/X86/decl-derived-member.ll
+++ b/llvm/test/DebugInfo/X86/decl-derived-member.ll
@@ -127,18 +127,18 @@ attributes #4 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n
!32 = !{i32 2, !"Dwarf Version", i32 4}
!33 = !{i32 1, !"Debug Info Version", i32 2}
!34 = !{!"clang version 3.5.0 (trunk 203673) (llvm/trunk 203681)"}
-!35 = !{i32 9, i32 0, !9, null}
+!35 = !MDLocation(line: 9, scope: !9)
!36 = !{!"0x101\00this\0016777216\001088", !19, null, !37} ; [ DW_TAG_arg_variable ] [this] [line 0]
!37 = !{!"0xf\00\000\0064\0064\000\000", null, null, !"_ZTS3foo"} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from _ZTS3foo]
-!38 = !{i32 0, i32 0, !19, null}
-!39 = !{i32 5, i32 0, !19, null}
+!38 = !MDLocation(line: 0, scope: !19)
+!39 = !MDLocation(line: 5, scope: !19)
!40 = !{!"0x101\00this\0016777216\001088", !13, null, !37} ; [ DW_TAG_arg_variable ] [this] [line 0]
-!41 = !{i32 0, i32 0, !13, null}
-!42 = !{i32 5, i32 0, !43, null}
+!41 = !MDLocation(line: 0, scope: !13)
+!42 = !MDLocation(line: 5, scope: !43)
!43 = !{!"0xb\005\000\000", !1, !13} ; [ DW_TAG_lexical_block ] [/usr/local/google/home/echristo/foo.cc]
-!44 = !{i32 5, i32 0, !13, null}
+!44 = !MDLocation(line: 5, scope: !13)
!45 = !{!"0x101\00this\0016777216\001088", !22, null, !46} ; [ DW_TAG_arg_variable ] [this] [line 0]
!46 = !{!"0xf\00\000\0064\0064\000\000", null, null, !"_ZTS4base"} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from _ZTS4base]
-!47 = !{i32 0, i32 0, !22, null}
-!48 = !{i32 1, i32 0, !22, null}
-!49 = !{i32 1, i32 0, !28, null}
+!47 = !MDLocation(line: 0, scope: !22)
+!48 = !MDLocation(line: 1, scope: !22)
+!49 = !MDLocation(line: 1, scope: !28)
diff --git a/llvm/test/DebugInfo/X86/discriminator.ll b/llvm/test/DebugInfo/X86/discriminator.ll
index 0f4a84d2207..185f7cd2416 100644
--- a/llvm/test/DebugInfo/X86/discriminator.ll
+++ b/llvm/test/DebugInfo/X86/discriminator.ll
@@ -51,11 +51,11 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe
!7 = !{i32 2, !"Dwarf Version", i32 4}
!8 = !{i32 1, !"Debug Info Version", i32 2}
!9 = !{!"clang version 3.5 "}
-!10 = !{i32 2, i32 0, !11, null}
+!10 = !MDLocation(line: 2, scope: !11)
!11 = !{!"0xb\002\000\000", !1, !4} ; [ DW_TAG_lexical_block ] [./discriminator.c]
-!12 = !{i32 3, i32 0, !4, null}
-!13 = !{i32 4, i32 0, !4, null}
-!14 = !{i32 2, i32 0, !15, null}
+!12 = !MDLocation(line: 3, scope: !4)
+!13 = !MDLocation(line: 4, scope: !4)
+!14 = !MDLocation(line: 2, scope: !15)
!15 = !{!"0xb\0042", !1, !4} ; [ DW_TAG_lexical_block ] [./discriminator.c]
; CHECK: Address Line Column File ISA Discriminator Flags
diff --git a/llvm/test/DebugInfo/X86/dwarf-aranges-no-dwarf-labels.ll b/llvm/test/DebugInfo/X86/dwarf-aranges-no-dwarf-labels.ll
index 02b03ad796f..1bda8ec7984 100644
--- a/llvm/test/DebugInfo/X86/dwarf-aranges-no-dwarf-labels.ll
+++ b/llvm/test/DebugInfo/X86/dwarf-aranges-no-dwarf-labels.ll
@@ -80,9 +80,9 @@ attributes #2 = { nounwind readnone }
!17 = !{!18}
!18 = !{!"0x34\00global\00global\00\001\000\001", null, !5, !8, i32* @global, null} ; [ DW_TAG_variable ] [global] [line 1] [def]
!19 = !{i32 2, !"Dwarf Version", i32 4}
-!20 = !{i32 2, i32 0, !4, null}
-!21 = !{i32 3, i32 0, !11, null}
-!22 = !{i32 6, i32 0, !14, null}
+!20 = !MDLocation(line: 2, scope: !4)
+!21 = !MDLocation(line: 3, scope: !11)
+!22 = !MDLocation(line: 6, scope: !14)
!23 = !{!"int", !24}
!24 = !{!"omnipotent char", !25}
!25 = !{!"Simple C/C++ TBAA"}
diff --git a/llvm/test/DebugInfo/X86/dwarf-aranges.ll b/llvm/test/DebugInfo/X86/dwarf-aranges.ll
index 28fb9e58344..6873e58eab5 100644
--- a/llvm/test/DebugInfo/X86/dwarf-aranges.ll
+++ b/llvm/test/DebugInfo/X86/dwarf-aranges.ll
@@ -76,6 +76,6 @@ entry:
!11 = !{!"0x34\00some_other\00some_other\00\003\000\001", null, !5, !10, i32* @some_other, null} ; [ DW_TAG_variable ] [some_other] [line 3] [def]
!12 = !{!"0x34\00some_bss\00some_bss\00\002\000\001", null, !5, !10, i32* @some_bss, null} ; [ DW_TAG_variable ] [some_bss] [line 2] [def]
!13 = !{i32 2, !"Dwarf Version", i32 4}
-!14 = !{i32 7, i32 0, !4, null}
-!15 = !{i32 8, i32 0, !4, null}
+!14 = !MDLocation(line: 7, scope: !4)
+!15 = !MDLocation(line: 8, scope: !4)
!16 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/dwarf-public-names.ll b/llvm/test/DebugInfo/X86/dwarf-public-names.ll
index b353442a691..778738ccb5f 100644
--- a/llvm/test/DebugInfo/X86/dwarf-public-names.ll
+++ b/llvm/test/DebugInfo/X86/dwarf-public-names.ll
@@ -124,12 +124,12 @@ attributes #1 = { nounwind readnone }
!27 = !{!"0x34\00global_namespace_variable\00global_namespace_variable\00_ZN2ns25global_namespace_variableE\0027\000\001", !21, !4, !11, i32* @_ZN2ns25global_namespace_variableE, null} ; [ DW_TAG_variable ] [global_namespace_variable] [line 27] [def]
!28 = !{!"0x101\00this\0016777225\001088", !3, !4, !29} ; [ DW_TAG_arg_variable ] [this] [line 9]
!29 = !{!"0xf\00\000\0064\0064\000\000", null, null, !8} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from C]
-!30 = !{i32 9, i32 0, !3, null}
-!31 = !{i32 10, i32 0, !3, null}
-!32 = !{i32 11, i32 0, !3, null}
-!33 = !{i32 14, i32 0, !18, null}
-!34 = !{i32 20, i32 0, !19, null}
-!35 = !{i32 25, i32 0, !20, null}
-!36 = !{i32 26, i32 0, !20, null}
+!30 = !MDLocation(line: 9, scope: !3)
+!31 = !MDLocation(line: 10, scope: !3)
+!32 = !MDLocation(line: 11, scope: !3)
+!33 = !MDLocation(line: 14, scope: !18)
+!34 = !MDLocation(line: 20, scope: !19)
+!35 = !MDLocation(line: 25, scope: !20)
+!36 = !MDLocation(line: 26, scope: !20)
!37 = !{!"dwarf-public-names.cpp", !"/usr2/kparzysz/s.hex/t"}
!38 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/dwarf-pubnames-split.ll b/llvm/test/DebugInfo/X86/dwarf-pubnames-split.ll
index 62d411689f2..fc99474badd 100644
--- a/llvm/test/DebugInfo/X86/dwarf-pubnames-split.ll
+++ b/llvm/test/DebugInfo/X86/dwarf-pubnames-split.ll
@@ -34,5 +34,5 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe
!7 = !{!8}
!8 = !{!"0x24\00int\000\0032\0032\000\000\005", null, null} ; [ DW_TAG_base_type ] [int] [line 0, size 32, align 32, offset 0, enc DW_ATE_signed]
!9 = !{i32 2, !"Dwarf Version", i32 3}
-!10 = !{i32 2, i32 0, !4, null}
+!10 = !MDLocation(line: 2, scope: !4)
!11 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/elf-names.ll b/llvm/test/DebugInfo/X86/elf-names.ll
index 9477f9e8181..910a6744777 100644
--- a/llvm/test/DebugInfo/X86/elf-names.ll
+++ b/llvm/test/DebugInfo/X86/elf-names.ll
@@ -94,19 +94,19 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
!32 = !{!34, !35}
!34 = !{!"0x101\00this\0016777235\001088", !31, !6, !30} ; [ DW_TAG_arg_variable ] [this] [line 19]
!35 = !{!"0x101\00d\0033554451\000", !31, !6, !23} ; [ DW_TAG_arg_variable ] [d] [line 19]
-!36 = !{i32 12, i32 0, !5, null}
-!37 = !{i32 13, i32 0, !38, null}
+!36 = !MDLocation(line: 12, scope: !5)
+!37 = !MDLocation(line: 13, scope: !38)
!38 = !{!"0xb\0012\000\000", !6, !5} ; [ DW_TAG_lexical_block ] [/usr/local/google/home/echristo/foo.cpp]
-!42 = !{i32 14, i32 0, !38, null}
-!43 = !{i32 15, i32 0, !38, null}
-!44 = !{i32 16, i32 0, !38, null}
-!45 = !{i32 17, i32 0, !38, null}
-!46 = !{i32 19, i32 0, !31, null}
-!47 = !{i32 20, i32 0, !48, null}
+!42 = !MDLocation(line: 14, scope: !38)
+!43 = !MDLocation(line: 15, scope: !38)
+!44 = !MDLocation(line: 16, scope: !38)
+!45 = !MDLocation(line: 17, scope: !38)
+!46 = !MDLocation(line: 19, scope: !31)
+!47 = !MDLocation(line: 20, scope: !48)
!48 = !{!"0xb\0019\000\001", !6, !31} ; [ DW_TAG_lexical_block ] [/usr/local/google/home/echristo/foo.cpp]
-!49 = !{i32 21, i32 0, !48, null}
-!50 = !{i32 22, i32 0, !48, null}
-!51 = !{i32 23, i32 0, !48, null}
-!52 = !{i32 24, i32 0, !48, null}
+!49 = !MDLocation(line: 21, scope: !48)
+!50 = !MDLocation(line: 22, scope: !48)
+!51 = !MDLocation(line: 23, scope: !48)
+!52 = !MDLocation(line: 24, scope: !48)
!53 = !{!"foo.cpp", !"/usr/local/google/home/echristo"}
!54 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/empty-and-one-elem-array.ll b/llvm/test/DebugInfo/X86/empty-and-one-elem-array.ll
index 82ee1072dd5..94e75e4d8bf 100644
--- a/llvm/test/DebugInfo/X86/empty-and-one-elem-array.ll
+++ b/llvm/test/DebugInfo/X86/empty-and-one-elem-array.ll
@@ -80,7 +80,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
!16 = !{!"0x1\00\000\0032\0032\000\000", null, null, !9, !17, i32 0, null, null, null} ; [ DW_TAG_array_type ] [line 0, size 32, align 32, offset 0] [from int]
!17 = !{!18}
!18 = !{!"0x21\000\001"} ; [ DW_TAG_subrange_type ] [0, 1]
-!19 = !{i32 12, i32 0, !11, null}
+!19 = !MDLocation(line: 12, scope: !11)
!20 = !{!"0x100\00my_bar\0013\000", !11, !6, !21} ; [ DW_TAG_auto_variable ] [my_bar] [line 13]
!21 = !{!"0x13\00bar\006\0032\0032\000\000\000", !32, null, null, !22, null, i32 0, null} ; [ DW_TAG_structure_type ] [bar] [line 6, size 32, align 32, offset 0] [def] [from ]
!22 = !{!23, !24}
@@ -89,9 +89,9 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
!25 = !{!"0x1\00\000\000\0032\000\000", null, null, !9, !26, i32 0, null, null, null} ; [ DW_TAG_array_type ] [line 0, size 0, align 32, offset 0] [from int]
!26 = !{!27}
!27 = !{!"0x21\000\000"} ; [ DW_TAG_subrange_type ] [0, 0]
-!28 = !{i32 13, i32 0, !11, null}
-!29 = !{i32 15, i32 0, !11, null}
-!30 = !{i32 16, i32 0, !11, null}
-!31 = !{i32 17, i32 0, !11, null}
+!28 = !MDLocation(line: 13, scope: !11)
+!29 = !MDLocation(line: 15, scope: !11)
+!30 = !MDLocation(line: 16, scope: !11)
+!31 = !MDLocation(line: 17, scope: !11)
!32 = !{!"test.c", !"/Volumes/Sandbox/llvm"}
!33 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/ending-run.ll b/llvm/test/DebugInfo/X86/ending-run.ll
index 2630a287b4f..0b5c77fea6e 100644
--- a/llvm/test/DebugInfo/X86/ending-run.ll
+++ b/llvm/test/DebugInfo/X86/ending-run.ll
@@ -38,11 +38,11 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
!8 = !{!9, !9}
!9 = !{!"0x24\00int\000\0032\0032\000\000\005", null, null} ; [ DW_TAG_base_type ]
!12 = !{!"0x101\00x\0016777221\000", !5, !6, !9} ; [ DW_TAG_arg_variable ]
-!13 = !{i32 5, i32 5, !5, null}
+!13 = !MDLocation(line: 5, column: 5, scope: !5)
!14 = !{!"0x100\00y\008\000", !15, !6, !9} ; [ DW_TAG_auto_variable ]
!15 = !{!"0xb\007\001\000", !19, !5} ; [ DW_TAG_lexical_block ]
-!16 = !{i32 8, i32 9, !15, null}
-!17 = !{i32 8, i32 18, !15, null}
-!18 = !{i32 9, i32 5, !15, null}
+!16 = !MDLocation(line: 8, column: 9, scope: !15)
+!17 = !MDLocation(line: 8, column: 18, scope: !15)
+!18 = !MDLocation(line: 9, column: 5, scope: !15)
!19 = !{!"ending-run.c", !"/Users/echristo/tmp"}
!20 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/fission-inline.ll b/llvm/test/DebugInfo/X86/fission-inline.ll
index 2bfca56fcc2..64999669c5b 100644
--- a/llvm/test/DebugInfo/X86/fission-inline.ll
+++ b/llvm/test/DebugInfo/X86/fission-inline.ll
@@ -112,8 +112,8 @@ attributes #1 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n
!22 = !{i32 2, !"Dwarf Version", i32 4}
!23 = !{i32 2, !"Debug Info Version", i32 2}
!24 = !{!"clang version 3.6.0 "}
-!25 = !{i32 17, i32 5, !20, null}
-!26 = !{i32 11, i32 3, !11, !27}
-!27 = !{i32 18, i32 5, !20, null}
-!28 = !{i32 12, i32 3, !11, !27}
-!29 = !{i32 21, i32 1, !10, null}
+!25 = !MDLocation(line: 17, column: 5, scope: !20)
+!26 = !MDLocation(line: 11, column: 3, scope: !11, inlinedAt: !27)
+!27 = !MDLocation(line: 18, column: 5, scope: !20)
+!28 = !MDLocation(line: 12, column: 3, scope: !11, inlinedAt: !27)
+!29 = !MDLocation(line: 21, column: 1, scope: !10)
diff --git a/llvm/test/DebugInfo/X86/fission-ranges.ll b/llvm/test/DebugInfo/X86/fission-ranges.ll
index 5239ccfa991..400998e9126 100644
--- a/llvm/test/DebugInfo/X86/fission-ranges.ll
+++ b/llvm/test/DebugInfo/X86/fission-ranges.ll
@@ -180,21 +180,21 @@ attributes #1 = { nounwind readnone }
!24 = !{!"0xb\007\000\000", !1, !8} ; [ DW_TAG_lexical_block ] [/usr/local/google/home/echristo/tmp/small.c]
!25 = !{!"0xf\00\000\0064\0064\000\000", null, null, !11} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from int]
!26 = !{i32 2, !"Dwarf Version", i32 4}
-!27 = !{i32 20, i32 0, !4, null}
-!28 = !{i32 21, i32 0, !4, null}
+!27 = !MDLocation(line: 20, scope: !4)
+!28 = !MDLocation(line: 21, scope: !4)
!29 = !{i32 1}
-!30 = !{i32 2, i32 0, !8, null}
-!31 = !{i32 7, i32 0, !24, null}
-!32 = !{i32 13, i32 0, !20, null}
+!30 = !MDLocation(line: 2, scope: !8)
+!31 = !MDLocation(line: 7, scope: !24)
+!32 = !MDLocation(line: 13, scope: !20)
!33 = !{!34, !34, i64 0}
!34 = !{!"int", !35, i64 0}
!35 = !{!"omnipotent char", !36, i64 0}
!36 = !{!"Simple C/C++ TBAA"}
-!37 = !{i32 8, i32 0, !23, null}
-!38 = !{i32 9, i32 0, !22, null}
-!39 = !{i32 10, i32 0, !21, null}
-!40 = !{i32 12, i32 0, !20, null}
+!37 = !MDLocation(line: 8, scope: !23)
+!38 = !MDLocation(line: 9, scope: !22)
+!39 = !MDLocation(line: 10, scope: !21)
+!40 = !MDLocation(line: 12, scope: !20)
!41 = !{i32* @c}
-!42 = !{i32 15, i32 0, !8, null}
+!42 = !MDLocation(line: 15, scope: !8)
!43 = !{i32 1, !"Debug Info Version", i32 2}
!44 = !{i32 0}
diff --git a/llvm/test/DebugInfo/X86/formal_parameter.ll b/llvm/test/DebugInfo/X86/formal_parameter.ll
index 9376214130f..9077c74b29f 100644
--- a/llvm/test/DebugInfo/X86/formal_parameter.ll
+++ b/llvm/test/DebugInfo/X86/formal_parameter.ll
@@ -73,12 +73,12 @@ attributes #3 = { nounwind }
!11 = !{i32 2, !"Dwarf Version", i32 2}
!12 = !{i32 1, !"Debug Info Version", i32 2}
!13 = !{!"clang version 3.5.0 "}
-!14 = !{i32 1, i32 0, !4, null}
+!14 = !MDLocation(line: 1, scope: !4)
!15 = !{!16, !16, i64 0}
!16 = !{!"int", !17, i64 0}
!17 = !{!"omnipotent char", !18, i64 0}
!18 = !{!"Simple C/C++ TBAA"}
-!19 = !{i32 3, i32 0, !4, null}
-!20 = !{i32 4, i32 0, !21, null}
+!19 = !MDLocation(line: 3, scope: !4)
+!20 = !MDLocation(line: 4, scope: !21)
!21 = !{!"0xb\004\000\000", !1, !4} ; [ DW_TAG_lexical_block ] [formal_parameter.c]
-!22 = !{i32 5, i32 0, !4, null}
+!22 = !MDLocation(line: 5, scope: !4)
diff --git a/llvm/test/DebugInfo/X86/generate-odr-hash.ll b/llvm/test/DebugInfo/X86/generate-odr-hash.ll
index 7eb20f96407..6d4fa86697c 100644
--- a/llvm/test/DebugInfo/X86/generate-odr-hash.ll
+++ b/llvm/test/DebugInfo/X86/generate-odr-hash.ll
@@ -267,11 +267,11 @@ attributes #1 = { nounwind readnone }
!45 = !{!"clang version 3.5 "}
!46 = !{!"0x100\00b\007\000", !22, !23, !47} ; [ DW_TAG_auto_variable ] [b] [line 7]
!47 = !{!"0x13\00baz\006\008\008\000\000\000", !1, !22, null, !2, null, null, null} ; [ DW_TAG_structure_type ] [baz] [line 6, size 8, align 8, offset 0] [def] [from ]
-!48 = !{i32 7, i32 0, !22, null}
-!49 = !{i32 8, i32 0, !22, null}
-!50 = !{i32 29, i32 0, !26, null}
+!48 = !MDLocation(line: 7, scope: !22)
+!49 = !MDLocation(line: 8, scope: !22)
+!50 = !MDLocation(line: 29, scope: !26)
!51 = !{!"0x101\00this\0016777216\001088", !27, null, !52} ; [ DW_TAG_arg_variable ] [this] [line 0]
!52 = !{!"0xf\00\000\0064\0064\000\000", null, null, !28} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from walrus]
-!53 = !{i32 0, i32 0, !27, null}
-!54 = !{i32 25, i32 0, !27, null}
-!55 = !{i32 25, i32 0, !36, null}
+!53 = !MDLocation(line: 0, scope: !27)
+!54 = !MDLocation(line: 25, scope: !27)
+!55 = !MDLocation(line: 25, scope: !36)
diff --git a/llvm/test/DebugInfo/X86/ghost-sdnode-dbgvalues.ll b/llvm/test/DebugInfo/X86/ghost-sdnode-dbgvalues.ll
index e996fe0ba21..9391da6da4f 100644
--- a/llvm/test/DebugInfo/X86/ghost-sdnode-dbgvalues.ll
+++ b/llvm/test/DebugInfo/X86/ghost-sdnode-dbgvalues.ll
@@ -86,20 +86,20 @@ attributes #1 = { nounwind readnone }
!15 = !{!"clang version 3.6.0 "}
!16 = !{!"0x101\00a\0016777219\000", !8, !9, !12} ; [ DW_TAG_arg_variable ] [a] [line 3]
!17 = !{!"0x102"} ; [ DW_TAG_expression ]
-!18 = !{i32 3, i32 13, !8, null}
-!19 = !{i32 4, i32 5, !8, null}
+!18 = !MDLocation(line: 3, column: 13, scope: !8)
+!19 = !MDLocation(line: 4, column: 5, scope: !8)
!20 = !{!"0x100\00b\004\000", !8, !9, !12} ; [ DW_TAG_auto_variable ] [b] [line 4]
-!21 = !{i32 4, i32 9, !8, null}
-!22 = !{i32 5, i32 5, !8, null}
+!21 = !MDLocation(line: 4, column: 9, scope: !8)
+!22 = !MDLocation(line: 5, column: 5, scope: !8)
!23 = !{!"0x100\00c\005\000", !8, !9, !12} ; [ DW_TAG_auto_variable ] [c] [line 5]
-!24 = !{i32 5, i32 9, !8, null}
-!25 = !{i32 6, i32 5, !8, null}
+!24 = !MDLocation(line: 5, column: 9, scope: !8)
+!25 = !MDLocation(line: 6, column: 5, scope: !8)
!26 = !{!"0x100\00d\006\000", !8, !9, !12} ; [ DW_TAG_auto_variable ] [d] [line 6]
-!27 = !{i32 6, i32 9, !8, null}
-!28 = !{i32 7, i32 5, !8, null}
+!27 = !MDLocation(line: 6, column: 9, scope: !8)
+!28 = !MDLocation(line: 7, column: 5, scope: !8)
!29 = !{!"0x100\00e\007\000", !8, !9, !12} ; [ DW_TAG_auto_variable ] [e] [line 7]
-!30 = !{i32 7, i32 9, !8, null}
-!31 = !{i32 8, i32 5, !8, null}
+!30 = !MDLocation(line: 7, column: 9, scope: !8)
+!31 = !MDLocation(line: 8, column: 5, scope: !8)
!32 = !{!"0x100\00f\008\000", !8, !9, !12} ; [ DW_TAG_auto_variable ] [f] [line 8]
-!33 = !{i32 8, i32 9, !8, null}
-!34 = !{i32 9, i32 5, !8, null}
+!33 = !MDLocation(line: 8, column: 9, scope: !8)
+!34 = !MDLocation(line: 9, column: 5, scope: !8)
diff --git a/llvm/test/DebugInfo/X86/gnu-public-names.ll b/llvm/test/DebugInfo/X86/gnu-public-names.ll
index d8e1262a17b..7e92b537c89 100644
--- a/llvm/test/DebugInfo/X86/gnu-public-names.ll
+++ b/llvm/test/DebugInfo/X86/gnu-public-names.ll
@@ -322,12 +322,12 @@ attributes #1 = { nounwind readnone }
!49 = !{!"clang version 3.5.0 "}
!50 = !{!"0x101\00this\0016777216\001088", !20, null, !51} ; [ DW_TAG_arg_variable ] [this] [line 0]
!51 = !{!"0xf\00\000\0064\0064\000\000", null, null, !"_ZTS1C"} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from _ZTS1C]
-!52 = !{i32 0, i32 0, !20, null}
-!53 = !{i32 10, i32 0, !20, null}
-!54 = !{i32 11, i32 0, !20, null}
-!55 = !{i32 14, i32 0, !21, null}
-!56 = !{i32 20, i32 0, !22, null}
-!57 = !{i32 25, i32 0, !24, null}
-!58 = !{i32 26, i32 0, !24, null}
-!59 = !{i32 39, i32 0, !27, null}
-!60 = !{i32 55, i32 0, !31, null}
+!52 = !MDLocation(line: 0, scope: !20)
+!53 = !MDLocation(line: 10, scope: !20)
+!54 = !MDLocation(line: 11, scope: !20)
+!55 = !MDLocation(line: 14, scope: !21)
+!56 = !MDLocation(line: 20, scope: !22)
+!57 = !MDLocation(line: 25, scope: !24)
+!58 = !MDLocation(line: 26, scope: !24)
+!59 = !MDLocation(line: 39, scope: !27)
+!60 = !MDLocation(line: 55, scope: !31)
diff --git a/llvm/test/DebugInfo/X86/inline-member-function.ll b/llvm/test/DebugInfo/X86/inline-member-function.ll
index b91e8a58ddd..68a211fcecc 100644
--- a/llvm/test/DebugInfo/X86/inline-member-function.ll
+++ b/llvm/test/DebugInfo/X86/inline-member-function.ll
@@ -88,9 +88,9 @@ attributes #1 = { nounwind readnone }
!20 = !{i32 2, !"Dwarf Version", i32 4}
!21 = !{i32 1, !"Debug Info Version", i32 2}
!22 = !{!"clang version 3.5.0 "}
-!23 = !{i32 8, i32 0, !13, null}
+!23 = !MDLocation(line: 8, scope: !13)
!24 = !{!"0x101\00this\0016777216\001088", !17, null, !25} ; [ DW_TAG_arg_variable ] [this] [line 0]
!25 = !{!"0xf\00\000\0064\0064\000\000", null, null, !"_ZTS3foo"} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from _ZTS3foo]
-!26 = !{i32 0, i32 0, !17, !23}
+!26 = !MDLocation(line: 0, scope: !17, inlinedAt: !23)
!27 = !{!"0x101\00x\0033554434\000", !17, !14, !9} ; [ DW_TAG_arg_variable ] [x] [line 2]
-!28 = !{i32 2, i32 0, !17, !23}
+!28 = !MDLocation(line: 2, scope: !17, inlinedAt: !23)
diff --git a/llvm/test/DebugInfo/X86/inline-seldag-test.ll b/llvm/test/DebugInfo/X86/inline-seldag-test.ll
index 68237d89c2c..8c10e3a859d 100644
--- a/llvm/test/DebugInfo/X86/inline-seldag-test.ll
+++ b/llvm/test/DebugInfo/X86/inline-seldag-test.ll
@@ -65,9 +65,9 @@ attributes #1 = { nounwind readnone }
!14 = !{!"clang version 3.5.0 "}
!15 = !{!"0x100\00x\005\000", !4, !5, !16} ; [ DW_TAG_auto_variable ] [x] [line 5]
!16 = !{!"0x35\00\000\000\000\000\000", null, null, !11} ; [ DW_TAG_volatile_type ] [line 0, size 0, align 0, offset 0] [from int]
-!17 = !{i32 5, i32 0, !4, null}
-!18 = !{i32 6, i32 7, !4, null}
+!17 = !MDLocation(line: 5, scope: !4)
+!18 = !MDLocation(line: 6, column: 7, scope: !4)
!19 = !{!"0x101\00y\0016777217\000", !8, !5, !11} ; [ DW_TAG_arg_variable ] [y] [line 1]
-!20 = !{i32 1, i32 0, !8, !18}
-!21 = !{i32 2, i32 0, !8, !18}
-!22 = !{i32 7, i32 0, !4, null}
+!20 = !MDLocation(line: 1, scope: !8, inlinedAt: !18)
+!21 = !MDLocation(line: 2, scope: !8, inlinedAt: !18)
+!22 = !MDLocation(line: 7, scope: !4)
diff --git a/llvm/test/DebugInfo/X86/instcombine-instrinsics.ll b/llvm/test/DebugInfo/X86/instcombine-instrinsics.ll
index a0f788705df..12b99a35949 100644
--- a/llvm/test/DebugInfo/X86/instcombine-instrinsics.ll
+++ b/llvm/test/DebugInfo/X86/instcombine-instrinsics.ll
@@ -72,8 +72,8 @@ attributes #1 = { nounwind readnone }
!15 = !{!16}
!16 = !{!"0xd\00i\002\0064\0064\000\000", !1, !14, !17} ; [ DW_TAG_member ] [i] [line 2, size 64, align 64, offset 0] [from long int]
!17 = !{!"0x24\00long int\000\0064\0064\000\000\005", null, null} ; [ DW_TAG_base_type ] [long int] [line 0, size 64, align 64, offset 0, enc DW_ATE_signed]
-!18 = !{i32 8, i32 0, !4, null}
-!19 = !{i32 9, i32 0, !4, null}
-!20 = !{i32 10, i32 0, !4, null}
-!21 = !{i32 11, i32 0, !4, null}
-!22 = !{i32 12, i32 0, !4, null}
+!18 = !MDLocation(line: 8, scope: !4)
+!19 = !MDLocation(line: 9, scope: !4)
+!20 = !MDLocation(line: 10, scope: !4)
+!21 = !MDLocation(line: 11, scope: !4)
+!22 = !MDLocation(line: 12, scope: !4)
diff --git a/llvm/test/DebugInfo/X86/lexical_block.ll b/llvm/test/DebugInfo/X86/lexical_block.ll
index e4fe009472b..a9e377a0181 100644
--- a/llvm/test/DebugInfo/X86/lexical_block.ll
+++ b/llvm/test/DebugInfo/X86/lexical_block.ll
@@ -62,6 +62,6 @@ attributes #1 = { nounwind readnone }
!11 = !{!"0x100\00i\002\000", !12, !5, !13} ; [ DW_TAG_auto_variable ] [i] [line 2]
!12 = !{!"0xb\002\000\000", !1, !4} ; [ DW_TAG_lexical_block ] [/tmp/dbginfo/lexical_block.cpp]
!13 = !{!"0x24\00int\000\0032\0032\000\000\005", null, null} ; [ DW_TAG_base_type ] [int] [line 0, size 32, align 32, offset 0, enc DW_ATE_signed]
-!14 = !{i32 2, i32 0, !12, null}
-!15 = !{i32 3, i32 0, !12, null}
-!16 = !{i32 4, i32 0, !4, null}
+!14 = !MDLocation(line: 2, scope: !12)
+!15 = !MDLocation(line: 3, scope: !12)
+!16 = !MDLocation(line: 4, scope: !4)
diff --git a/llvm/test/DebugInfo/X86/line-info.ll b/llvm/test/DebugInfo/X86/line-info.ll
index 00a80608943..e4364268021 100644
--- a/llvm/test/DebugInfo/X86/line-info.ll
+++ b/llvm/test/DebugInfo/X86/line-info.ll
@@ -53,8 +53,8 @@ attributes #1 = { nounwind readnone }
!12 = !{!"0x15\00\000\000\000\000\000\000", i32 0, null, null, !13, null, null, null} ; [ DW_TAG_subroutine_type ] [line 0, size 0, align 0, offset 0] [from ]
!13 = !{!9}
!14 = !{!"0x101\00x\0016777217\000", !4, !6, !9} ; [ DW_TAG_arg_variable ] [x] [line 1]
-!15 = !{i32 1, i32 0, !4, null}
-!16 = !{i32 2, i32 0, !4, null}
-!17 = !{i32 3, i32 0, !18, null}
+!15 = !MDLocation(line: 1, scope: !4)
+!16 = !MDLocation(line: 2, scope: !4)
+!17 = !MDLocation(line: 3, scope: !18)
!18 = !{!"0xb\000", !11, !10} ; [ DW_TAG_lexical_block ] [/usr/local/google/home/blaikie/dev/scratch/list0.c]
!19 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/linkage-name.ll b/llvm/test/DebugInfo/X86/linkage-name.ll
index 27bf476a40d..187ff8bce3a 100644
--- a/llvm/test/DebugInfo/X86/linkage-name.ll
+++ b/llvm/test/DebugInfo/X86/linkage-name.ll
@@ -43,10 +43,10 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
!20 = !{!"0x34\00a\00a\00\009\000\001", null, !6, !11, %class.A* @a, null} ; [ DW_TAG_variable ]
!21 = !{!"0x101\00this\0016777221\0064", !5, !6, !22} ; [ DW_TAG_arg_variable ]
!22 = !{!"0xf\00\000\0064\0064\000\000", null, null, !11} ; [ DW_TAG_pointer_type ]
-!23 = !{i32 5, i32 8, !5, null}
+!23 = !MDLocation(line: 5, column: 8, scope: !5)
!24 = !{!"0x101\00b\0033554437\000", !5, !6, !9} ; [ DW_TAG_arg_variable ]
-!25 = !{i32 5, i32 14, !5, null}
-!26 = !{i32 6, i32 4, !27, null}
+!25 = !MDLocation(line: 5, column: 14, scope: !5)
+!26 = !MDLocation(line: 6, column: 4, scope: !27)
!27 = !{!"0xb\005\0017\000", !6, !5} ; [ DW_TAG_lexical_block ]
!28 = !{!"foo.cpp", !"/Users/echristo"}
!29 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/low-pc-cu.ll b/llvm/test/DebugInfo/X86/low-pc-cu.ll
index 9b097048288..cac572e1b2c 100644
--- a/llvm/test/DebugInfo/X86/low-pc-cu.ll
+++ b/llvm/test/DebugInfo/X86/low-pc-cu.ll
@@ -43,4 +43,4 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe
!8 = !{i32 2, !"Dwarf Version", i32 4}
!9 = !{i32 1, !"Debug Info Version", i32 2}
!10 = !{!"clang version 3.5.0 (trunk 204164) (llvm/trunk 204183)"}
-!11 = !{i32 1, i32 0, !4, null}
+!11 = !MDLocation(line: 1, scope: !4)
diff --git a/llvm/test/DebugInfo/X86/misched-dbg-value.ll b/llvm/test/DebugInfo/X86/misched-dbg-value.ll
index 30ffe0c8b06..709b6b2194e 100644
--- a/llvm/test/DebugInfo/X86/misched-dbg-value.ll
+++ b/llvm/test/DebugInfo/X86/misched-dbg-value.ll
@@ -167,20 +167,20 @@ attributes #1 = { nounwind readnone }
!61 = !{!62}
!62 = !{!"0x21\000\0031"} ; [ DW_TAG_subrange_type ] [0, 30]
!63 = !{!"0x34\00PtrGlbNext\00PtrGlbNext\00\00178\000\001", null, !3, !47, %struct.Record** @PtrGlbNext, null} ; [ DW_TAG_variable ] [PtrGlbNext] [line 178] [def]
-!64 = !{i32 181, i32 0, !12, null}
-!65 = !{i32 182, i32 0, !12, null}
-!66 = !{i32 183, i32 0, !12, null}
-!67 = !{i32 184, i32 0, !12, null}
-!68 = !{i32 189, i32 0, !12, null}
-!69 = !{i32 190, i32 0, !12, null}
-!73 = !{i32 191, i32 0, !12, null}
-!74 = !{i32 192, i32 0, !12, null}
-!75 = !{i32 193, i32 0, !76, null}
+!64 = !MDLocation(line: 181, scope: !12)
+!65 = !MDLocation(line: 182, scope: !12)
+!66 = !MDLocation(line: 183, scope: !12)
+!67 = !MDLocation(line: 184, scope: !12)
+!68 = !MDLocation(line: 189, scope: !12)
+!69 = !MDLocation(line: 190, scope: !12)
+!73 = !MDLocation(line: 191, scope: !12)
+!74 = !MDLocation(line: 192, scope: !12)
+!75 = !MDLocation(line: 193, scope: !76)
!76 = !{!"0xb\00193\000\000", !82, !12} ; [ DW_TAG_lexical_block ] [/Users/manmanren/test-Nov/rdar_13183203/test2/dry.c]
-!77 = !{i32 194, i32 0, !76, null}
-!78 = !{i32 195, i32 0, !12, null}
-!79 = !{i32 196, i32 0, !12, null}
-!80 = !{i32 197, i32 0, !12, null}
-!81 = !{i32 198, i32 0, !12, null}
+!77 = !MDLocation(line: 194, scope: !76)
+!78 = !MDLocation(line: 195, scope: !12)
+!79 = !MDLocation(line: 196, scope: !12)
+!80 = !MDLocation(line: 197, scope: !12)
+!81 = !MDLocation(line: 198, scope: !12)
!82 = !{!"dry.c", !"/Users/manmanren/test-Nov/rdar_13183203/test2"}
!83 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/nodebug_with_debug_loc.ll b/llvm/test/DebugInfo/X86/nodebug_with_debug_loc.ll
index df2ef6c5046..cc9a8747280 100644
--- a/llvm/test/DebugInfo/X86/nodebug_with_debug_loc.ll
+++ b/llvm/test/DebugInfo/X86/nodebug_with_debug_loc.ll
@@ -123,12 +123,12 @@ attributes #3 = { nounwind }
!23 = !{i32 2, !"Dwarf Version", i32 4}
!24 = !{i32 2, !"Debug Info Version", i32 2}
!25 = !{!"clang version 3.5.0 "}
-!26 = !{i32 15, i32 0, !11, null}
+!26 = !MDLocation(line: 15, scope: !11)
!27 = !{!"0x101\00lhs\0016777229\000", !17, !12, !20, !28} ; [ DW_TAG_arg_variable ] [lhs] [line 13]
-!28 = !{i32 16, i32 0, !11, null}
-!29 = !{i32 13, i32 0, !17, !28}
-!30 = !{i32 17, i32 0, !11, null}
-!31 = !{i32 18, i32 0, !11, null}
+!28 = !MDLocation(line: 16, scope: !11)
+!29 = !MDLocation(line: 13, scope: !17, inlinedAt: !28)
+!30 = !MDLocation(line: 17, scope: !11)
+!31 = !MDLocation(line: 18, scope: !11)
!32 = !{!33, !34, i64 0}
!33 = !{!"_ZTS6string", !34, i64 0}
!34 = !{!"any pointer", !35, i64 0}
diff --git a/llvm/test/DebugInfo/X86/objc-property-void.ll b/llvm/test/DebugInfo/X86/objc-property-void.ll
index dd743491cde..0ae9e1a337e 100644
--- a/llvm/test/DebugInfo/X86/objc-property-void.ll
+++ b/llvm/test/DebugInfo/X86/objc-property-void.ll
@@ -98,7 +98,7 @@ attributes #1 = { nounwind readnone }
!23 = !{!""}
!24 = !{!"0x101\00self\0016777216\001088", !10, null, !25} ; [ DW_TAG_arg_variable ] [self] [line 0]
!25 = !{!"0xf\00\000\0064\0064\000\000", null, null, !4} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from Foo]
-!26 = !{i32 0, i32 0, !10, null}
+!26 = !MDLocation(line: 0, scope: !10)
!27 = !{!"0x101\00_cmd\0033554432\0064", !10, null, !28} ; [ DW_TAG_arg_variable ] [_cmd] [line 0]
!28 = !{!"0x16\00SEL\005\000\000\000\000", !5, null, !15} ; [ DW_TAG_typedef ] [SEL] [line 5, size 0, align 0, offset 0] [from ]
-!29 = !{i32 5, i32 0, !10, null}
+!29 = !MDLocation(line: 5, scope: !10)
diff --git a/llvm/test/DebugInfo/X86/op_deref.ll b/llvm/test/DebugInfo/X86/op_deref.ll
index 1352a06089e..2aff5c2e8e0 100644
--- a/llvm/test/DebugInfo/X86/op_deref.ll
+++ b/llvm/test/DebugInfo/X86/op_deref.ll
@@ -89,23 +89,23 @@ declare void @llvm.stackrestore(i8*) nounwind
!8 = !{null, !9}
!9 = !{!"0x24\00int\000\0032\0032\000\000\005", null, null} ; [ DW_TAG_base_type ]
!10 = !{!"0x101\00s\0016777217\000", !5, !6, !9} ; [ DW_TAG_arg_variable ]
-!11 = !{i32 1, i32 26, !5, null}
-!12 = !{i32 3, i32 13, !13, null}
+!11 = !MDLocation(line: 1, column: 26, scope: !5)
+!12 = !MDLocation(line: 3, column: 13, scope: !13)
!13 = !{!"0xb\002\001\000", !28, !5} ; [ DW_TAG_lexical_block ]
!14 = !{!"0x100\00vla\003\008192", !13, !6, !15} ; [ DW_TAG_auto_variable ]
!15 = !{!"0x1\00\000\000\0032\000\000", null, null, !9, !16, i32 0, null, null, null} ; [ DW_TAG_array_type ] [line 0, size 0, align 32, offset 0] [from int]
!16 = !{!17}
!17 = !{!"0x21\000\00-1"} ; [ DW_TAG_subrange_type ]
-!18 = !{i32 3, i32 7, !13, null}
+!18 = !MDLocation(line: 3, column: 7, scope: !13)
!19 = !{!"0x100\00i\004\000", !13, !6, !9} ; [ DW_TAG_auto_variable ]
-!20 = !{i32 4, i32 7, !13, null}
-!21 = !{i32 5, i32 8, !22, null}
+!20 = !MDLocation(line: 4, column: 7, scope: !13)
+!21 = !MDLocation(line: 5, column: 8, scope: !22)
!22 = !{!"0xb\005\003\001", !28, !13} ; [ DW_TAG_lexical_block ]
-!23 = !{i32 6, i32 5, !24, null}
+!23 = !MDLocation(line: 6, column: 5, scope: !24)
!24 = !{!"0xb\005\0027\002", !28, !22} ; [ DW_TAG_lexical_block ]
-!25 = !{i32 7, i32 3, !24, null}
-!26 = !{i32 5, i32 22, !22, null}
-!27 = !{i32 8, i32 1, !13, null}
+!25 = !MDLocation(line: 7, column: 3, scope: !24)
+!26 = !MDLocation(line: 5, column: 22, scope: !22)
+!27 = !MDLocation(line: 8, column: 1, scope: !13)
!28 = !{!"bar.c", !"/Users/echristo/tmp"}
!29 = !{i32 1, !"Debug Info Version", i32 2}
!30 = !{!"0x102\006"} ; [ DW_TAG_expression ] [DW_OP_deref]
diff --git a/llvm/test/DebugInfo/X86/parameters.ll b/llvm/test/DebugInfo/X86/parameters.ll
index 10c6686c64e..1655f09790e 100644
--- a/llvm/test/DebugInfo/X86/parameters.ll
+++ b/llvm/test/DebugInfo/X86/parameters.ll
@@ -106,13 +106,13 @@ attributes #2 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n
!21 = !{i32 2, !"Dwarf Version", i32 3}
!22 = !{!"0x101\00f\0016777222\008192", !4, !23, !8} ; [ DW_TAG_arg_variable ] [f] [line 6]
!23 = !{!"0x29", !1} ; [ DW_TAG_file_type ] [/tmp/pass.cpp]
-!24 = !{i32 6, i32 0, !4, null}
-!25 = !{i32 7, i32 0, !4, null}
+!24 = !MDLocation(line: 6, scope: !4)
+!25 = !MDLocation(line: 7, scope: !4)
!26 = !{!"0x101\00b\0016777228\000", !17, !23, !20} ; [ DW_TAG_arg_variable ] [b] [line 12]
-!27 = !{i32 12, i32 0, !17, null}
+!27 = !MDLocation(line: 12, scope: !17)
!28 = !{!"0x101\00g\0033554444\008192", !17, !23, !8} ; [ DW_TAG_arg_variable ] [g] [line 12]
-!29 = !{i32 13, i32 0, !30, null}
+!29 = !MDLocation(line: 13, scope: !30)
!30 = !{!"0xb\0013\000\000", !1, !17} ; [ DW_TAG_lexical_block ] [/tmp/pass.cpp]
-!31 = !{i32 14, i32 0, !30, null}
-!32 = !{i32 15, i32 0, !17, null}
+!31 = !MDLocation(line: 14, scope: !30)
+!32 = !MDLocation(line: 15, scope: !17)
!33 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/pieces-1.ll b/llvm/test/DebugInfo/X86/pieces-1.ll
index 73b7e8bb3e5..4c11a8b969c 100644
--- a/llvm/test/DebugInfo/X86/pieces-1.ll
+++ b/llvm/test/DebugInfo/X86/pieces-1.ll
@@ -71,9 +71,9 @@ attributes #1 = { nounwind readnone }
!18 = !{i32 1, !"Debug Info Version", i32 2}
!19 = !{!"clang version 3.5 "}
!20 = !{!"0x101\00s\0016777219\000", !4, !5, !9} ; [ DW_TAG_arg_variable ] [s] [line 3]
-!21 = !{i32 3, i32 0, !4, null}
+!21 = !MDLocation(line: 3, scope: !4)
!22 = !{!"0x101\00s\0016777219\000", !4, !5, !9} ; [ DW_TAG_arg_variable ] [s] [line 3]
-!23 = !{i32 4, i32 0, !4, null}
+!23 = !MDLocation(line: 4, scope: !4)
!24 = !{!"0x102\00147\000\008"} ; [ DW_TAG_expression ] [DW_OP_piece 0 8] [piece, size 8, offset 0]
!25 = !{}
!27 = !{!"0x102\00147\008\004"} ; [ DW_TAG_expression ] [DW_OP_piece 8 4] [piece, size 4, offset 8]
diff --git a/llvm/test/DebugInfo/X86/pieces-2.ll b/llvm/test/DebugInfo/X86/pieces-2.ll
index 11bf1492e1e..184840956fd 100644
--- a/llvm/test/DebugInfo/X86/pieces-2.ll
+++ b/llvm/test/DebugInfo/X86/pieces-2.ll
@@ -83,9 +83,9 @@ attributes #2 = { nounwind }
!23 = !{i32 1, !"Debug Info Version", i32 2}
!24 = !{!"clang version 3.5.0 "}
!25 = !{!"0x101\00outer\0016777226\000", !4, !5, !9} ; [ DW_TAG_arg_variable ] [outer] [line 10]
-!26 = !{i32 10, i32 0, !4, null}
-!27 = !{i32 11, i32 0, !4, null}
+!26 = !MDLocation(line: 10, scope: !4)
+!27 = !MDLocation(line: 11, scope: !4)
!28 = !{!"0x100\00i1\0011\000", !4, !5, !14} ; [ DW_TAG_auto_variable ] [i1] [line 11]
!29 = !{!"0x102\00147\000\004"} ; [ DW_TAG_expression ] [DW_OP_piece 0 4] [piece, size 4, offset 0]
!31 = !{i32 3, i32 0, i32 12}
-!32 = !{i32 12, i32 0, !4, null}
+!32 = !MDLocation(line: 12, scope: !4)
diff --git a/llvm/test/DebugInfo/X86/pieces-3.ll b/llvm/test/DebugInfo/X86/pieces-3.ll
index 02e686eb9fb..3e4965fcf81 100644
--- a/llvm/test/DebugInfo/X86/pieces-3.ll
+++ b/llvm/test/DebugInfo/X86/pieces-3.ll
@@ -93,14 +93,14 @@ attributes #2 = { nounwind }
!23 = !{!"clang version 3.5.0 "}
!24 = !{!"0x101\00outer\0016777226\000", !4, !5, !9} ; [ DW_TAG_arg_variable ] [outer] [line 10]
!25 = !{!"0x102\00147\000\008"} ; [ DW_TAG_expression ] [DW_OP_piece 0 8] [piece, size 8, offset 0]
-!26 = !{i32 10, i32 0, !4, null}
+!26 = !MDLocation(line: 10, scope: !4)
!27 = !{!"0x101\00outer\0016777226\000", !4, !5, !9} ; [ DW_TAG_arg_variable ] [outer] [line 10]
!28 = !{!"0x102\00147\008\008"} ; [ DW_TAG_expression ] [DW_OP_piece 8 8] [piece, size 8, offset 8]
!29 = !{!"0x101\00outer\0016777226\000", !4, !5, !9} ; [ DW_TAG_arg_variable ] [outer] [line 10]
!30 = !{!"0x102\00147\0012\004"} ; [ DW_TAG_expression ] [DW_OP_piece 12 4] [piece, size 4, offset 12]
!31 = !{!"0x101\00outer\0016777226\000", !4, !5, !9} ; [ DW_TAG_arg_variable ] [outer] [line 10]
!32 = !{!"0x102\00147\008\004"} ; [ DW_TAG_expression ] [DW_OP_piece 8 4] [piece, size 4, offset 8]
-!33 = !{i32 11, i32 0, !4, null}
+!33 = !MDLocation(line: 11, scope: !4)
!34 = !{!"0x100\00i1\0011\000", !4, !5, !14} ; [ DW_TAG_auto_variable ] [i1] [line 11]
!35 = !{!"0x102\00147\000\004"} ; [ DW_TAG_expression ] [DW_OP_piece 0 4] [piece, size 4, offset 0]
-!36 = !{i32 12, i32 0, !4, null}
+!36 = !MDLocation(line: 12, scope: !4)
diff --git a/llvm/test/DebugInfo/X86/pr11300.ll b/llvm/test/DebugInfo/X86/pr11300.ll
index 365595ced9b..53e85acf82c 100644
--- a/llvm/test/DebugInfo/X86/pr11300.ll
+++ b/llvm/test/DebugInfo/X86/pr11300.ll
@@ -58,13 +58,13 @@ entry:
!19 = !{!"0x24"} ; [ DW_TAG_base_type ]
!20 = !{!"0x2e\00bar\00bar\00_ZN3foo3barEv\002\000\001\000\006\00256\000\002", !6, null, !13, null, void (%struct.foo*)* @_ZN3foo3barEv, null, !12, null} ; [ DW_TAG_subprogram ] [line 2] [def] [bar]
!23 = !{!"0x101\00x\0016777220\000", !5, !6, !9} ; [ DW_TAG_arg_variable ]
-!24 = !{i32 4, i32 15, !5, null}
-!25 = !{i32 4, i32 20, !26, null}
+!24 = !MDLocation(line: 4, column: 15, scope: !5)
+!25 = !MDLocation(line: 4, column: 20, scope: !26)
!26 = !{!"0xb\004\0018\000", !6, !5} ; [ DW_TAG_lexical_block ]
-!27 = !{i32 4, i32 30, !26, null}
+!27 = !MDLocation(line: 4, column: 30, scope: !26)
!28 = !{!"0x101\00this\0016777218\0064", !20, !6, !15} ; [ DW_TAG_arg_variable ]
-!29 = !{i32 2, i32 8, !20, null}
-!30 = !{i32 2, i32 15, !31, null}
+!29 = !MDLocation(line: 2, column: 8, scope: !20)
+!30 = !MDLocation(line: 2, column: 15, scope: !31)
!31 = !{!"0xb\002\0014\001", !6, !20} ; [ DW_TAG_lexical_block ]
!32 = !{!"/home/espindola/llvm/test.cc", !"/home/espindola/tmpfs/build"}
!33 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/pr12831.ll b/llvm/test/DebugInfo/X86/pr12831.ll
index c7f31849d65..5adaeaf7d31 100644
--- a/llvm/test/DebugInfo/X86/pr12831.ll
+++ b/llvm/test/DebugInfo/X86/pr12831.ll
@@ -210,29 +210,29 @@ entry:
!132 = !{!"0x24\00bool\000\008\008\000\000\002", null, null} ; [ DW_TAG_base_type ]
!133 = !{!"0x101\00this\0016777235\0064", !5, !6, !134} ; [ DW_TAG_arg_variable ]
!134 = !{!"0xf\00\000\0064\0064\000\000", null, null, !10} ; [ DW_TAG_pointer_type ]
-!135 = !{i32 19, i32 39, !5, null}
-!136 = !{i32 20, i32 17, !137, null}
+!135 = !MDLocation(line: 19, column: 39, scope: !5)
+!136 = !MDLocation(line: 20, column: 17, scope: !137)
!137 = !{!"0xb\0019\0051\000", !6, !5} ; [ DW_TAG_lexical_block ]
-!138 = !{i32 23, i32 17, !137, null}
-!139 = !{i32 26, i32 15, !137, null}
+!138 = !MDLocation(line: 23, column: 17, scope: !137)
+!139 = !MDLocation(line: 26, column: 15, scope: !137)
!140 = !{!"0x101\00this\0016777224\0064", !106, !6, !141} ; [ DW_TAG_arg_variable ]
!141 = !{!"0xf\00\000\0064\0064\000\000", null, null, !20} ; [ DW_TAG_pointer_type ]
-!142 = !{i32 8, i32 45, !106, null}
+!142 = !MDLocation(line: 8, column: 45, scope: !106)
!143 = !{!"0x101\00__f\0033554440\000", !106, !6, !61} ; [ DW_TAG_arg_variable ]
-!144 = !{i32 8, i32 63, !106, null}
-!145 = !{i32 9, i32 9, !146, null}
+!144 = !MDLocation(line: 8, column: 63, scope: !106)
+!145 = !MDLocation(line: 9, column: 9, scope: !146)
!146 = !{!"0xb\008\0081\001", !6, !106} ; [ DW_TAG_lexical_block ]
-!147 = !{i32 10, i32 13, !146, null}
-!148 = !{i32 4, i32 5, !149, null}
+!147 = !MDLocation(line: 10, column: 13, scope: !146)
+!148 = !MDLocation(line: 4, column: 5, scope: !149)
!149 = !{!"0xb\003\00105\002", !6, !107} ; [ DW_TAG_lexical_block ]
!150 = !{!"0x101\00this\0016777224\0064", !126, !6, !141} ; [ DW_TAG_arg_variable ]
-!151 = !{i32 8, i32 45, !126, null}
+!151 = !MDLocation(line: 8, column: 45, scope: !126)
!152 = !{!"0x101\00__f\0033554440\000", !126, !6, !26} ; [ DW_TAG_arg_variable ]
-!153 = !{i32 8, i32 63, !126, null}
-!154 = !{i32 9, i32 9, !155, null}
+!153 = !MDLocation(line: 8, column: 63, scope: !126)
+!154 = !MDLocation(line: 9, column: 9, scope: !155)
!155 = !{!"0xb\008\0081\003", !6, !126} ; [ DW_TAG_lexical_block ]
-!156 = !{i32 10, i32 13, !155, null}
-!157 = !{i32 4, i32 5, !158, null}
+!156 = !MDLocation(line: 10, column: 13, scope: !155)
+!157 = !MDLocation(line: 4, column: 5, scope: !158)
!158 = !{!"0xb\003\00105\004", !6, !127} ; [ DW_TAG_lexical_block ]
!159 = !{!"0x29", !161} ; [ DW_TAG_file_type ]
!160 = !{!"BPLFunctionWriter2.ii", !"/home/peter/crashdelta"}
diff --git a/llvm/test/DebugInfo/X86/pr13303.ll b/llvm/test/DebugInfo/X86/pr13303.ll
index a56171acf8a..2ca697a3e45 100644
--- a/llvm/test/DebugInfo/X86/pr13303.ll
+++ b/llvm/test/DebugInfo/X86/pr13303.ll
@@ -23,7 +23,7 @@ entry:
!7 = !{!"0x15\00\000\000\000\000\000\000", i32 0, null, null, !8, null, null, null} ; [ DW_TAG_subroutine_type ] [line 0, size 0, align 0, offset 0] [from ]
!8 = !{!9}
!9 = !{!"0x24\00int\000\0032\0032\000\000\005", null, null} ; [ DW_TAG_base_type ] [int] [line 0, size 32, align 32, offset 0, enc DW_ATE_signed]
-!10 = !{i32 1, i32 14, !11, null}
+!10 = !MDLocation(line: 1, column: 14, scope: !11)
!11 = !{!"0xb\001\0012\000", !12, !5} ; [ DW_TAG_lexical_block ] [/home/probinson/PR13303.c]
!12 = !{!"PR13303.c", !"/home/probinson"}
!13 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/pr19307.ll b/llvm/test/DebugInfo/X86/pr19307.ll
index 83cb78041b8..c05dc475d63 100644
--- a/llvm/test/DebugInfo/X86/pr19307.ll
+++ b/llvm/test/DebugInfo/X86/pr19307.ll
@@ -130,16 +130,16 @@ attributes #2 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n
!43 = !{i32 2, !"Debug Info Version", i32 2}
!44 = !{!"clang version 3.5.0 (209308)"}
!45 = !{!"0x101\00offset\0016777219\000", !13, !14, !17} ; [ DW_TAG_arg_variable ] [offset] [line 3]
-!46 = !{i32 3, i32 0, !13, null}
+!46 = !MDLocation(line: 3, scope: !13)
!47 = !{!"0x101\00limit\0033554435\000", !13, !14, !17} ; [ DW_TAG_arg_variable ] [limit] [line 3]
!48 = !{!"0x101\00range\0050331652\008192", !13, !14, !19} ; [ DW_TAG_arg_variable ] [range] [line 4]
-!49 = !{i32 4, i32 0, !13, null}
-!50 = !{i32 5, i32 0, !51, null}
+!49 = !MDLocation(line: 4, scope: !13)
+!50 = !MDLocation(line: 5, scope: !51)
!51 = !{!"0xb\005\000\000", !1, !13} ; [ DW_TAG_lexical_block ] [/llvm_cmake_gcc/pr19307.cc]
-!52 = !{i32 5, i32 0, !53, null}
+!52 = !MDLocation(line: 5, scope: !53)
!53 = !{!"0xb\005\000\001", !1, !51} ; [ DW_TAG_lexical_block ] [/llvm_cmake_gcc/pr19307.cc]
-!54 = !{i32 6, i32 0, !51, null}
-!55 = !{i32 7, i32 0, !13, null}
-!56 = !{i32 8, i32 0, !13, null}
-!57 = !{i32 9, i32 0, !13, null}
+!54 = !MDLocation(line: 6, scope: !51)
+!55 = !MDLocation(line: 7, scope: !13)
+!56 = !MDLocation(line: 8, scope: !13)
+!57 = !MDLocation(line: 9, scope: !13)
diff --git a/llvm/test/DebugInfo/X86/prologue-stack.ll b/llvm/test/DebugInfo/X86/prologue-stack.ll
index ac969822ba4..1cc872ab418 100644
--- a/llvm/test/DebugInfo/X86/prologue-stack.ll
+++ b/llvm/test/DebugInfo/X86/prologue-stack.ll
@@ -29,8 +29,8 @@ declare i32 @callme(i32)
!7 = !{!"0x15\00\000\000\000\000\000\000", i32 0, null, null, !8, null, null, null} ; [ DW_TAG_subroutine_type ] [line 0, size 0, align 0, offset 0] [from ]
!8 = !{!9}
!9 = !{!"0x24\00int\000\0032\0032\000\000\005", null, null} ; [ DW_TAG_base_type ] [int] [line 0, size 32, align 32, offset 0, enc DW_ATE_signed]
-!10 = !{i32 5, i32 3, !11, null}
+!10 = !MDLocation(line: 5, column: 3, scope: !11)
!11 = !{!"0xb\004\001\000", !13, !5} ; [ DW_TAG_lexical_block ] [/usr/local/google/home/echristo/tmp/bar.c]
-!12 = !{i32 6, i32 3, !11, null}
+!12 = !MDLocation(line: 6, column: 3, scope: !11)
!13 = !{!"bar.c", !"/usr/local/google/home/echristo/tmp"}
!14 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/recursive_inlining.ll b/llvm/test/DebugInfo/X86/recursive_inlining.ll
index 234b1140d18..6cd935ce061 100644
--- a/llvm/test/DebugInfo/X86/recursive_inlining.ll
+++ b/llvm/test/DebugInfo/X86/recursive_inlining.ll
@@ -230,46 +230,46 @@ attributes #3 = { nounwind }
!28 = !{i32 2, !"Dwarf Version", i32 4}
!29 = !{i32 2, !"Debug Info Version", i32 2}
!30 = !{!"clang version 3.6.0 "}
-!31 = !{i32 16, i32 0, !14, null}
-!32 = !{i32 17, i32 0, !14, null}
+!31 = !MDLocation(line: 16, scope: !14)
+!32 = !MDLocation(line: 17, scope: !14)
!33 = !{!34, !34, i64 0}
!34 = !{!"any pointer", !35, i64 0}
!35 = !{!"omnipotent char", !36, i64 0}
!36 = !{!"Simple C/C++ TBAA"}
!37 = !{!"0x101\00this\0016777216\001088", !22, null, !25, !32} ; [ DW_TAG_arg_variable ] [this] [line 0]
-!38 = !{i32 0, i32 0, !22, !32}
-!39 = !{i32 8, i32 0, !22, !32}
-!40 = !{i32 9, i32 0, !41, !32}
+!38 = !MDLocation(line: 0, scope: !22, inlinedAt: !32)
+!39 = !MDLocation(line: 8, scope: !22, inlinedAt: !32)
+!40 = !MDLocation(line: 9, scope: !41, inlinedAt: !32)
!41 = !{!"0xb\009\000\000", !5, !22} ; [ DW_TAG_lexical_block ] [/usr/local/google/home/blaikie/dev/scratch/missing_concrete_variable_on_darwin/reduce/recursive_inlining.cpp]
!42 = !{!43, !44, i64 0}
!43 = !{!"_ZTS1C", !44, i64 0}
!44 = !{!"int", !35, i64 0}
-!45 = !{i32 9, i32 0, !46, !32}
+!45 = !MDLocation(line: 9, scope: !46, inlinedAt: !32)
!46 = !{!"0xb\009\000\001", !5, !41} ; [ DW_TAG_lexical_block ] [/usr/local/google/home/blaikie/dev/scratch/missing_concrete_variable_on_darwin/reduce/recursive_inlining.cpp]
-!47 = !{i32 10, i32 0, !22, !32}
-!48 = !{i32 19, i32 0, !14, null}
-!49 = !{i32 0, i32 0, !22, null}
-!50 = !{i32 8, i32 0, !22, null}
-!51 = !{i32 9, i32 0, !41, null}
-!52 = !{i32 9, i32 0, !46, null}
-!53 = !{i32 16, i32 0, !14, !54}
-!54 = !{i32 20, i32 0, !18, !55}
-!55 = !{i32 10, i32 0, !22, null}
-!56 = !{i32 17, i32 0, !14, !54}
+!47 = !MDLocation(line: 10, scope: !22, inlinedAt: !32)
+!48 = !MDLocation(line: 19, scope: !14)
+!49 = !MDLocation(line: 0, scope: !22)
+!50 = !MDLocation(line: 8, scope: !22)
+!51 = !MDLocation(line: 9, scope: !41)
+!52 = !MDLocation(line: 9, scope: !46)
+!53 = !MDLocation(line: 16, scope: !14, inlinedAt: !54)
+!54 = !MDLocation(line: 20, scope: !18, inlinedAt: !55)
+!55 = !MDLocation(line: 10, scope: !22)
+!56 = !MDLocation(line: 17, scope: !14, inlinedAt: !54)
!57 = !{!"0x101\00this\0016777216\001088", !22, null, !25, !56} ; [ DW_TAG_arg_variable ] [this] [line 0]
-!58 = !{i32 0, i32 0, !22, !56}
-!59 = !{i32 8, i32 0, !22, !56}
-!60 = !{i32 9, i32 0, !41, !56}
-!61 = !{i32 9, i32 0, !46, !56}
-!62 = !{i32 10, i32 0, !22, !56}
-!63 = !{i32 11, i32 0, !22, null}
-!64 = !{i32 16, i32 0, !14, !65}
-!65 = !{i32 20, i32 0, !18, null}
-!66 = !{i32 17, i32 0, !14, !65}
+!58 = !MDLocation(line: 0, scope: !22, inlinedAt: !56)
+!59 = !MDLocation(line: 8, scope: !22, inlinedAt: !56)
+!60 = !MDLocation(line: 9, scope: !41, inlinedAt: !56)
+!61 = !MDLocation(line: 9, scope: !46, inlinedAt: !56)
+!62 = !MDLocation(line: 10, scope: !22, inlinedAt: !56)
+!63 = !MDLocation(line: 11, scope: !22)
+!64 = !MDLocation(line: 16, scope: !14, inlinedAt: !65)
+!65 = !MDLocation(line: 20, scope: !18)
+!66 = !MDLocation(line: 17, scope: !14, inlinedAt: !65)
!67 = !{!"0x101\00this\0016777216\001088", !22, null, !25, !66} ; [ DW_TAG_arg_variable ] [this] [line 0]
-!68 = !{i32 0, i32 0, !22, !66}
-!69 = !{i32 8, i32 0, !22, !66}
-!70 = !{i32 9, i32 0, !41, !66}
-!71 = !{i32 9, i32 0, !46, !66}
-!72 = !{i32 21, i32 0, !19, null}
-!73 = !{i32 22, i32 0, !20, null}
+!68 = !MDLocation(line: 0, scope: !22, inlinedAt: !66)
+!69 = !MDLocation(line: 8, scope: !22, inlinedAt: !66)
+!70 = !MDLocation(line: 9, scope: !41, inlinedAt: !66)
+!71 = !MDLocation(line: 9, scope: !46, inlinedAt: !66)
+!72 = !MDLocation(line: 21, scope: !19)
+!73 = !MDLocation(line: 22, scope: !20)
diff --git a/llvm/test/DebugInfo/X86/reference-argument.ll b/llvm/test/DebugInfo/X86/reference-argument.ll
index ead01d41419..68ff200be40 100644
--- a/llvm/test/DebugInfo/X86/reference-argument.ll
+++ b/llvm/test/DebugInfo/X86/reference-argument.ll
@@ -81,23 +81,23 @@ declare void @_ZN4SValD2Ev(%class.SVal* %this)
!46 = !{i32 786468}
!47 = !{i32 2, !"Dwarf Version", i32 3}
!48 = !{!"0x101\00v\0016777235\000", !4, !5, !8} ; [ DW_TAG_arg_variable ] [v] [line 19]
-!49 = !{i32 19, i32 0, !4, null}
+!49 = !MDLocation(line: 19, scope: !4)
!50 = !{!"0x100\00v\0026\000", !29, !5, !9} ; [ DW_TAG_auto_variable ] [v] [line 26]
-!51 = !{i32 26, i32 0, !29, null}
-!52 = !{i32 27, i32 0, !29, null}
-!53 = !{i32 28, i32 0, !29, null}
+!51 = !MDLocation(line: 26, scope: !29)
+!52 = !MDLocation(line: 27, scope: !29)
+!53 = !MDLocation(line: 28, scope: !29)
!54 = !{!"0x100\00a\0029\000", !29, !5, !39} ; [ DW_TAG_auto_variable ] [a] [line 29]
-!55 = !{i32 29, i32 0, !29, null}
-!56 = !{i32 30, i32 0, !29, null}
-!57 = !{i32 31, i32 0, !29, null}
-!58 = !{i32 32, i32 0, !29, null}
+!55 = !MDLocation(line: 29, scope: !29)
+!56 = !MDLocation(line: 30, scope: !29)
+!57 = !MDLocation(line: 31, scope: !29)
+!58 = !MDLocation(line: 32, scope: !29)
!59 = !{!"0x101\00this\0016777238\001088", !35, !5, !60} ; [ DW_TAG_arg_variable ] [this] [line 22]
!60 = !{!"0xf\00\000\0064\0064\000\000", null, null, !39} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from A]
-!61 = !{i32 22, i32 0, !35, null}
+!61 = !MDLocation(line: 22, scope: !35)
!62 = !{!"0x101\00v\0033554454\008192", !35, !5, !9} ; [ DW_TAG_arg_variable ] [v] [line 22]
!63 = !{!"0x101\00this\0016777230\001088", !33, !5, !64} ; [ DW_TAG_arg_variable ] [this] [line 14]
!64 = !{!"0xf\00\000\0064\0064\000\000", null, null, !9} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from SVal]
-!65 = !{i32 14, i32 0, !33, null}
+!65 = !MDLocation(line: 14, scope: !33)
!66 = !{!"0x101\00this\0016777230\001088", !34, !5, !64} ; [ DW_TAG_arg_variable ] [this] [line 14]
-!67 = !{i32 14, i32 0, !34, null}
+!67 = !MDLocation(line: 14, scope: !34)
!68 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/rvalue-ref.ll b/llvm/test/DebugInfo/X86/rvalue-ref.ll
index 0e07bf9066e..3829966482f 100644
--- a/llvm/test/DebugInfo/X86/rvalue-ref.ll
+++ b/llvm/test/DebugInfo/X86/rvalue-ref.ll
@@ -33,9 +33,9 @@ declare i32 @printf(i8*, ...)
!9 = !{!"0x42\00\000\000\000\000\000", null, null, !10} ; [ DW_TAG_rvalue_reference_type ]
!10 = !{!"0x24\00int\000\0032\0032\000\000\005", null, null} ; [ DW_TAG_base_type ]
!11 = !{!"0x101\00i\0016777220\000", !5, !6, !9} ; [ DW_TAG_arg_variable ]
-!12 = !{i32 4, i32 17, !5, null}
-!13 = !{i32 6, i32 3, !14, null}
+!12 = !MDLocation(line: 4, column: 17, scope: !5)
+!13 = !MDLocation(line: 6, column: 3, scope: !14)
!14 = !{!"0xb\005\001\000", !16, !5} ; [ DW_TAG_lexical_block ]
-!15 = !{i32 7, i32 1, !14, null}
+!15 = !MDLocation(line: 7, column: 1, scope: !14)
!16 = !{!"foo.cpp", !"/Users/echristo/tmp"}
!17 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/sret.ll b/llvm/test/DebugInfo/X86/sret.ll
index 03356837abb..42d65695f63 100644
--- a/llvm/test/DebugInfo/X86/sret.ll
+++ b/llvm/test/DebugInfo/X86/sret.ll
@@ -325,69 +325,69 @@ attributes #7 = { builtin nounwind }
!66 = !{!"clang version 3.5.0 (trunk 203283) (llvm/trunk 203307)"}
!67 = !{!"0x101\00this\0016777216\001088", !49, null, !68} ; [ DW_TAG_arg_variable ] [this] [line 0]
!68 = !{!"0xf\00\000\0064\0064\000\000", null, null, !"_ZTS1A"} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from _ZTS1A]
-!69 = !{i32 0, i32 0, !49, null}
+!69 = !MDLocation(line: 0, scope: !49)
!70 = !{!"0x101\00i\0033554448\000", !49, !7, !12} ; [ DW_TAG_arg_variable ] [i] [line 16]
-!71 = !{i32 16, i32 0, !49, null}
-!72 = !{i32 18, i32 0, !49, null}
-!73 = !{i32 19, i32 0, !49, null}
+!71 = !MDLocation(line: 16, scope: !49)
+!72 = !MDLocation(line: 18, scope: !49)
+!73 = !MDLocation(line: 19, scope: !49)
!74 = !{!"0x101\00this\0016777216\001088", !50, null, !68} ; [ DW_TAG_arg_variable ] [this] [line 0]
-!75 = !{i32 0, i32 0, !50, null}
+!75 = !MDLocation(line: 0, scope: !50)
!76 = !{!"0x101\00rhs\0033554453\000", !50, !7, !22} ; [ DW_TAG_arg_variable ] [rhs] [line 21]
-!77 = !{i32 21, i32 0, !50, null}
-!78 = !{i32 23, i32 0, !50, null}
-!79 = !{i32 24, i32 0, !50, null}
+!77 = !MDLocation(line: 21, scope: !50)
+!78 = !MDLocation(line: 23, scope: !50)
+!79 = !MDLocation(line: 24, scope: !50)
!80 = !{!"0x101\00this\0016777216\001088", !51, null, !68} ; [ DW_TAG_arg_variable ] [this] [line 0]
-!81 = !{i32 0, i32 0, !51, null}
+!81 = !MDLocation(line: 0, scope: !51)
!82 = !{!"0x101\00rhs\0033554459\000", !51, !7, !22} ; [ DW_TAG_arg_variable ] [rhs] [line 27]
-!83 = !{i32 27, i32 0, !51, null}
-!84 = !{i32 29, i32 0, !51, null}
-!85 = !{i32 30, i32 0, !51, null}
+!83 = !MDLocation(line: 27, scope: !51)
+!84 = !MDLocation(line: 29, scope: !51)
+!85 = !MDLocation(line: 30, scope: !51)
!86 = !{!"0x101\00this\0016777216\001088", !52, null, !68} ; [ DW_TAG_arg_variable ] [this] [line 0]
-!87 = !{i32 0, i32 0, !52, null}
-!88 = !{i32 35, i32 0, !52, null}
+!87 = !MDLocation(line: 0, scope: !52)
+!88 = !MDLocation(line: 35, scope: !52)
!89 = !{!"0x101\00this\0016777216\001088", !53, null, !90} ; [ DW_TAG_arg_variable ] [this] [line 0]
!90 = !{!"0xf\00\000\0064\0064\000\000", null, null, !"_ZTS1B"} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from _ZTS1B]
-!91 = !{i32 0, i32 0, !53, null}
-!92 = !{i32 49, i32 0, !53, null}
+!91 = !MDLocation(line: 0, scope: !53)
+!92 = !MDLocation(line: 49, scope: !53)
!93 = !{!"0x100\00a\0049\008192", !53, !7, !4} ; [ DW_TAG_auto_variable ] [a] [line 49]
-!94 = !{i32 50, i32 0, !53, null}
-!95 = !{i32 51, i32 0, !53, null}
-!96 = !{i32 51, i32 0, !97, null}
+!94 = !MDLocation(line: 50, scope: !53)
+!95 = !MDLocation(line: 51, scope: !53)
+!96 = !MDLocation(line: 51, scope: !97)
!97 = !{!"0xb\0051\000\002", !1, !53} ; [ DW_TAG_lexical_block ] [/usr/local/google/home/echristo/tmp/sret.cpp]
-!98 = !{i32 51, i32 0, !99, null}
+!98 = !MDLocation(line: 51, scope: !99)
!99 = !{!"0xb\0051\000\003", !1, !100} ; [ DW_TAG_lexical_block ] [/usr/local/google/home/echristo/tmp/sret.cpp]
!100 = !{!"0xb\0051\000\001", !1, !53} ; [ DW_TAG_lexical_block ] [/usr/local/google/home/echristo/tmp/sret.cpp]
!101 = !{!"0x101\00this\0016777216\001088", !63, null, !68} ; [ DW_TAG_arg_variable ] [this] [line 0]
-!102 = !{i32 0, i32 0, !63, null}
-!103 = !{i32 8, i32 0, !63, null}
+!102 = !MDLocation(line: 0, scope: !63)
+!103 = !MDLocation(line: 8, scope: !63)
!104 = !{!"0x101\00argc\0016777269\000", !54, !7, !12} ; [ DW_TAG_arg_variable ] [argc] [line 53]
-!105 = !{i32 53, i32 0, !54, null}
+!105 = !MDLocation(line: 53, scope: !54)
!106 = !{!"0x101\00argv\0033554485\000", !54, !7, !57} ; [ DW_TAG_arg_variable ] [argv] [line 53]
!107 = !{!"0x100\00b\0055\000", !54, !7, !37} ; [ DW_TAG_auto_variable ] [b] [line 55]
-!108 = !{i32 55, i32 0, !54, null}
+!108 = !MDLocation(line: 55, scope: !54)
!109 = !{!"0x100\00return_val\0056\000", !54, !7, !12} ; [ DW_TAG_auto_variable ] [return_val] [line 56]
-!110 = !{i32 56, i32 0, !54, null}
-!111 = !{i32 56, i32 0, !112, null}
+!110 = !MDLocation(line: 56, scope: !54)
+!111 = !MDLocation(line: 56, scope: !112)
!112 = !{!"0xb\0056\000\001", !1, !54} ; [ DW_TAG_lexical_block ] [/usr/local/google/home/echristo/tmp/sret.cpp]
!113 = !{!"0x100\00a\0058\000", !54, !7, !4} ; [ DW_TAG_auto_variable ] [a] [line 58]
-!114 = !{i32 58, i32 0, !54, null}
-!115 = !{i32 59, i32 0, !54, null}
-!116 = !{i32 60, i32 0, !54, null}
-!117 = !{i32 60, i32 0, !118, null}
+!114 = !MDLocation(line: 58, scope: !54)
+!115 = !MDLocation(line: 59, scope: !54)
+!116 = !MDLocation(line: 60, scope: !54)
+!117 = !MDLocation(line: 60, scope: !118)
!118 = !{!"0xb\0060\000\001", !1, !54} ; [ DW_TAG_lexical_block ] [/usr/local/google/home/echristo/tmp/sret.cpp]
-!119 = !{i32 60, i32 0, !120, null}
+!119 = !MDLocation(line: 60, scope: !120)
!120 = !{!"0xb\0060\000\003", !1, !54} ; [ DW_TAG_lexical_block ] [/usr/local/google/home/echristo/tmp/sret.cpp]
-!121 = !{i32 60, i32 0, !122, null}
+!121 = !MDLocation(line: 60, scope: !122)
!122 = !{!"0xb\0060\000\002", !1, !54} ; [ DW_TAG_lexical_block ] [/usr/local/google/home/echristo/tmp/sret.cpp]
!123 = !{!"0x101\00this\0016777216\001088", !62, null, !90} ; [ DW_TAG_arg_variable ] [this] [line 0]
-!124 = !{i32 0, i32 0, !62, null}
-!125 = !{i32 41, i32 0, !62, null}
+!124 = !MDLocation(line: 0, scope: !62)
+!125 = !MDLocation(line: 41, scope: !62)
!126 = !{!"0x101\00this\0016777216\001088", !61, null, !68} ; [ DW_TAG_arg_variable ] [this] [line 0]
-!127 = !{i32 0, i32 0, !61, null}
-!128 = !{i32 8, i32 0, !61, null}
-!129 = !{i32 8, i32 0, !130, null}
+!127 = !MDLocation(line: 0, scope: !61)
+!128 = !MDLocation(line: 8, scope: !61)
+!129 = !MDLocation(line: 8, scope: !130)
!130 = !{!"0xb\008\000\001", !1, !61} ; [ DW_TAG_lexical_block ] [/usr/local/google/home/echristo/tmp/sret.cpp]
-!131 = !{i32 8, i32 0, !132, null}
+!131 = !MDLocation(line: 8, scope: !132)
!132 = !{!"0xb\008\000\002", !1, !61} ; [ DW_TAG_lexical_block ] [/usr/local/google/home/echristo/tmp/sret.cpp]
-!133 = !{i32 8, i32 0, !134, null}
+!133 = !MDLocation(line: 8, scope: !134)
!134 = !{!"0xb\008\000\003", !1, !61} ; [ DW_TAG_lexical_block ] [/usr/local/google/home/echristo/tmp/sret.cpp]
diff --git a/llvm/test/DebugInfo/X86/stmt-list-multiple-compile-units.ll b/llvm/test/DebugInfo/X86/stmt-list-multiple-compile-units.ll
index 0d0e6e86a5c..0b2c50ec766 100644
--- a/llvm/test/DebugInfo/X86/stmt-list-multiple-compile-units.ll
+++ b/llvm/test/DebugInfo/X86/stmt-list-multiple-compile-units.ll
@@ -92,12 +92,12 @@ entry:
!13 = !{!"0x2e\00fn\00fn\00\001\000\001\000\006\00256\000\001", !24, !14, !7, null, i32 (i32)* @fn, null, null, !1} ; [ DW_TAG_subprogram ] [line 1] [def] [fn]
!14 = !{!"0x29", !24} ; [ DW_TAG_file_type ]
!15 = !{!"0x101\00a\0016777218\000", !5, !6, !9} ; [ DW_TAG_arg_variable ] [a] [line 2]
-!16 = !{i32 2, i32 0, !5, null}
-!17 = !{i32 4, i32 0, !18, null}
+!16 = !MDLocation(line: 2, scope: !5)
+!17 = !MDLocation(line: 4, scope: !18)
!18 = !{!"0xb\003\000\000", !23, !5} ; [ DW_TAG_lexical_block ]
!19 = !{!"0x101\00a\0016777217\000", !13, !14, !9} ; [ DW_TAG_arg_variable ] [a] [line 1]
-!20 = !{i32 1, i32 0, !13, null}
-!21 = !{i32 2, i32 0, !22, null}
+!20 = !MDLocation(line: 1, scope: !13)
+!21 = !MDLocation(line: 2, scope: !22)
!22 = !{!"0xb\001\000\000", !24, !13} ; [ DW_TAG_lexical_block ]
!23 = !{!"simple.c", !"/private/tmp"}
!24 = !{!"simple2.c", !"/private/tmp"}
diff --git a/llvm/test/DebugInfo/X86/subrange-type.ll b/llvm/test/DebugInfo/X86/subrange-type.ll
index c1bd51e66c4..65d19f2bd44 100644
--- a/llvm/test/DebugInfo/X86/subrange-type.ll
+++ b/llvm/test/DebugInfo/X86/subrange-type.ll
@@ -34,7 +34,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
!12 = !{!"0x1\00\000\0064\0032\000\000", null, null, !9, !13, i32 0, null, null, null} ; [ DW_TAG_array_type ] [line 0, size 64, align 32, offset 0] [from int]
!13 = !{!14}
!14 = !{!"0x21\000\002"} ; [ DW_TAG_subrange_type ] [0, 1]
-!15 = !{i32 4, i32 0, !11, null}
-!16 = !{i32 6, i32 0, !11, null}
+!15 = !MDLocation(line: 4, scope: !11)
+!16 = !MDLocation(line: 6, scope: !11)
!17 = !{!"foo.c", !"/usr/local/google/home/echristo/tmp"}
!18 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/subreg.ll b/llvm/test/DebugInfo/X86/subreg.ll
index a9a566cb077..2a1de49368f 100644
--- a/llvm/test/DebugInfo/X86/subreg.ll
+++ b/llvm/test/DebugInfo/X86/subreg.ll
@@ -28,7 +28,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
!4 = !{!"0x15\00\000\000\000\000\000\000", !10, !2, null, !5, null, null, null} ; [ DW_TAG_subroutine_type ] [line 0, size 0, align 0, offset 0] [from ]
!5 = !{null}
!6 = !{!"0x24\00short\000\0016\0016\000\000\005", null, !3} ; [ DW_TAG_base_type ]
-!7 = !{i32 4, i32 22, !8, null}
+!7 = !MDLocation(line: 4, column: 22, scope: !8)
!8 = !{!"0xb\003\0019\000", !10, !1} ; [ DW_TAG_lexical_block ]
!10 = !{!"/home/espindola/llvm/test.c", !"/home/espindola/tmpfs/build"}
!11 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/subregisters.ll b/llvm/test/DebugInfo/X86/subregisters.ll
index dc61355c422..8e912adbed1 100644
--- a/llvm/test/DebugInfo/X86/subregisters.ll
+++ b/llvm/test/DebugInfo/X86/subregisters.ll
@@ -103,15 +103,15 @@ attributes #4 = { nounwind }
!22 = !{i32 2, !"Dwarf Version", i32 2}
!23 = !{i32 1, !"Debug Info Version", i32 2}
!24 = !{!"clang version 3.5 "}
-!25 = !{i32 10, i32 0, !4, null}
-!26 = !{i32 12, i32 0, !4, null}
+!25 = !MDLocation(line: 10, scope: !4)
+!26 = !MDLocation(line: 12, scope: !4)
!27 = !{!28, !29, i64 0}
!28 = !{!"bar", !29, i64 0, !29, i64 4}
!29 = !{!"int", !30, i64 0}
!30 = !{!"omnipotent char", !31, i64 0}
!31 = !{!"Simple C/C++ TBAA"}
-!32 = !{i32 13, i32 0, !4, null}
-!33 = !{i32 14, i32 0, !4, null}
-!34 = !{i32 18, i32 0, !17, null}
-!35 = !{i32 19, i32 0, !17, null}
-!36 = !{i32 20, i32 0, !17, null}
+!32 = !MDLocation(line: 13, scope: !4)
+!33 = !MDLocation(line: 14, scope: !4)
+!34 = !MDLocation(line: 18, scope: !17)
+!35 = !MDLocation(line: 19, scope: !17)
+!36 = !MDLocation(line: 20, scope: !17)
diff --git a/llvm/test/DebugInfo/X86/template.ll b/llvm/test/DebugInfo/X86/template.ll
index 43e3727520f..5125b09f91e 100644
--- a/llvm/test/DebugInfo/X86/template.ll
+++ b/llvm/test/DebugInfo/X86/template.ll
@@ -125,6 +125,6 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe
!33 = !{i32 2, !"Dwarf Version", i32 4}
!34 = !{i32 2, !"Debug Info Version", i32 2}
!35 = !{!"clang version 3.6.0 (trunk 224394) (llvm/trunk 224384)"}
-!36 = !{i32 3, i32 12, !10, null}
-!37 = !{i32 1, i32 96, !14, null}
-!38 = !{i32 0, i32 0, !28, null}
+!36 = !MDLocation(line: 3, column: 12, scope: !10)
+!37 = !MDLocation(line: 1, column: 96, scope: !14)
+!38 = !MDLocation(line: 0, scope: !28)
diff --git a/llvm/test/DebugInfo/X86/tls.ll b/llvm/test/DebugInfo/X86/tls.ll
index b4d65bedb03..6f673dd378b 100644
--- a/llvm/test/DebugInfo/X86/tls.ll
+++ b/llvm/test/DebugInfo/X86/tls.ll
@@ -99,4 +99,4 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe
!15 = !{i32 2, !"Dwarf Version", i32 4}
!16 = !{i32 1, !"Debug Info Version", i32 2}
!17 = !{!"clang version 3.5 "}
-!18 = !{i32 6, i32 0, !4, null}
+!18 = !MDLocation(line: 6, scope: !4)
diff --git a/llvm/test/DebugInfo/X86/union-template.ll b/llvm/test/DebugInfo/X86/union-template.ll
index d6d3cad9259..df070542687 100644
--- a/llvm/test/DebugInfo/X86/union-template.ll
+++ b/llvm/test/DebugInfo/X86/union-template.ll
@@ -53,8 +53,8 @@ attributes #1 = { nounwind readnone }
!21 = !{!22}
!22 = !{!"0x2f\00T\000\000", null, !8, null} ; [ DW_TAG_template_type_parameter ]
!23 = !{!"0x101\00value\0016777219\000", !4, !11, !8} ; [ DW_TAG_arg_variable ] [value] [line 3]
-!24 = !{i32 3, i32 0, !4, null}
+!24 = !MDLocation(line: 3, scope: !4)
!25 = !{!"0x100\00tempValue\004\000", !4, !11, !12} ; [ DW_TAG_auto_variable ] [tempValue] [line 4]
-!26 = !{i32 4, i32 0, !4, null}
-!27 = !{i32 5, i32 0, !4, null}
+!26 = !MDLocation(line: 4, scope: !4)
+!27 = !MDLocation(line: 5, scope: !4)
!28 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/X86/vla.ll b/llvm/test/DebugInfo/X86/vla.ll
index da49a84eb96..b2f2f3d922d 100644
--- a/llvm/test/DebugInfo/X86/vla.ll
+++ b/llvm/test/DebugInfo/X86/vla.ll
@@ -91,17 +91,17 @@ entry:
!13 = !{!"0xf\00\000\0064\0064\000\000", null, null, !14} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from char]
!14 = !{!"0x24\00char\000\008\008\000\000\006", null, null} ; [ DW_TAG_base_type ] [char] [line 0, size 8, align 8, offset 0, enc DW_ATE_signed_char]
!15 = !{!"0x101\00n\0016777217\000", !4, !5, !8} ; [ DW_TAG_arg_variable ] [n] [line 1]
-!16 = !{i32 1, i32 0, !4, null}
-!17 = !{i32 2, i32 0, !4, null}
+!16 = !MDLocation(line: 1, scope: !4)
+!17 = !MDLocation(line: 2, scope: !4)
!18 = !{!"0x100\00a\002\008192", !4, !5, !19} ; [ DW_TAG_auto_variable ] [a] [line 2]
!19 = !{!"0x1\00\000\000\0032\000\000", null, null, !8, !20, i32 0, null, null, null} ; [ DW_TAG_array_type ] [line 0, size 0, align 32, offset 0] [from int]
!20 = !{!21}
!21 = !{!"0x21\000\00-1"} ; [ DW_TAG_subrange_type ] [unbounded]
-!22 = !{i32 3, i32 0, !4, null}
-!23 = !{i32 4, i32 0, !4, null}
-!24 = !{i32 5, i32 0, !4, null}
+!22 = !MDLocation(line: 3, scope: !4)
+!23 = !MDLocation(line: 4, scope: !4)
+!24 = !MDLocation(line: 5, scope: !4)
!25 = !{!"0x101\00argc\0016777223\000", !9, !5, !8} ; [ DW_TAG_arg_variable ] [argc] [line 7]
-!26 = !{i32 7, i32 0, !9, null}
+!26 = !MDLocation(line: 7, scope: !9)
!27 = !{!"0x101\00argv\0033554439\000", !9, !5, !12} ; [ DW_TAG_arg_variable ] [argv] [line 7]
-!28 = !{i32 8, i32 0, !9, null}
+!28 = !MDLocation(line: 8, scope: !9)
!29 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/array.ll b/llvm/test/DebugInfo/array.ll
index a9e05103860..4439571e707 100644
--- a/llvm/test/DebugInfo/array.ll
+++ b/llvm/test/DebugInfo/array.ll
@@ -31,8 +31,8 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone
;CHECK-NOT: DW_AT_upper_bound
;CHECK-NEXT: End Of Children Mark
!10 = !{!"0x21\000\00-1"} ; [ DW_TAG_subrange_type ]
-!11 = !{i32 4, i32 7, !7, null}
-!12 = !{i32 5, i32 3, !7, null}
+!11 = !MDLocation(line: 4, column: 7, scope: !7)
+!12 = !MDLocation(line: 5, column: 3, scope: !7)
!13 = !{!0}
!14 = !{!"array.c", !"/private/tmp"}
!15 = !{i32 0}
diff --git a/llvm/test/DebugInfo/block-asan.ll b/llvm/test/DebugInfo/block-asan.ll
index 0a4a8ac4bf2..b25aee1b5ce 100644
--- a/llvm/test/DebugInfo/block-asan.ll
+++ b/llvm/test/DebugInfo/block-asan.ll
@@ -81,7 +81,7 @@ attributes #3 = { nounwind }
!20 = !{!"0xd\00__size\000\0032\0032\00160\000", !1, !5, !19} ; [ DW_TAG_member ] [__size] [line 0, size 32, align 32, offset 160] [from int]
!21 = !{!"0xd\00x\000\0032\0032\00192\000", !1, !5, !19} ; [ DW_TAG_member ] [x] [line 0, size 32, align 32, offset 192] [from int]
!22 = !{!"0x102\0034\008\006\0034\0024"} ; [ DW_TAG_expression ] [DW_OP_plus 8] [DW_OP_deref] [DW_OP_plus 24]
-!23 = !{i32 4, i32 15, !4, null}
-!24 = !{i32 4, i32 3, !4, null}
-!25 = !{i32 5, i32 3, !4, null}
-!26 = !{i32 6, i32 1, !4, null}
+!23 = !MDLocation(line: 4, column: 15, scope: !4)
+!24 = !MDLocation(line: 4, column: 3, scope: !4)
+!25 = !MDLocation(line: 5, column: 3, scope: !4)
+!26 = !MDLocation(line: 6, column: 1, scope: !4)
diff --git a/llvm/test/DebugInfo/constant-pointers.ll b/llvm/test/DebugInfo/constant-pointers.ll
index 52ffd8ea0e0..add97801b6f 100644
--- a/llvm/test/DebugInfo/constant-pointers.ll
+++ b/llvm/test/DebugInfo/constant-pointers.ll
@@ -48,4 +48,4 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe
!15 = !{i32 2, !"Dwarf Version", i32 4}
!16 = !{i32 2, !"Debug Info Version", i32 2}
!17 = !{!"clang version 3.5.0 "}
-!18 = !{i32 3, i32 0, !4, null}
+!18 = !MDLocation(line: 3, scope: !4)
diff --git a/llvm/test/DebugInfo/cross-cu-inlining.ll b/llvm/test/DebugInfo/cross-cu-inlining.ll
index 74ad5ad811b..fafa3fa4e8f 100644
--- a/llvm/test/DebugInfo/cross-cu-inlining.ll
+++ b/llvm/test/DebugInfo/cross-cu-inlining.ll
@@ -131,10 +131,10 @@ attributes #3 = { nounwind }
!16 = !{i32 2, !"Dwarf Version", i32 4}
!17 = !{i32 2, !"Debug Info Version", i32 2}
!18 = !{!"clang version 3.5.0 "}
-!19 = !{i32 4, i32 0, !4, null}
+!19 = !MDLocation(line: 4, scope: !4)
!20 = !{!"0x101\00x\0016777217\000", !12, !13, !8} ; [ DW_TAG_arg_variable ] [x] [line 1]
-!21 = !{i32 1, i32 0, !12, !19}
-!22 = !{i32 2, i32 0, !12, !19}
-!23 = !{i32 1, i32 0, !12, null}
-!24 = !{i32 2, i32 0, !12, null}
+!21 = !MDLocation(line: 1, scope: !12, inlinedAt: !19)
+!22 = !MDLocation(line: 2, scope: !12, inlinedAt: !19)
+!23 = !MDLocation(line: 1, scope: !12)
+!24 = !MDLocation(line: 2, scope: !12)
diff --git a/llvm/test/DebugInfo/cross-cu-linkonce-distinct.ll b/llvm/test/DebugInfo/cross-cu-linkonce-distinct.ll
index 26366d1bbd5..2bd7c471835 100644
--- a/llvm/test/DebugInfo/cross-cu-linkonce-distinct.ll
+++ b/llvm/test/DebugInfo/cross-cu-linkonce-distinct.ll
@@ -91,5 +91,5 @@ attributes #1 = { nounwind readnone }
!20 = !{i32 1, !"Debug Info Version", i32 2}
!21 = !{!"clang version 3.5.0 "}
!22 = !{!"0x101\00i\0016777217\000", !4, !5, !8} ; [ DW_TAG_arg_variable ] [i] [line 1]
-!23 = !{i32 1, i32 0, !4, null}
-!24 = !{i32 2, i32 0, !4, null}
+!23 = !MDLocation(line: 1, scope: !4)
+!24 = !MDLocation(line: 2, scope: !4)
diff --git a/llvm/test/DebugInfo/cross-cu-linkonce.ll b/llvm/test/DebugInfo/cross-cu-linkonce.ll
index c8058cb5997..aaae4c169d4 100644
--- a/llvm/test/DebugInfo/cross-cu-linkonce.ll
+++ b/llvm/test/DebugInfo/cross-cu-linkonce.ll
@@ -69,5 +69,5 @@ attributes #1 = { nounwind readnone }
!18 = !{i32 1, !"Debug Info Version", i32 2}
!19 = !{!"clang version 3.5.0 "}
!20 = !{!"0x101\00i\0016777217\000", !4, !6, !9} ; [ DW_TAG_arg_variable ] [i] [line 1]
-!21 = !{i32 1, i32 0, !4, null}
-!22 = !{i32 2, i32 0, !4, null}
+!21 = !MDLocation(line: 1, scope: !4)
+!22 = !MDLocation(line: 2, scope: !4)
diff --git a/llvm/test/DebugInfo/cu-range-hole.ll b/llvm/test/DebugInfo/cu-range-hole.ll
index 274072def35..aa489b60d8c 100644
--- a/llvm/test/DebugInfo/cu-range-hole.ll
+++ b/llvm/test/DebugInfo/cu-range-hole.ll
@@ -69,6 +69,6 @@ attributes #1 = { nounwind readnone }
!11 = !{i32 2, !"Dwarf Version", i32 4}
!12 = !{i32 1, !"Debug Info Version", i32 2}
!13 = !{!"0x101\00c\0016777217\000", !5, !6, !9} ; [ DW_TAG_arg_variable ] [c] [line 1]
-!14 = !{i32 1, i32 0, !5, null}
+!14 = !MDLocation(line: 1, scope: !5)
!15 = !{!"0x101\00e\0016777219\000", !10, !6, !9} ; [ DW_TAG_arg_variable ] [e] [line 3]
-!16 = !{i32 3, i32 0, !10, null}
+!16 = !MDLocation(line: 3, scope: !10)
diff --git a/llvm/test/DebugInfo/cu-ranges.ll b/llvm/test/DebugInfo/cu-ranges.ll
index 8876c4c4682..6296b93792c 100644
--- a/llvm/test/DebugInfo/cu-ranges.ll
+++ b/llvm/test/DebugInfo/cu-ranges.ll
@@ -63,9 +63,9 @@ attributes #1 = { nounwind readnone }
!11 = !{i32 1, !"Debug Info Version", i32 2}
!12 = !{!"clang version 3.5.0 (trunk 204164) (llvm/trunk 204183)"}
!13 = !{!"0x101\00a\0016777217\000", !4, !5, !8} ; [ DW_TAG_arg_variable ] [a] [line 1]
-!14 = !{i32 1, i32 0, !4, null}
-!15 = !{i32 2, i32 0, !4, null}
+!14 = !MDLocation(line: 1, scope: !4)
+!15 = !MDLocation(line: 2, scope: !4)
!16 = !{!"0x101\00a\0016777221\000", !9, !5, !8} ; [ DW_TAG_arg_variable ] [a] [line 5]
-!17 = !{i32 5, i32 0, !9, null}
-!18 = !{i32 6, i32 0, !9, null}
+!17 = !MDLocation(line: 5, scope: !9)
+!18 = !MDLocation(line: 6, scope: !9)
diff --git a/llvm/test/DebugInfo/dead-argument-order.ll b/llvm/test/DebugInfo/dead-argument-order.ll
index fd7340a5929..d375412141a 100644
--- a/llvm/test/DebugInfo/dead-argument-order.ll
+++ b/llvm/test/DebugInfo/dead-argument-order.ll
@@ -77,5 +77,5 @@ attributes #1 = { nounwind readnone }
!17 = !{i32 2, !"Debug Info Version", i32 2}
!18 = !{!"clang version 3.5.0 "}
!19 = !{%struct.S* undef}
-!20 = !{i32 2, i32 0, !9, null}
+!20 = !MDLocation(line: 2, scope: !9)
diff --git a/llvm/test/DebugInfo/debug-info-always-inline.ll b/llvm/test/DebugInfo/debug-info-always-inline.ll
index db2d0dab348..88ac4cb39d5 100644
--- a/llvm/test/DebugInfo/debug-info-always-inline.ll
+++ b/llvm/test/DebugInfo/debug-info-always-inline.ll
@@ -132,12 +132,12 @@ attributes #3 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="false" "
!15 = !{i32 786433, null, null, !"", i32 0, i64 320, i64 32, i32 0, i32 0, !9, !16, i32 0, null, null, null} ; [ DW_TAG_array_type ] [line 0, size 320, align 32, offset 0] [from int]
!16 = !{!17}
!17 = !{i32 786465, i64 0, i64 10} ; [ DW_TAG_subrange_type ] [0, 9]
-!18 = !{i32 3, i32 0, !4, null}
-!19 = !{i32 4, i32 0, !4, null}
+!18 = !MDLocation(line: 3, scope: !4)
+!19 = !MDLocation(line: 4, scope: !4)
!20 = !{i32 786688, !4, !"sum", !6, i32 5, !9, i32 0, i32 0} ; [ DW_TAG_auto_variable ] [sum] [line 5]
-!21 = !{i32 5, i32 0, !4, null}
-!22 = !{i32 6, i32 0, !4, null}
-!23 = !{i32 13, i32 0, !10, null}
+!21 = !MDLocation(line: 5, scope: !4)
+!22 = !MDLocation(line: 6, scope: !4)
+!23 = !MDLocation(line: 13, scope: !10)
!24 = !{i32 786688, !10, !"i", !6, i32 14, !9, i32 0, i32 0} ; [ DW_TAG_auto_variable ] [i] [line 14]
-!25 = !{i32 14, i32 0, !10, null}
-!26 = !{i32 15, i32 0, !10, null}
+!25 = !MDLocation(line: 14, scope: !10)
+!26 = !MDLocation(line: 15, scope: !10)
diff --git a/llvm/test/DebugInfo/debug-info-qualifiers.ll b/llvm/test/DebugInfo/debug-info-qualifiers.ll
index e2fe53ce232..b0f9cd4c83b 100644
--- a/llvm/test/DebugInfo/debug-info-qualifiers.ll
+++ b/llvm/test/DebugInfo/debug-info-qualifiers.ll
@@ -86,15 +86,15 @@ attributes #1 = { nounwind readnone }
!22 = !{i32 1, !"Debug Info Version", i32 2}
!23 = !{!"clang version 3.5 "}
!24 = !{!"0x100\00a\0011\000", !17, !18, !4} ; [ DW_TAG_auto_variable ] [a] [line 11]
-!25 = !{i32 11, i32 0, !17, null}
+!25 = !MDLocation(line: 11, scope: !17)
!26 = !{!"0x100\00pl\0016\000", !17, !18, !27} ; [ DW_TAG_auto_variable ] [pl] [line 16]
!27 = !{!"0x1f\00\000\000\000\000\000", null, null, !28, !"_ZTS1A"} ; [ DW_TAG_ptr_to_member_type ] [line 0, size 0, align 0, offset 0] [from ]
!28 = !{!"0x15\00\000\000\000\000\0016384\000", i32 0, null, null, !29, null, null, null} ; [ DW_TAG_subroutine_type ] [line 0, size 0, align 0, offset 0] [reference] [from ]
!29 = !{null, !30}
!30 = !{!"0xf\00\000\0064\0064\000\001088", null, null, !"_ZTS1A"} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [artificial] [from _ZTS1A]
-!31 = !{i32 16, i32 0, !17, null}
+!31 = !MDLocation(line: 16, scope: !17)
!32 = !{!"0x100\00pr\0021\000", !17, !18, !33} ; [ DW_TAG_auto_variable ] [pr] [line 21]
!33 = !{!"0x1f\00\000\000\000\000\000", null, null, !34, !"_ZTS1A"} ; [ DW_TAG_ptr_to_member_type ] [line 0, size 0, align 0, offset 0] [from ]
!34 = !{!"0x15\00\000\000\000\000\0032768\000", i32 0, null, null, !29, null, null, null} ; [ DW_TAG_subroutine_type ] [line 0, size 0, align 0, offset 0] [rvalue reference] [from ]
-!35 = !{i32 21, i32 0, !17, null}
-!36 = !{i32 22, i32 0, !17, null}
+!35 = !MDLocation(line: 21, scope: !17)
+!36 = !MDLocation(line: 22, scope: !17)
diff --git a/llvm/test/DebugInfo/debuginfofinder-multiple-cu.ll b/llvm/test/DebugInfo/debuginfofinder-multiple-cu.ll
index a8054bc5113..0eba64d2ea6 100644
--- a/llvm/test/DebugInfo/debuginfofinder-multiple-cu.ll
+++ b/llvm/test/DebugInfo/debuginfofinder-multiple-cu.ll
@@ -36,6 +36,6 @@ define void @g() {
!11 = !{!"0x2e\00g\00g\00\001\000\001\000\006\000\000\001", !9, !12, !6, null, void ()* @g, null, null, !2} ; [ DW_TAG_subprogram ] [line 1] [def] [g]
!12 = !{!"0x29", !9} ; [ DW_TAG_file_type ] [/tmp/test2.c]
!13 = !{i32 2, !"Dwarf Version", i32 4}
-!14 = !{i32 1, i32 0, !4, null}
-!15 = !{i32 1, i32 0, !11, null}
+!14 = !MDLocation(line: 1, scope: !4)
+!15 = !MDLocation(line: 1, scope: !11)
!16 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/duplicate_inline.ll b/llvm/test/DebugInfo/duplicate_inline.ll
index 71b2970dc6d..2a9c485632b 100644
--- a/llvm/test/DebugInfo/duplicate_inline.ll
+++ b/llvm/test/DebugInfo/duplicate_inline.ll
@@ -20,14 +20,14 @@
; appears to be only one inlined function.
; To fix this, we'd need to add some kind of unique metadata per call site, possibly something like:
;
-; !42 = !{i32 1, i32 0, !43, !44}
-; !44 = !{i32 2, i32 0, !45, null}
+; !42 = !MDLocation(line: 1, scope: !43, inlinedAt: !44)
+; !44 = !MDLocation(line: 2, scope: !45)
;
; ->
;
-; !42 = !{i32 1, i32 0, !43, !44}
+; !42 = !MDLocation(line: 1, scope: !43, inlinedAt: !44)
; !44 = !{!45, !44}
-; !45 = !{i32 2, i32 0, !45, null}
+; !45 = !MDLocation(line: 2, scope: !45)
;
; since cycles in metadata are not uniqued, the !44 node would not be shared
; between calls to the same function from the same location, ensuring separate
@@ -107,11 +107,11 @@ attributes #2 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n
!14 = !{!"clang version 3.6.0 "}
!15 = !{!"0x101\00x\0016777224\000", !4, !5, !8} ; [ DW_TAG_arg_variable ] [x] [line 8]
!16 = !{!"0x102"} ; [ DW_TAG_expression ]
-!17 = !{i32 8, i32 13, !4, null}
+!17 = !MDLocation(line: 8, column: 13, scope: !4)
!18 = !{!"0x101\00y\0033554440\000", !4, !5, !8} ; [ DW_TAG_arg_variable ] [y] [line 8]
-!19 = !{i32 8, i32 20, !4, null}
-!20 = !{i32 8, i32 25, !4, null}
+!19 = !MDLocation(line: 8, column: 20, scope: !4)
+!20 = !MDLocation(line: 8, column: 25, scope: !4)
!21 = !{!"0x101\00i\0016777218\000", !9, !5, !8} ; [ DW_TAG_arg_variable ] [i] [line 2]
-!22 = !{i32 2, i32 51, !9, !20}
-!23 = !{i32 2, i32 56, !9, !20}
-!24 = !{i32 8, i32 36, !4, null}
+!22 = !MDLocation(line: 2, column: 51, scope: !9, inlinedAt: !20)
+!23 = !MDLocation(line: 2, column: 56, scope: !9, inlinedAt: !20)
+!24 = !MDLocation(line: 8, column: 36, scope: !4)
diff --git a/llvm/test/DebugInfo/dwarf-public-names.ll b/llvm/test/DebugInfo/dwarf-public-names.ll
index 489686c9f34..d2b86642043 100644
--- a/llvm/test/DebugInfo/dwarf-public-names.ll
+++ b/llvm/test/DebugInfo/dwarf-public-names.ll
@@ -120,12 +120,12 @@ attributes #1 = { nounwind readnone }
!27 = !{!"0x34\00global_namespace_variable\00global_namespace_variable\00_ZN2ns25global_namespace_variableE\0027\000\001", !21, !4, !11, i32* @_ZN2ns25global_namespace_variableE, null} ; [ DW_TAG_variable ] [global_namespace_variable] [line 27] [def]
!28 = !{!"0x101\00this\0016777225\001088", !3, !4, !29} ; [ DW_TAG_arg_variable ] [this] [line 9]
!29 = !{!"0xf\00\000\0064\0064\000\000", null, null, !8} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from C]
-!30 = !{i32 9, i32 0, !3, null}
-!31 = !{i32 10, i32 0, !3, null}
-!32 = !{i32 11, i32 0, !3, null}
-!33 = !{i32 14, i32 0, !18, null}
-!34 = !{i32 20, i32 0, !19, null}
-!35 = !{i32 25, i32 0, !20, null}
-!36 = !{i32 26, i32 0, !20, null}
+!30 = !MDLocation(line: 9, scope: !3)
+!31 = !MDLocation(line: 10, scope: !3)
+!32 = !MDLocation(line: 11, scope: !3)
+!33 = !MDLocation(line: 14, scope: !18)
+!34 = !MDLocation(line: 20, scope: !19)
+!35 = !MDLocation(line: 25, scope: !20)
+!36 = !MDLocation(line: 26, scope: !20)
!37 = !{!"dwarf-public-names.cpp", !"/usr2/kparzysz/s.hex/t"}
!38 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/enum-types.ll b/llvm/test/DebugInfo/enum-types.ll
index 2edfaa03f0e..3932535b4c4 100644
--- a/llvm/test/DebugInfo/enum-types.ll
+++ b/llvm/test/DebugInfo/enum-types.ll
@@ -71,8 +71,8 @@ attributes #1 = { nounwind readnone }
!20 = !{i32 2, !"Debug Info Version", i32 2}
!21 = !{!"clang version 3.5.0 (trunk 214102:214133) (llvm/trunk 214102:214132)"}
!22 = !{!"0x101\00sa\0016777221\000", !7, !8, !"_ZTS2EA"} ; [ DW_TAG_arg_variable ] [sa] [line 5]
-!23 = !{i32 5, i32 14, !7, null}
-!24 = !{i32 6, i32 1, !7, null}
+!23 = !MDLocation(line: 5, column: 14, scope: !7)
+!24 = !MDLocation(line: 6, column: 1, scope: !7)
!25 = !{!"0x101\00sa\0016777221\000", !17, !18, !"_ZTS2EA"} ; [ DW_TAG_arg_variable ] [sa] [line 5]
-!26 = !{i32 5, i32 14, !17, null}
-!27 = !{i32 6, i32 1, !17, null}
+!26 = !MDLocation(line: 5, column: 14, scope: !17)
+!27 = !MDLocation(line: 6, column: 1, scope: !17)
diff --git a/llvm/test/DebugInfo/enum.ll b/llvm/test/DebugInfo/enum.ll
index 09e1a356ee8..4dd4c688ad6 100644
--- a/llvm/test/DebugInfo/enum.ll
+++ b/llvm/test/DebugInfo/enum.ll
@@ -75,6 +75,6 @@ attributes #1 = { nounwind readnone }
!19 = !{i32 2, !"Dwarf Version", i32 3}
!20 = !{!"0x100\00b\004\000", !13, !14, !21} ; [ DW_TAG_auto_variable ] [b] [line 4]
!21 = !{!"0x24\00int\000\0032\0032\000\000\005", null, null} ; [ DW_TAG_base_type ] [int] [line 0, size 32, align 32, offset 0, enc DW_ATE_signed]
-!22 = !{i32 4, i32 0, !13, null}
-!23 = !{i32 5, i32 0, !13, null}
+!22 = !MDLocation(line: 4, scope: !13)
+!23 = !MDLocation(line: 5, scope: !13)
!24 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/global.ll b/llvm/test/DebugInfo/global.ll
index d398d61c976..1715ca8388a 100644
--- a/llvm/test/DebugInfo/global.ll
+++ b/llvm/test/DebugInfo/global.ll
@@ -38,5 +38,5 @@ attributes #0 = { nounwind readnone uwtable "less-precise-fpmad"="false" "no-fra
!9 = !{!10}
!10 = !{!"0x34\00i\00i\00_ZL1i\001\001\001", null, !5, !8, null, null} ; [ DW_TAG_variable ]
!11 = !{i32 2, !"Dwarf Version", i32 3}
-!12 = !{i32 4, i32 0, !4, null}
+!12 = !MDLocation(line: 4, scope: !4)
!13 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/incorrect-variable-debugloc.ll b/llvm/test/DebugInfo/incorrect-variable-debugloc.ll
index 9eaaf773ee4..afccd672f90 100644
--- a/llvm/test/DebugInfo/incorrect-variable-debugloc.ll
+++ b/llvm/test/DebugInfo/incorrect-variable-debugloc.ll
@@ -375,17 +375,17 @@ attributes #3 = { nounwind readnone }
!36 = !{i32 2, !"Dwarf Version", i32 4}
!37 = !{i32 2, !"Debug Info Version", i32 2}
!38 = !{!"clang version 3.5.0 "}
-!39 = !{i32 6, i32 0, !32, !40}
-!40 = !{i32 18, i32 0, !22, null}
+!39 = !MDLocation(line: 6, scope: !32, inlinedAt: !40)
+!40 = !MDLocation(line: 18, scope: !22)
!41 = !{!42, !43, i64 0}
!42 = !{!"_ZTS1B", !43, i64 0}
!43 = !{!"int", !44, i64 0}
!44 = !{!"omnipotent char", !45, i64 0}
!45 = !{!"Simple C/C++ TBAA"}
-!46 = !{i32 17, i32 0, !22, null}
-!47 = !{i32 19, i32 0, !22, null}
-!48 = !{i32 0, i32 0, !28, null}
-!49 = !{i32 22, i32 0, !28, null}
-!50 = !{i32 6, i32 0, !32, !51}
-!51 = !{i32 23, i32 0, !28, null}
-!52 = !{i32 24, i32 0, !28, null}
+!46 = !MDLocation(line: 17, scope: !22)
+!47 = !MDLocation(line: 19, scope: !22)
+!48 = !MDLocation(line: 0, scope: !28)
+!49 = !MDLocation(line: 22, scope: !28)
+!50 = !MDLocation(line: 6, scope: !32, inlinedAt: !51)
+!51 = !MDLocation(line: 23, scope: !28)
+!52 = !MDLocation(line: 24, scope: !28)
diff --git a/llvm/test/DebugInfo/incorrect-variable-debugloc1.ll b/llvm/test/DebugInfo/incorrect-variable-debugloc1.ll
index 99c861a35ab..18f2dc78e3e 100644
--- a/llvm/test/DebugInfo/incorrect-variable-debugloc1.ll
+++ b/llvm/test/DebugInfo/incorrect-variable-debugloc1.ll
@@ -70,8 +70,8 @@ attributes #2 = { nounwind readnone }
!14 = !{!"clang version 3.6.0 (trunk 223522)"}
!15 = !{i32 13}
!16 = !{!"0x102"} ; [ DW_TAG_expression ]
-!17 = !{i32 5, i32 16, !4, null}
-!18 = !{i32 5, i32 3, !4, null}
-!19 = !{i32 6, i32 7, !4, null}
-!20 = !{i32 7, i32 3, !4, null}
+!17 = !MDLocation(line: 5, column: 16, scope: !4)
+!18 = !MDLocation(line: 5, column: 3, scope: !4)
+!19 = !MDLocation(line: 6, column: 7, scope: !4)
+!20 = !MDLocation(line: 7, column: 3, scope: !4)
diff --git a/llvm/test/DebugInfo/inheritance.ll b/llvm/test/DebugInfo/inheritance.ll
index 0a2261ad591..ab71d25d625 100644
--- a/llvm/test/DebugInfo/inheritance.ll
+++ b/llvm/test/DebugInfo/inheritance.ll
@@ -126,29 +126,29 @@ declare void @_ZdlPv(i8*) nounwind
!18 = !{!"0x2e\00~test1\00~test1\00\004\000\000\001\006\000\000\000", i32 0, !8, !19, !8, null, null, null, null} ; [ DW_TAG_subprogram ]
!19 = !{!"0x15\00\000\000\000\000\000\000", !4, null, null, !20, null, null, null} ; [ DW_TAG_subroutine_type ] [line 0, size 0, align 0, offset 0] [from ]
!20 = !{null, !17, !7}
-!21 = !{i32 11, i32 0, !1, null}
-!22 = !{i32 13, i32 0, !1, null}
-!23 = !{i32 14, i32 0, !1, null}
+!21 = !MDLocation(line: 11, scope: !1)
+!22 = !MDLocation(line: 13, scope: !1)
+!23 = !MDLocation(line: 14, scope: !1)
!24 = !{!"0x101\00this\0013\000", !25, !4, !26} ; [ DW_TAG_arg_variable ]
!25 = !{!"0x2e\00test1\00test1\00_ZN5test1C1Ev\001\000\001\000\006\000\000\000", i32 0, !4, !15, null, null, null, null, null} ; [ DW_TAG_subprogram ]
!26 = !{!"0x26\00\000\0064\0064\000\0064", !4, null, !27} ; [ DW_TAG_const_type ]
!27 = !{!"0xf\00\000\0064\0064\000\000", !4, null, !8} ; [ DW_TAG_pointer_type ]
-!28 = !{i32 1, i32 0, !25, null}
-!29 = !{i32 1, i32 0, !30, null}
+!28 = !MDLocation(line: 1, scope: !25)
+!29 = !MDLocation(line: 1, scope: !30)
!30 = !{!"0xb\000\000\000", !44, !31} ; [ DW_TAG_lexical_block ]
!31 = !{!"0xb\000\000\000", !44, !25} ; [ DW_TAG_lexical_block ]
!32 = !{!"0x101\00this\004\000", !33, !4, !26} ; [ DW_TAG_arg_variable ]
!33 = !{!"0x2e\00~test1\00~test1\00_ZN5test1D1Ev\004\000\001\001\006\000\000\000", i32 0, !8, !15, !8, null, null, null, null} ; [ DW_TAG_subprogram ]
-!34 = !{i32 4, i32 0, !33, null}
-!35 = !{i32 5, i32 0, !36, null}
+!34 = !MDLocation(line: 4, scope: !33)
+!35 = !MDLocation(line: 5, scope: !36)
!36 = !{!"0xb\000\000\000", !44, !33} ; [ DW_TAG_lexical_block ]
-!37 = !{i32 6, i32 0, !36, null}
+!37 = !MDLocation(line: 6, scope: !36)
!38 = !{!"0x101\00this\004\000", !39, !4, !26} ; [ DW_TAG_arg_variable ]
!39 = !{!"0x2e\00~test1\00~test1\00_ZN5test1D0Ev\004\000\001\001\006\000\000\000", i32 0, !8, !15, !8, null, null, null, null} ; [ DW_TAG_subprogram ]
-!40 = !{i32 4, i32 0, !39, null}
-!41 = !{i32 5, i32 0, !42, null}
+!40 = !MDLocation(line: 4, scope: !39)
+!41 = !MDLocation(line: 5, scope: !42)
!42 = !{!"0xb\000\000\000", !44, !39} ; [ DW_TAG_lexical_block ]
-!43 = !{i32 6, i32 0, !42, null}
+!43 = !MDLocation(line: 6, scope: !42)
!44 = !{!"inheritance.cpp", !"/tmp/"}
!45 = !{i32 0}
!46 = !{!"<built-in>", !"/tmp/"}
diff --git a/llvm/test/DebugInfo/inline-debug-info-multiret.ll b/llvm/test/DebugInfo/inline-debug-info-multiret.ll
index 18d8a733e7f..0115ecd3a8d 100644
--- a/llvm/test/DebugInfo/inline-debug-info-multiret.ll
+++ b/llvm/test/DebugInfo/inline-debug-info-multiret.ll
@@ -10,8 +10,8 @@
; CHECK: br label %invoke.cont, !dbg ![[MD]]
; The branch instruction has the source location of line 9 and its inlined location
; has the source location of line 14.
-; CHECK: ![[INL:[0-9]+]] = !{i32 14, i32 0, {{.*}}, null}
-; CHECK: ![[MD]] = !{i32 9, i32 0, {{.*}}, ![[INL]]}
+; CHECK: ![[INL:[0-9]+]] = !MDLocation(line: 14, scope: {{.*}})
+; CHECK: ![[MD]] = !MDLocation(line: 9, scope: {{.*}}, inlinedAt: ![[INL]])
; ModuleID = 'test.cpp'
target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64-S128"
@@ -136,21 +136,21 @@ attributes #2 = { nounwind }
!11 = !{!"0x15\00\000\000\000\000\000\000", i32 0, null, null, !12, null, null, null} ; [ DW_TAG_subroutine_type ] [line 0, size 0, align 0, offset 0] [from ]
!12 = !{!9}
!13 = !{!"0x101\00k\0016777220\000", !4, !6, !9} ; [ DW_TAG_arg_variable ] [k] [line 4]
-!14 = !{i32 4, i32 0, !4, null}
+!14 = !MDLocation(line: 4, scope: !4)
!15 = !{!"0x100\00k2\005\000", !4, !6, !9} ; [ DW_TAG_auto_variable ] [k2] [line 5]
-!16 = !{i32 5, i32 0, !4, null}
-!17 = !{i32 6, i32 0, !4, null}
-!18 = !{i32 7, i32 0, !4, null}
-!19 = !{i32 8, i32 0, !4, null}
-!20 = !{i32 9, i32 0, !4, null}
-!21 = !{i32 14, i32 0, !22, null}
+!16 = !MDLocation(line: 5, scope: !4)
+!17 = !MDLocation(line: 6, scope: !4)
+!18 = !MDLocation(line: 7, scope: !4)
+!19 = !MDLocation(line: 8, scope: !4)
+!20 = !MDLocation(line: 9, scope: !4)
+!21 = !MDLocation(line: 14, scope: !22)
!22 = !{!"0xb\0013\000\000", !5, !10} ; [ DW_TAG_lexical_block ] [test.cpp]
-!23 = !{i32 15, i32 0, !22, null}
+!23 = !MDLocation(line: 15, scope: !22)
!24 = !{!"0x100\00e\0016\000", !10, !6, !9} ; [ DW_TAG_auto_variable ] [e] [line 16]
-!25 = !{i32 16, i32 0, !10, null}
-!26 = !{i32 17, i32 0, !27, null}
+!25 = !MDLocation(line: 16, scope: !10)
+!26 = !MDLocation(line: 17, scope: !27)
!27 = !{!"0xb\0016\000\001", !5, !10} ; [ DW_TAG_lexical_block ] [test.cpp]
-!28 = !{i32 18, i32 0, !27, null}
-!29 = !{i32 19, i32 0, !10, null}
-!30 = !{i32 20, i32 0, !10, null}
+!28 = !MDLocation(line: 18, scope: !27)
+!29 = !MDLocation(line: 19, scope: !10)
+!30 = !MDLocation(line: 20, scope: !10)
!31 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/inline-debug-info.ll b/llvm/test/DebugInfo/inline-debug-info.ll
index 8f810d2e4f6..5d2f652034d 100644
--- a/llvm/test/DebugInfo/inline-debug-info.ll
+++ b/llvm/test/DebugInfo/inline-debug-info.ll
@@ -31,8 +31,8 @@
; CHECK: br label %invoke.cont, !dbg ![[MD:[0-9]+]]
; The branch instruction has the source location of line 9 and its inlined location
; has the source location of line 14.
-; CHECK: ![[INL:[0-9]+]] = !{i32 14, i32 0, {{.*}}, null}
-; CHECK: ![[MD]] = !{i32 9, i32 0, {{.*}}, ![[INL]]}
+; CHECK: ![[INL:[0-9]+]] = !MDLocation(line: 14, scope: {{.*}})
+; CHECK: ![[MD]] = !MDLocation(line: 9, scope: {{.*}}, inlinedAt: ![[INL]])
; ModuleID = 'test.cpp'
target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64-S128"
@@ -154,21 +154,21 @@ attributes #2 = { nounwind }
!11 = !{!"0x15\00\000\000\000\000\000\000", i32 0, null, null, !12, null, null, null} ; [ DW_TAG_subroutine_type ] [line 0, size 0, align 0, offset 0] [from ]
!12 = !{!9}
!13 = !{!"0x101\00k\0016777220\000", !4, !6, !9} ; [ DW_TAG_arg_variable ] [k] [line 4]
-!14 = !{i32 4, i32 0, !4, null}
+!14 = !MDLocation(line: 4, scope: !4)
!15 = !{!"0x100\00k2\005\000", !4, !6, !9} ; [ DW_TAG_auto_variable ] [k2] [line 5]
-!16 = !{i32 5, i32 0, !4, null}
-!17 = !{i32 6, i32 0, !4, null}
-!18 = !{i32 7, i32 0, !4, null}
-!19 = !{i32 8, i32 0, !4, null}
-!20 = !{i32 9, i32 0, !4, null}
-!21 = !{i32 14, i32 0, !22, null}
+!16 = !MDLocation(line: 5, scope: !4)
+!17 = !MDLocation(line: 6, scope: !4)
+!18 = !MDLocation(line: 7, scope: !4)
+!19 = !MDLocation(line: 8, scope: !4)
+!20 = !MDLocation(line: 9, scope: !4)
+!21 = !MDLocation(line: 14, scope: !22)
!22 = !{!"0xb\0013\000\000", !5, !10} ; [ DW_TAG_lexical_block ] [test.cpp]
-!23 = !{i32 15, i32 0, !22, null}
+!23 = !MDLocation(line: 15, scope: !22)
!24 = !{!"0x100\00e\0016\000", !10, !6, !9} ; [ DW_TAG_auto_variable ] [e] [line 16]
-!25 = !{i32 16, i32 0, !10, null}
-!26 = !{i32 17, i32 0, !27, null}
+!25 = !MDLocation(line: 16, scope: !10)
+!26 = !MDLocation(line: 17, scope: !27)
!27 = !{!"0xb\0016\000\001", !5, !10} ; [ DW_TAG_lexical_block ] [test.cpp]
-!28 = !{i32 18, i32 0, !27, null}
-!29 = !{i32 19, i32 0, !10, null}
-!30 = !{i32 20, i32 0, !10, null}
+!28 = !MDLocation(line: 18, scope: !27)
+!29 = !MDLocation(line: 19, scope: !10)
+!30 = !MDLocation(line: 20, scope: !10)
!31 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/inline-no-debug-info.ll b/llvm/test/DebugInfo/inline-no-debug-info.ll
index 5a88b54fa35..68fd8e7a01b 100644
--- a/llvm/test/DebugInfo/inline-no-debug-info.ll
+++ b/llvm/test/DebugInfo/inline-no-debug-info.ll
@@ -21,10 +21,10 @@
; Debug location of the code in caller() and of the inlined code that did not
; have any debug location before.
-; CHECK-DAG: [[A]] = !{i32 4, i32 0, !{{[01-9]+}}, null}
+; CHECK-DAG: [[A]] = !MDLocation(line: 4, scope: !{{[01-9]+}})
; Debug location of the inlined code.
-; CHECK-DAG: [[B]] = !{i32 2, i32 0, !{{[01-9]+}}, [[A]]}
+; CHECK-DAG: [[B]] = !MDLocation(line: 2, scope: !{{[01-9]+}}, inlinedAt: [[A]])
target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
@@ -65,5 +65,5 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe
!8 = !{i32 2, !"Dwarf Version", i32 4}
!9 = !{i32 2, !"Debug Info Version", i32 2}
!10 = !{!"clang version 3.5.0 (210174)"}
-!11 = !{i32 2, i32 0, !7, null}
-!12 = !{i32 4, i32 0, !4, null}
+!11 = !MDLocation(line: 2, scope: !7)
+!12 = !MDLocation(line: 4, scope: !4)
diff --git a/llvm/test/DebugInfo/inline-scopes.ll b/llvm/test/DebugInfo/inline-scopes.ll
index a4524754b63..ec36a2fdec6 100644
--- a/llvm/test/DebugInfo/inline-scopes.ll
+++ b/llvm/test/DebugInfo/inline-scopes.ll
@@ -114,17 +114,17 @@ attributes #2 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n
!16 = !{!"0x100\00b\003\000", !17, !11, !18} ; [ DW_TAG_auto_variable ] [b] [line 3]
!17 = !{!"0xb\003\000\001", !1, !12} ; [ DW_TAG_lexical_block ] [/tmp/dbginfo/inline-scopes.cpp]
!18 = !{!"0x24\00bool\000\008\008\000\000\002", null, null} ; [ DW_TAG_base_type ] [bool] [line 0, size 8, align 8, offset 0, enc DW_ATE_boolean]
-!19 = !{i32 3, i32 0, !17, !20}
-!20 = !{i32 8, i32 0, !4, null}
-!21 = !{i32 4, i32 0, !17, !20}
-!22 = !{i32 5, i32 0, !12, !20}
-!23 = !{i32 6, i32 0, !12, !20}
+!19 = !MDLocation(line: 3, scope: !17, inlinedAt: !20)
+!20 = !MDLocation(line: 8, scope: !4)
+!21 = !MDLocation(line: 4, scope: !17, inlinedAt: !20)
+!22 = !MDLocation(line: 5, scope: !12, inlinedAt: !20)
+!23 = !MDLocation(line: 6, scope: !12, inlinedAt: !20)
!24 = !{!"0x100\00b\002\000", !25, !6, !18} ; [ DW_TAG_auto_variable ] [b] [line 2]
!25 = !{!"0xb\002\000\000", !5, !26} ; [ DW_TAG_lexical_block ] [/tmp/dbginfo/y.cc]
!26 = !{!"0xb\000", !5, !10} ; [ DW_TAG_lexical_block ] [/tmp/dbginfo/y.cc]
-!27 = !{i32 2, i32 0, !25, !28}
-!28 = !{i32 9, i32 0, !4, null}
-!29 = !{i32 3, i32 0, !25, !28}
-!30 = !{i32 4, i32 0, !26, !28}
-!31 = !{i32 5, i32 0, !26, !28}
-!32 = !{i32 10, i32 0, !4, null}
+!27 = !MDLocation(line: 2, scope: !25, inlinedAt: !28)
+!28 = !MDLocation(line: 9, scope: !4)
+!29 = !MDLocation(line: 3, scope: !25, inlinedAt: !28)
+!30 = !MDLocation(line: 4, scope: !26, inlinedAt: !28)
+!31 = !MDLocation(line: 5, scope: !26, inlinedAt: !28)
+!32 = !MDLocation(line: 10, scope: !4)
diff --git a/llvm/test/DebugInfo/inlined-arguments.ll b/llvm/test/DebugInfo/inlined-arguments.ll
index 115efeb1dff..c705cf8e97f 100644
--- a/llvm/test/DebugInfo/inlined-arguments.ll
+++ b/llvm/test/DebugInfo/inlined-arguments.ll
@@ -67,13 +67,13 @@ attributes #2 = { nounwind readnone }
!14 = !{!"0x101\00y\0033554438\000", !8, !5, !11} ; [ DW_TAG_arg_variable ] [y] [line 6]
!15 = !{i32 undef}
!16 = !{!"0x101\00x\0016777222\000", !8, !5, !11, !17} ; [ DW_TAG_arg_variable ] [x] [line 6]
-!17 = !{i32 4, i32 0, !4, null}
-!18 = !{i32 6, i32 0, !8, !17}
+!17 = !MDLocation(line: 4, scope: !4)
+!18 = !MDLocation(line: 6, scope: !8, inlinedAt: !17)
!19 = !{i32 2}
!20 = !{!"0x101\00y\0033554438\000", !8, !5, !11, !17} ; [ DW_TAG_arg_variable ] [y] [line 6]
-!21 = !{i32 7, i32 0, !8, !17}
-!22 = !{i32 5, i32 0, !4, null}
-!23 = !{i32 6, i32 0, !8, null}
-!24 = !{i32 7, i32 0, !8, null}
-!25 = !{i32 8, i32 0, !8, null}
+!21 = !MDLocation(line: 7, scope: !8, inlinedAt: !17)
+!22 = !MDLocation(line: 5, scope: !4)
+!23 = !MDLocation(line: 6, scope: !8)
+!24 = !MDLocation(line: 7, scope: !8)
+!25 = !MDLocation(line: 8, scope: !8)
!26 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/inlined-vars.ll b/llvm/test/DebugInfo/inlined-vars.ll
index 22f935a9644..b84e12f4ce9 100644
--- a/llvm/test/DebugInfo/inlined-vars.ll
+++ b/llvm/test/DebugInfo/inlined-vars.ll
@@ -46,11 +46,11 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
; VARIABLE-NOT: {{.*Abbrev.*DW_TAG_variable}}
!18 = !{!"0x101\00argument\0016777219\000", !10, !6, !9, !19} ; [ DW_TAG_arg_variable ]
-!19 = !{i32 11, i32 10, !5, null}
-!21 = !{i32 3, i32 25, !10, !19}
+!19 = !MDLocation(line: 11, column: 10, scope: !5)
+!21 = !MDLocation(line: 3, column: 25, scope: !10, inlinedAt: !19)
!22 = !{!"0x100\00local\004\000", !10, !6, !9, !19} ; [ DW_TAG_auto_variable ]
-!23 = !{i32 4, i32 16, !10, !19}
-!24 = !{i32 5, i32 3, !10, !19}
-!25 = !{i32 6, i32 3, !10, !19}
+!23 = !MDLocation(line: 4, column: 16, scope: !10, inlinedAt: !19)
+!24 = !MDLocation(line: 5, column: 3, scope: !10, inlinedAt: !19)
+!25 = !MDLocation(line: 6, column: 3, scope: !10, inlinedAt: !19)
!26 = !{!"inline-bug.cc", !"/tmp/dbginfo/pr13202"}
!27 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/lto-comp-dir.ll b/llvm/test/DebugInfo/lto-comp-dir.ll
index 459235ff3b6..a79cf3248cf 100644
--- a/llvm/test/DebugInfo/lto-comp-dir.ll
+++ b/llvm/test/DebugInfo/lto-comp-dir.ll
@@ -78,7 +78,7 @@ attributes #1 = { uwtable "less-precise-fpmad"="false" "no-frame-pointer-elim"="
!16 = !{i32 2, !"Dwarf Version", i32 4}
!17 = !{i32 1, !"Debug Info Version", i32 2}
!18 = !{!"clang version 3.5.0 "}
-!19 = !{i32 2, i32 0, !4, null}
-!20 = !{i32 3, i32 0, !11, null}
-!21 = !{i32 4, i32 0, !11, null}
+!19 = !MDLocation(line: 2, scope: !4)
+!20 = !MDLocation(line: 3, scope: !11)
+!21 = !MDLocation(line: 4, scope: !11)
diff --git a/llvm/test/DebugInfo/member-order.ll b/llvm/test/DebugInfo/member-order.ll
index 5ff59bb8f26..ae845719cdc 100644
--- a/llvm/test/DebugInfo/member-order.ll
+++ b/llvm/test/DebugInfo/member-order.ll
@@ -61,6 +61,6 @@ attributes #1 = { nounwind readnone }
!15 = !{i32 2, !"Dwarf Version", i32 4}
!16 = !{!"0x101\00this\0016777216\001088", !14, null, !17} ; [ DW_TAG_arg_variable ] [this] [line 0]
!17 = !{!"0xf\00\000\0064\0064\000\000", null, null, !"_ZTS3foo"} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from _ZTS3foo]
-!18 = !{i32 0, i32 0, !14, null}
-!19 = !{i32 7, i32 0, !14, null}
+!18 = !MDLocation(line: 0, scope: !14)
+!19 = !MDLocation(line: 7, scope: !14)
!20 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/missing-abstract-variable.ll b/llvm/test/DebugInfo/missing-abstract-variable.ll
index 3395c2ece44..dcaa2db435d 100644
--- a/llvm/test/DebugInfo/missing-abstract-variable.ll
+++ b/llvm/test/DebugInfo/missing-abstract-variable.ll
@@ -161,22 +161,22 @@ attributes #2 = { nounwind readnone }
!23 = !{!"clang version 3.5.0 "}
!24 = !{i1 false}
!25 = !{!"0x101\00b\0016777221\000", !14, !5, !11, !26} ; [ DW_TAG_arg_variable ] [b] [line 5]
-!26 = !{i32 14, i32 0, !4, null}
-!27 = !{i32 5, i32 0, !14, !26}
-!28 = !{i32 10, i32 0, !14, !26}
-!29 = !{i32 15, i32 0, !4, null}
-!30 = !{i32 17, i32 0, !8, null}
+!26 = !MDLocation(line: 14, scope: !4)
+!27 = !MDLocation(line: 5, scope: !14, inlinedAt: !26)
+!28 = !MDLocation(line: 10, scope: !14, inlinedAt: !26)
+!29 = !MDLocation(line: 15, scope: !4)
+!30 = !MDLocation(line: 17, scope: !8)
!31 = !{!"0x101\00b\0016777221\000", !14, !5, !11, !32} ; [ DW_TAG_arg_variable ] [b] [line 5]
-!32 = !{i32 18, i32 0, !8, null}
-!33 = !{i32 5, i32 0, !14, !32}
-!34 = !{i32 6, i32 0, !19, !32}
-!35 = !{i32 7, i32 0, !18, !32}
+!32 = !MDLocation(line: 18, scope: !8)
+!33 = !MDLocation(line: 5, scope: !14, inlinedAt: !32)
+!34 = !MDLocation(line: 6, scope: !19, inlinedAt: !32)
+!35 = !MDLocation(line: 7, scope: !18, inlinedAt: !32)
!36 = !{!37, !37, i64 0}
!37 = !{!"int", !38, i64 0}
!38 = !{!"omnipotent char", !39, i64 0}
!39 = !{!"Simple C/C++ TBAA"}
!40 = !{!"0x100\00s\007\000", !18, !5, !20, !32} ; [ DW_TAG_auto_variable ] [s] [line 7]
-!41 = !{i32 8, i32 0, !18, !32}
-!42 = !{i32 9, i32 0, !18, !32}
-!43 = !{i32 10, i32 0, !14, !32}
-!44 = !{i32 19, i32 0, !8, null}
+!41 = !MDLocation(line: 8, scope: !18, inlinedAt: !32)
+!42 = !MDLocation(line: 9, scope: !18, inlinedAt: !32)
+!43 = !MDLocation(line: 10, scope: !14, inlinedAt: !32)
+!44 = !MDLocation(line: 19, scope: !8)
diff --git a/llvm/test/DebugInfo/multiline.ll b/llvm/test/DebugInfo/multiline.ll
index bc365cc823d..e67af328416 100644
--- a/llvm/test/DebugInfo/multiline.ll
+++ b/llvm/test/DebugInfo/multiline.ll
@@ -73,10 +73,10 @@ attributes #1 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n
!8 = !{i32 2, !"Dwarf Version", i32 4}
!9 = !{i32 2, !"Debug Info Version", i32 2}
!10 = !{!"clang version 3.6.0 (trunk 225000) (llvm/trunk 224999)"}
-!11 = !{i32 3, i32 3, !4, null}
-!12 = !{i32 3, i32 9, !4, null}
-!13 = !{i32 3, i32 15, !4, null}
-!14 = !{i32 4, i32 3, !4, null}
-!15 = !{i32 4, i32 9, !4, null}
-!16 = !{i32 4, i32 15, !4, null}
-!17 = !{i32 5, i32 1, !4, null}
+!11 = !MDLocation(line: 3, column: 3, scope: !4)
+!12 = !MDLocation(line: 3, column: 9, scope: !4)
+!13 = !MDLocation(line: 3, column: 15, scope: !4)
+!14 = !MDLocation(line: 4, column: 3, scope: !4)
+!15 = !MDLocation(line: 4, column: 9, scope: !4)
+!16 = !MDLocation(line: 4, column: 15, scope: !4)
+!17 = !MDLocation(line: 5, column: 1, scope: !4)
diff --git a/llvm/test/DebugInfo/namespace.ll b/llvm/test/DebugInfo/namespace.ll
index 7c98b8a9115..a4fdbd27a89 100644
--- a/llvm/test/DebugInfo/namespace.ll
+++ b/llvm/test/DebugInfo/namespace.ll
@@ -348,19 +348,19 @@ attributes #1 = { nounwind readnone }
!57 = !{i32 2, !"Dwarf Version", i32 2}
!58 = !{i32 2, !"Debug Info Version", i32 2}
!59 = !{!"clang version 3.6.0 "}
-!60 = !{i32 3, i32 12, !10, null}
+!60 = !MDLocation(line: 3, column: 12, scope: !10)
!61 = !{!"0x101\00\0016777220\000", !14, !18, !13} ; [ DW_TAG_arg_variable ] [line 4]
!62 = !{!"0x102"} ; [ DW_TAG_expression ]
-!63 = !{i32 4, i32 12, !14, null}
-!64 = !{i32 4, i32 16, !14, null}
-!65 = !{i32 20, i32 12, !17, null}
+!63 = !MDLocation(line: 4, column: 12, scope: !14)
+!64 = !MDLocation(line: 4, column: 16, scope: !14)
+!65 = !MDLocation(line: 20, column: 12, scope: !17)
!66 = !{!"0x101\00b\0016777237\000", !21, !18, !24} ; [ DW_TAG_arg_variable ] [b] [line 21]
-!67 = !{i32 21, i32 15, !21, null}
-!68 = !{i32 22, i32 7, !21, null}
-!69 = !{i32 24, i32 5, !38, null}
-!70 = !{i32 38, i32 3, !21, null}
-!71 = !{i32 39, i32 1, !21, null}
-!72 = !{i32 44, i32 15, !25, null}
-!73 = !{i32 47, i32 21, !26, null}
-!74 = !{i32 0, i32 0, !75, null}
+!67 = !MDLocation(line: 21, column: 15, scope: !21)
+!68 = !MDLocation(line: 22, column: 7, scope: !21)
+!69 = !MDLocation(line: 24, column: 5, scope: !38)
+!70 = !MDLocation(line: 38, column: 3, scope: !21)
+!71 = !MDLocation(line: 39, column: 1, scope: !21)
+!72 = !MDLocation(line: 44, column: 15, scope: !25)
+!73 = !MDLocation(line: 47, column: 21, scope: !26)
+!74 = !MDLocation(line: 0, scope: !75)
!75 = !{!"0xb\000", !5, !27} ; [ DW_TAG_lexical_block ] [/tmp/foo.cpp]
diff --git a/llvm/test/DebugInfo/namespace_function_definition.ll b/llvm/test/DebugInfo/namespace_function_definition.ll
index bde4a1a0c06..02c55bf094a 100644
--- a/llvm/test/DebugInfo/namespace_function_definition.ll
+++ b/llvm/test/DebugInfo/namespace_function_definition.ll
@@ -41,4 +41,4 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe
!8 = !{i32 2, !"Dwarf Version", i32 4}
!9 = !{i32 1, !"Debug Info Version", i32 2}
!10 = !{!"clang version 3.5.0 "}
-!11 = !{i32 3, i32 0, !4, null}
+!11 = !MDLocation(line: 3, scope: !4)
diff --git a/llvm/test/DebugInfo/namespace_inline_function_definition.ll b/llvm/test/DebugInfo/namespace_inline_function_definition.ll
index 55e09220fd7..b6f1b5ff2c0 100644
--- a/llvm/test/DebugInfo/namespace_inline_function_definition.ll
+++ b/llvm/test/DebugInfo/namespace_inline_function_definition.ll
@@ -86,7 +86,7 @@ attributes #2 = { nounwind readnone }
!13 = !{i32 2, !"Dwarf Version", i32 4}
!14 = !{i32 2, !"Debug Info Version", i32 2}
!15 = !{!"clang version 3.5.0 "}
-!16 = !{i32 5, i32 0, !4, null}
+!16 = !MDLocation(line: 5, scope: !4)
!17 = !{!"0x101\00i\0016777222\000", !9, !5, !8} ; [ DW_TAG_arg_variable ] [i] [line 6]
-!18 = !{i32 6, i32 0, !9, !16}
-!19 = !{i32 6, i32 0, !9, null}
+!18 = !MDLocation(line: 6, scope: !9, inlinedAt: !16)
+!19 = !MDLocation(line: 6, scope: !9)
diff --git a/llvm/test/DebugInfo/nodebug.ll b/llvm/test/DebugInfo/nodebug.ll
index efb79336aa6..83ce2625603 100644
--- a/llvm/test/DebugInfo/nodebug.ll
+++ b/llvm/test/DebugInfo/nodebug.ll
@@ -48,4 +48,4 @@ attributes #0 = { uwtable "less-precise-fpmad"="false" "no-frame-pointer-elim"="
!8 = !{i32 2, !"Dwarf Version", i32 4}
!9 = !{i32 2, !"Debug Info Version", i32 2}
!10 = !{!"clang version 3.5.0 "}
-!11 = !{i32 3, i32 0, !4, null}
+!11 = !MDLocation(line: 3, scope: !4)
diff --git a/llvm/test/DebugInfo/restrict.ll b/llvm/test/DebugInfo/restrict.ll
index 52c89eac76f..54bdec7affa 100644
--- a/llvm/test/DebugInfo/restrict.ll
+++ b/llvm/test/DebugInfo/restrict.ll
@@ -49,5 +49,5 @@ attributes #1 = { nounwind readnone }
!11 = !{i32 1, !"Debug Info Version", i32 2}
!12 = !{!"clang version 3.5.0 "}
!13 = !{!"0x101\00dst\0016777217\000", !4, !5, !8} ; [ DW_TAG_arg_variable ] [dst] [line 1]
-!14 = !{i32 1, i32 0, !4, null}
-!15 = !{i32 2, i32 0, !4, null}
+!14 = !MDLocation(line: 1, scope: !4)
+!15 = !MDLocation(line: 2, scope: !4)
diff --git a/llvm/test/DebugInfo/sugared-constants.ll b/llvm/test/DebugInfo/sugared-constants.ll
index ebe165b066c..9e4f374e9fa 100644
--- a/llvm/test/DebugInfo/sugared-constants.ll
+++ b/llvm/test/DebugInfo/sugared-constants.ll
@@ -71,12 +71,12 @@ attributes #2 = { nounwind readnone }
!18 = !{i32 1, !"Debug Info Version", i32 2}
!19 = !{!"clang version 3.5.0 "}
!20 = !{i32 42}
-!21 = !{i32 5, i32 0, !4, null}
-!22 = !{i32 6, i32 0, !4, null}
+!21 = !MDLocation(line: 5, scope: !4)
+!22 = !MDLocation(line: 6, scope: !4)
!23 = !{i32 117}
-!24 = !{i32 7, i32 0, !4, null}
-!25 = !{i32 8, i32 0, !4, null}
+!24 = !MDLocation(line: 7, scope: !4)
+!25 = !MDLocation(line: 8, scope: !4)
!26 = !{i16 7}
-!27 = !{i32 9, i32 0, !4, null}
-!28 = !{i32 10, i32 0, !4, null}
-!29 = !{i32 11, i32 0, !4, null}
+!27 = !MDLocation(line: 9, scope: !4)
+!28 = !MDLocation(line: 10, scope: !4)
+!29 = !MDLocation(line: 11, scope: !4)
diff --git a/llvm/test/DebugInfo/tu-composite.ll b/llvm/test/DebugInfo/tu-composite.ll
index bc55275fa99..6f052ee2a82 100644
--- a/llvm/test/DebugInfo/tu-composite.ll
+++ b/llvm/test/DebugInfo/tu-composite.ll
@@ -161,25 +161,25 @@ attributes #1 = { nounwind readnone }
!35 = !{i32 2, !"Dwarf Version", i32 2}
!36 = !{!"0x101\00this\0016777216\001088", !31, null, !37} ; [ DW_TAG_arg_variable ] [this] [line 0]
!37 = !{!"0xf\00\000\0064\0064\000\000", null, null, !"_ZTS1C"} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from _ZTS1C]
-!38 = !{i32 0, i32 0, !31, null}
-!39 = !{i32 5, i32 0, !31, null}
+!38 = !MDLocation(line: 0, scope: !31)
+!39 = !MDLocation(line: 5, scope: !31)
!40 = !{!"0x100\00B\0021\000", !32, !7, !41} ; [ DW_TAG_auto_variable ] [B] [line 21]
!41 = !{!"0x16\00baz\008\000\000\000\000", !1, null, !"_ZTS3bar"} ; [ DW_TAG_typedef ] [baz] [line 8, size 0, align 0, offset 0] [from _ZTS3bar]
-!42 = !{i32 21, i32 0, !32, null}
+!42 = !MDLocation(line: 21, scope: !32)
!43 = !{!"0x100\00A\0022\000", !32, !7, !44} ; [ DW_TAG_auto_variable ] [A] [line 22]
!44 = !{!"0x1\00\000\0024\008\000\000", null, null, !"_ZTS3bar", !45, i32 0, null, null, null} ; [ DW_TAG_array_type ] [line 0, size 24, align 8, offset 0] [from _ZTS3bar]
!45 = !{!46}
!46 = !{!"0x21\000\003"} ; [ DW_TAG_subrange_type ] [0, 2]
-!47 = !{i32 22, i32 0, !32, null}
+!47 = !MDLocation(line: 22, scope: !32)
!48 = !{!"0x100\00B2\0023\000", !32, !7, !49} ; [ DW_TAG_auto_variable ] [B2] [line 23]
!49 = !{!"0x16\00baz2\0010\000\000\000\000", !1, !"_ZTS1D", !"_ZTS3bar"} ; [ DW_TAG_typedef ] [baz2] [line 10, size 0, align 0, offset 0] [from _ZTS3bar]
-!50 = !{i32 23, i32 0, !32, null}
+!50 = !MDLocation(line: 23, scope: !32)
!51 = !{!"0x100\00e\0024\000", !32, !7, !22} ; [ DW_TAG_auto_variable ] [e] [line 24]
-!52 = !{i32 24, i32 0, !32, null}
+!52 = !MDLocation(line: 24, scope: !32)
!53 = !{!"0x100\00p\0025\000", !32, !7, !54} ; [ DW_TAG_auto_variable ] [p] [line 25]
!54 = !{!"0xf\00\000\0064\0064\000\000", null, null, !"_ZTSN1D7Nested2E"} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from _ZTSN1D7Nested2E]
-!55 = !{i32 25, i32 0, !32, null}
+!55 = !MDLocation(line: 25, scope: !32)
!56 = !{!"0x100\00t\0026\000", !32, !7, !24} ; [ DW_TAG_auto_variable ] [t] [line 26]
-!57 = !{i32 26, i32 0, !32, null}
-!58 = !{i32 27, i32 0, !32, null}
+!57 = !MDLocation(line: 26, scope: !32)
+!58 = !MDLocation(line: 27, scope: !32)
!59 = !{i32 1, !"Debug Info Version", i32 2}
diff --git a/llvm/test/DebugInfo/two-cus-from-same-file.ll b/llvm/test/DebugInfo/two-cus-from-same-file.ll
index 796e5c877e3..b810a914960 100644
--- a/llvm/test/DebugInfo/two-cus-from-same-file.ll
+++ b/llvm/test/DebugInfo/two-cus-from-same-file.ll
@@ -54,15 +54,15 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon
!19 = !{!21, !22}
!21 = !{!"0x101\00argc\0016777227\000", !12, !6, !15} ; [ DW_TAG_arg_variable ]
!22 = !{!"0x101\00argv\0033554443\000", !12, !6, !16} ; [ DW_TAG_arg_variable ]
-!23 = !{i32 6, i32 3, !24, null}
+!23 = !MDLocation(line: 6, column: 3, scope: !24)
!24 = !{!"0xb\005\0016\000", !32, !5} ; [ DW_TAG_lexical_block ]
-!25 = !{i32 7, i32 1, !24, null}
-!26 = !{i32 11, i32 14, !12, null}
-!27 = !{i32 11, i32 26, !12, null}
-!28 = !{i32 12, i32 3, !29, null}
+!25 = !MDLocation(line: 7, column: 1, scope: !24)
+!26 = !MDLocation(line: 11, column: 14, scope: !12)
+!27 = !MDLocation(line: 11, column: 26, scope: !12)
+!28 = !MDLocation(line: 12, column: 3, scope: !29)
!29 = !{!"0xb\0011\0034\000", !32, !12} ; [ DW_TAG_lexical_block ]
-!30 = !{i32 13, i32 3, !29, null}
-!31 = !{i32 14, i32 3, !29, null}
+!30 = !MDLocation(line: 13, column: 3, scope: !29)
+!31 = !MDLocation(line: 14, column: 3, scope: !29)
!32 = !{!"foo.c", !"/tmp"}
; This test is simple to be cross platform (many targets don't yet have
diff --git a/llvm/test/DebugInfo/unconditional-branch.ll b/llvm/test/DebugInfo/unconditional-branch.ll
index ba88a343347..c82f1bab10b 100644
--- a/llvm/test/DebugInfo/unconditional-branch.ll
+++ b/llvm/test/DebugInfo/unconditional-branch.ll
@@ -58,8 +58,8 @@ attributes #1 = { nounwind readnone }
!10 = !{i32 1, !"Debug Info Version", i32 2}
!11 = !{!"clang version 3.5.0 (204712)"}
!12 = !{!"0x101\00i\0016777217\000", !4, !5, !8} ; [ DW_TAG_arg_variable ] [i] [line 1]
-!13 = !{i32 1, i32 0, !4, null}
-!14 = !{i32 2, i32 0, !4, null}
-!15 = !{i32 4, i32 0, !16, null}
+!13 = !MDLocation(line: 1, scope: !4)
+!14 = !MDLocation(line: 2, scope: !4)
+!15 = !MDLocation(line: 4, scope: !16)
!16 = !{!"0xb\002\000\000", !1, !4} ; [ DW_TAG_lexical_block ] [D:\work\EPRs\396363/test.c]
-!17 = !{i32 6, i32 0, !4, null}
+!17 = !MDLocation(line: 6, scope: !4)
diff --git a/llvm/test/DebugInfo/varargs.ll b/llvm/test/DebugInfo/varargs.ll
index 523a20feb6c..907d2e309a5 100644
--- a/llvm/test/DebugInfo/varargs.ll
+++ b/llvm/test/DebugInfo/varargs.ll
@@ -93,10 +93,10 @@ attributes #1 = { nounwind readnone }
!19 = !{i32 1, !"Debug Info Version", i32 2}
!20 = !{!"clang version 3.5 "}
!21 = !{!"0x101\00c\0016777229\000", !14, !15, !10} ; [ DW_TAG_arg_variable ] [c] [line 13]
-!22 = !{i32 13, i32 0, !14, null}
+!22 = !MDLocation(line: 13, scope: !14)
!23 = !{!"0x100\00a\0016\000", !14, !15, !4} ; [ DW_TAG_auto_variable ] [a] [line 16]
-!24 = !{i32 16, i32 0, !14, null}
+!24 = !MDLocation(line: 16, scope: !14)
!25 = !{!"0x100\00fptr\0018\000", !14, !15, !26} ; [ DW_TAG_auto_variable ] [fptr] [line 18]
!26 = !{!"0xf\00\000\0064\0064\000\000", null, null, !16} ; [ DW_TAG_pointer_type ] [line 0, size 64, align 64, offset 0] [from ]
-!27 = !{i32 18, i32 0, !14, null}
-!28 = !{i32 22, i32 0, !14, null}
+!27 = !MDLocation(line: 18, scope: !14)
+!28 = !MDLocation(line: 22, scope: !14)
diff --git a/llvm/test/DebugInfo/version.ll b/llvm/test/DebugInfo/version.ll
index e6798d7f35a..6ee33b6a940 100644
--- a/llvm/test/DebugInfo/version.ll
+++ b/llvm/test/DebugInfo/version.ll
@@ -28,5 +28,5 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe
!7 = !{!8}
!8 = !{!"0x24\00int\000\0032\0032\000\000\005", null, null} ; [ DW_TAG_base_type ] [int] [line 0, size 32, align 32, offset 0, enc DW_ATE_signed]
!9 = !{i32 2, !"Dwarf Version", i32 3}
-!10 = !{i32 7, i32 0, !4, null}
+!10 = !MDLocation(line: 7, scope: !4)
!11 = !{i32 1, !"Debug Info Version", i32 2}
OpenPOWER on IntegriCloud