summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2017-06-30 20:56:57 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2017-06-30 20:56:57 +0000
commit638ba5afb5d78eccf8ce249293d2cb1559c1a351 (patch)
tree531f87cb71916a2f09906d8f49eaa40570ea6c33 /test
parente33b6de6d6d284e238ad9a1a53ac24703c0baa2b (diff)
Fix ODR violations due to abuse of LLVM_YAML_IS_(FLOW_)?SEQUENCE_VECTOR
This is a short-term fix for PR33650 aimed to get the modules build bots green again. Remove all the places where we use the LLVM_YAML_IS_(FLOW_)?SEQUENCE_VECTOR macros to try to locally specialize a global template for a global type. That's not how C++ works. Instead, we now centrally define how to format vectors of fundamental types and of string (std::string and StringRef). We use flow formatting for the former cases, since that's the obvious right thing to do; in the latter case, it's less clear what the right choice is, but flow formatting is really bad for some cases (due to very long strings), so we pick block formatting. (Many of the cases that were using flow formatting for strings are improved by this change.) Other than the flow -> block formatting change for some vectors of strings, this should result in no functionality change. Differential Revision: https://reviews.llvm.org/D34907 Corresponding updates to clang, clang-tools-extra, and lld to follow. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@306878 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r--test/CodeGen/AMDGPU/code-object-metadata-from-llvm-ir-full.ll10
-rw-r--r--test/MC/AMDGPU/code-object-metadata-kernel-args.s4
-rw-r--r--test/MC/AMDGPU/code-object-metadata-kernel-attrs.s4
-rw-r--r--test/Transforms/LowerTypeTests/export-icall.ll9
4 files changed, 19 insertions, 8 deletions
diff --git a/test/CodeGen/AMDGPU/code-object-metadata-from-llvm-ir-full.ll b/test/CodeGen/AMDGPU/code-object-metadata-from-llvm-ir-full.ll
index a68ddabd956..37fd08242fb 100644
--- a/test/CodeGen/AMDGPU/code-object-metadata-from-llvm-ir-full.ll
+++ b/test/CodeGen/AMDGPU/code-object-metadata-from-llvm-ir-full.ll
@@ -16,7 +16,9 @@
; CHECK: ---
; CHECK: Version: [ 1, 0 ]
-; CHECK: Printf: [ '1:1:4:%d\n', '2:1:8:%g\n' ]
+; CHECK: Printf:
+; CHECK: - '1:1:4:%d\n'
+; CHECK: - '2:1:8:%g\n'
; CHECK: Kernels:
; CHECK: - Name: test_char
@@ -1253,8 +1255,8 @@ define amdgpu_kernel void @test_pointee_align(i64 addrspace(1)* %a,
; NOTES-NEXT: Owner Data size Description
; NOTES-NEXT: AMD 0x00000008 Unknown note type: (0x00000001)
; NOTES-NEXT: AMD 0x0000001b Unknown note type: (0x00000003)
-; GFX700: AMD 0x00008b06 Unknown note type: (0x0000000a)
-; GFX800: AMD 0x00008e6a Unknown note type: (0x0000000a)
-; GFX900: AMD 0x00008b06 Unknown note type: (0x0000000a)
+; GFX700: AMD 0x00008b0a Unknown note type: (0x0000000a)
+; GFX800: AMD 0x00008e6e Unknown note type: (0x0000000a)
+; GFX900: AMD 0x00008b0a Unknown note type: (0x0000000a)
; PARSER: AMDGPU Code Object Metadata Parser Test: PASS
diff --git a/test/MC/AMDGPU/code-object-metadata-kernel-args.s b/test/MC/AMDGPU/code-object-metadata-kernel-args.s
index 90915e61f99..46cf4f506a5 100644
--- a/test/MC/AMDGPU/code-object-metadata-kernel-args.s
+++ b/test/MC/AMDGPU/code-object-metadata-kernel-args.s
@@ -4,7 +4,9 @@
// CHECK: .amdgpu_code_object_metadata
// CHECK: Version: [ 1, 0 ]
-// CHECK: Printf: [ '1:1:4:%d\n', '2:1:8:%g\n' ]
+// CHECK: Printf:
+// CHECK: - '1:1:4:%d\n'
+// CHECK: - '2:1:8:%g\n'
// CHECK: Kernels:
// CHECK: - Name: test_kernel
// CHECK: Language: OpenCL C
diff --git a/test/MC/AMDGPU/code-object-metadata-kernel-attrs.s b/test/MC/AMDGPU/code-object-metadata-kernel-attrs.s
index 9669fcf5393..7884b6672e7 100644
--- a/test/MC/AMDGPU/code-object-metadata-kernel-attrs.s
+++ b/test/MC/AMDGPU/code-object-metadata-kernel-attrs.s
@@ -4,7 +4,9 @@
// CHECK: .amdgpu_code_object_metadata
// CHECK: Version: [ 1, 0 ]
-// CHECK: Printf: [ '1:1:4:%d\n', '2:1:8:%g\n' ]
+// CHECK: Printf:
+// CHECK: - '1:1:4:%d\n'
+// CHECK: - '2:1:8:%g\n'
// CHECK: Kernels:
// CHECK: - Name: test_kernel
// CHECK: Language: OpenCL C
diff --git a/test/Transforms/LowerTypeTests/export-icall.ll b/test/Transforms/LowerTypeTests/export-icall.ll
index f53b63af496..ad360489930 100644
--- a/test/Transforms/LowerTypeTests/export-icall.ll
+++ b/test/Transforms/LowerTypeTests/export-icall.ll
@@ -60,6 +60,11 @@ declare !type !8 void @f(i32 %x)
; SUMMARY-NEXT: SizeM1BitWidth: 0
; SUMMARY-NEXT: WPDRes:
-; SUMMARY: CfiFunctionDefs: [ f, g, h ]
-; SUMMARY-NEXT: CfiFunctionDecls: [ external, external_weak ]
+; SUMMARY: CfiFunctionDefs:
+; SUMMARY-NEXT: - f
+; SUMMARY-NEXT: - g
+; SUMMARY-NEXT: - h
+; SUMMARY-NEXT: CfiFunctionDecls:
+; SUMMARY-NEXT: - external
+; SUMMARY-NEXT: - external_weak
; SUMMARY-NEXT: ...