From 9a1e0e252a7ede548acaac98cf304d4bb135fb97 Mon Sep 17 00:00:00 2001 From: Eric Christopher Date: Tue, 8 Jan 2013 01:53:52 +0000 Subject: Remove the llvm-local DW_TAG_vector_type tag and add a test to make sure that vector types do work. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171833 91177308-0d34-0410-b5e6-96231b3b80d8 --- test/DebugInfo/X86/vector.ll | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 test/DebugInfo/X86/vector.ll (limited to 'test/DebugInfo/X86/vector.ll') diff --git a/test/DebugInfo/X86/vector.ll b/test/DebugInfo/X86/vector.ll new file mode 100644 index 0000000000..5f46406ed1 --- /dev/null +++ b/test/DebugInfo/X86/vector.ll @@ -0,0 +1,23 @@ +; RUN: llc -mtriple=x86_64-linux-gnu -O0 -filetype=obj -o %t %s +; RUN: llvm-dwarfdump %t | FileCheck %s + +@a = common global <4 x i32> zeroinitializer, align 16 + +!llvm.dbg.cu = !{!0} + +!0 = metadata !{i32 786449, i32 0, i32 12, metadata !"foo.c", metadata !"/Users/echristo", metadata !"clang version 3.3 (trunk 171825) (llvm/trunk 171822)", i1 true, i1 false, metadata !"", i32 0, metadata !1, metadata !1, metadata !1, metadata !3} ; [ DW_TAG_compile_unit ] [/Users/echristo/foo.c] [DW_LANG_C99] +!1 = metadata !{metadata !2} +!2 = metadata !{i32 0} +!3 = metadata !{metadata !4} +!4 = metadata !{metadata !5} +!5 = metadata !{i32 786484, i32 0, null, metadata !"a", metadata !"a", metadata !"", metadata !6, i32 3, metadata !7, i32 0, i32 1, <4 x i32>* @a} ; [ DW_TAG_variable ] [a] [line 3] [def] +!6 = metadata !{i32 786473, metadata !"foo.c", metadata !"/Users/echristo", null} ; [ DW_TAG_file_type ] +!7 = metadata !{i32 786454, null, metadata !"v4si", metadata !6, i32 1, i64 0, i64 0, i64 0, i32 0, metadata !8} ; [ DW_TAG_typedef ] [v4si] [line 1, size 0, align 0, offset 0] [from ] +!8 = metadata !{i32 786433, null, metadata !"", null, i32 0, i64 128, i64 128, i32 0, i32 2048, metadata !9, metadata !10, i32 0, i32 0} ; [ DW_TAG_array_type ] [line 0, size 128, align 128, offset 0] [vector] [from int] +!9 = metadata !{i32 786468, null, metadata !"int", null, i32 0, i64 32, i64 32, i64 0, i32 0, i32 5} ; [ DW_TAG_base_type ] [int] [line 0, size 32, align 32, offset 0, enc DW_ATE_signed] +!10 = metadata !{metadata !11} +!11 = metadata !{i32 786465, i64 0, i64 4} ; [ DW_TAG_subrange_type ] [0, 3] + +; Check that we get an array type with a vector attribute. +; CHECK: DW_TAG_array_type +; CHECK-NEXT: DW_AT_GNU_vector -- cgit v1.2.3-18-g5258 From ef24963cbcb068a5796073354fde7b9d25fd17d0 Mon Sep 17 00:00:00 2001 From: Eric Christopher Date: Tue, 8 Jan 2013 03:03:14 +0000 Subject: Add the C testcase to this file. Suggested by Dave Blaikie. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171839 91177308-0d34-0410-b5e6-96231b3b80d8 --- test/DebugInfo/X86/vector.ll | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'test/DebugInfo/X86/vector.ll') diff --git a/test/DebugInfo/X86/vector.ll b/test/DebugInfo/X86/vector.ll index 5f46406ed1..7b61e76f18 100644 --- a/test/DebugInfo/X86/vector.ll +++ b/test/DebugInfo/X86/vector.ll @@ -1,6 +1,12 @@ ; RUN: llc -mtriple=x86_64-linux-gnu -O0 -filetype=obj -o %t %s ; RUN: llvm-dwarfdump %t | FileCheck %s +; Generated from: +; clang -g -S -emit-llvm -o foo.ll foo.c +; typedef int v4si __attribute__((__vector_size__(16))); +; +; v4si a + @a = common global <4 x i32> zeroinitializer, align 16 !llvm.dbg.cu = !{!0} -- cgit v1.2.3-18-g5258 From 767295f1143db4ed844ea9d25f9758e624c35302 Mon Sep 17 00:00:00 2001 From: Eli Bendersky Date: Fri, 25 Jan 2013 21:44:53 +0000 Subject: Now that llvm-dwarfdump supports flags to specify which DWARF section to dump, use them in tests that run llvm-dwarfdump. This is in order to make tests as specific as possible. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173498 91177308-0d34-0410-b5e6-96231b3b80d8 --- test/DebugInfo/X86/vector.ll | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'test/DebugInfo/X86/vector.ll') diff --git a/test/DebugInfo/X86/vector.ll b/test/DebugInfo/X86/vector.ll index 7b61e76f18..6fe2ef132f 100644 --- a/test/DebugInfo/X86/vector.ll +++ b/test/DebugInfo/X86/vector.ll @@ -1,5 +1,5 @@ ; RUN: llc -mtriple=x86_64-linux-gnu -O0 -filetype=obj -o %t %s -; RUN: llvm-dwarfdump %t | FileCheck %s +; RUN: llvm-dwarfdump -debug-dump=info %t | FileCheck %s ; Generated from: ; clang -g -S -emit-llvm -o foo.ll foo.c -- cgit v1.2.3-18-g5258 From a8eefc7cc7c6e8be06d570fff76dc42b43a23392 Mon Sep 17 00:00:00 2001 From: David Blaikie Date: Sat, 2 Feb 2013 05:56:24 +0000 Subject: Remove the (apparently) unnecessary debug info metadata indirection. The main lists of debug info metadata attached to the compile_unit had an extra layer of metadata nodes they went through for no apparent reason. This patch removes that (& still passes just as much of the GDB 7.5 test suite). If anyone can show evidence as to why these extra metadata nodes are there I'm open to reverting this patch & documenting why they're there. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174266 91177308-0d34-0410-b5e6-96231b3b80d8 --- test/DebugInfo/X86/vector.ll | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'test/DebugInfo/X86/vector.ll') diff --git a/test/DebugInfo/X86/vector.ll b/test/DebugInfo/X86/vector.ll index 6fe2ef132f..0ff99ccbd9 100644 --- a/test/DebugInfo/X86/vector.ll +++ b/test/DebugInfo/X86/vector.ll @@ -12,10 +12,8 @@ !llvm.dbg.cu = !{!0} !0 = metadata !{i32 786449, i32 0, i32 12, metadata !"foo.c", metadata !"/Users/echristo", metadata !"clang version 3.3 (trunk 171825) (llvm/trunk 171822)", i1 true, i1 false, metadata !"", i32 0, metadata !1, metadata !1, metadata !1, metadata !3} ; [ DW_TAG_compile_unit ] [/Users/echristo/foo.c] [DW_LANG_C99] -!1 = metadata !{metadata !2} -!2 = metadata !{i32 0} -!3 = metadata !{metadata !4} -!4 = metadata !{metadata !5} +!1 = metadata !{i32 0} +!3 = metadata !{metadata !5} !5 = metadata !{i32 786484, i32 0, null, metadata !"a", metadata !"a", metadata !"", metadata !6, i32 3, metadata !7, i32 0, i32 1, <4 x i32>* @a} ; [ DW_TAG_variable ] [a] [line 3] [def] !6 = metadata !{i32 786473, metadata !"foo.c", metadata !"/Users/echristo", null} ; [ DW_TAG_file_type ] !7 = metadata !{i32 786454, null, metadata !"v4si", metadata !6, i32 1, i64 0, i64 0, i64 0, i32 0, metadata !8} ; [ DW_TAG_typedef ] [v4si] [line 1, size 0, align 0, offset 0] [from ] -- cgit v1.2.3-18-g5258 From 850b74d3927c35850a99b10ca7809f61a3b69c67 Mon Sep 17 00:00:00 2001 From: David Blaikie Date: Mon, 11 Mar 2013 22:37:40 +0000 Subject: Upgrading debug info test cases to be (more) compatible with the current debug info format. These cases were found by further work to remove support for debug info versioning. Common cleanups (other than changing the version info in the tag field) included adding the last parameter to compile_units (recently added for fission support) and other cases of trailing fields in lexical blocks, compile units, and subprograms. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@176834 91177308-0d34-0410-b5e6-96231b3b80d8 --- test/DebugInfo/X86/vector.ll | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'test/DebugInfo/X86/vector.ll') diff --git a/test/DebugInfo/X86/vector.ll b/test/DebugInfo/X86/vector.ll index 0ff99ccbd9..c5ca705ec7 100644 --- a/test/DebugInfo/X86/vector.ll +++ b/test/DebugInfo/X86/vector.ll @@ -14,7 +14,7 @@ !0 = metadata !{i32 786449, i32 0, i32 12, metadata !"foo.c", metadata !"/Users/echristo", metadata !"clang version 3.3 (trunk 171825) (llvm/trunk 171822)", i1 true, i1 false, metadata !"", i32 0, metadata !1, metadata !1, metadata !1, metadata !3} ; [ DW_TAG_compile_unit ] [/Users/echristo/foo.c] [DW_LANG_C99] !1 = metadata !{i32 0} !3 = metadata !{metadata !5} -!5 = metadata !{i32 786484, i32 0, null, metadata !"a", metadata !"a", metadata !"", metadata !6, i32 3, metadata !7, i32 0, i32 1, <4 x i32>* @a} ; [ DW_TAG_variable ] [a] [line 3] [def] +!5 = metadata !{i32 786484, i32 0, null, metadata !"a", metadata !"a", metadata !"", metadata !6, i32 3, metadata !7, i32 0, i32 1, <4 x i32>* @a, null} ; [ DW_TAG_variable ] [a] [line 3] [def] !6 = metadata !{i32 786473, metadata !"foo.c", metadata !"/Users/echristo", null} ; [ DW_TAG_file_type ] !7 = metadata !{i32 786454, null, metadata !"v4si", metadata !6, i32 1, i64 0, i64 0, i64 0, i32 0, metadata !8} ; [ DW_TAG_typedef ] [v4si] [line 1, size 0, align 0, offset 0] [from ] !8 = metadata !{i32 786433, null, metadata !"", null, i32 0, i64 128, i64 128, i32 0, i32 2048, metadata !9, metadata !10, i32 0, i32 0} ; [ DW_TAG_array_type ] [line 0, size 128, align 128, offset 0] [vector] [from int] -- cgit v1.2.3-18-g5258