Skip to content

Commit 9d7f00c

Browse files
author
Kevin Frei
committed
Added checking for aggregate counts for a dwarfdump test
1 parent 9fe63e3 commit 9d7f00c

File tree

2 files changed

+12
-3
lines changed

2 files changed

+12
-3
lines changed

llvm/test/tools/llvm-dwarfdump/X86/verify_file_encoding.yaml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# RUN: yaml2obj %s | not llvm-dwarfdump --no-aggregate-errors --verify - | FileCheck %s --implicit-check-not=error:
1+
# RUN: yaml2obj %s | not llvm-dwarfdump --verify - | FileCheck %s --implicit-check-not=error:
22

33
# CHECK: error: DIE has DW_AT_decl_file with invalid encoding{{[[:space:]]}}
44
# CHECK-NEXT: 0x0000001a: DW_TAG_subprogram
@@ -50,7 +50,11 @@
5050
# CHECK-NEXT: DW_AT_decl_line [DW_FORM_sdata] (3)
5151
# CHECK-NEXT: DW_AT_call_file [DW_FORM_sdata] (4)
5252
# CHECK-NEXT: DW_AT_call_line [DW_FORM_sdata] (5){{[[:space:]]}}
53-
53+
# CHECK-NEXT: Verifying dwo Units...
54+
# CHECK-NEXT: error: Aggregated error category counts:
55+
# CHECK-NEXT: error: Error category 'Invalid encoding in DW_AT_decl_file' occurred 4 time(s).
56+
# CHECK-NEXT: error: Error category 'Invalid file index in DW_AT_call_line' occurred 1 time(s).
57+
# CHECK-NEXT: error: Error category 'Invalid file index in DW_AT_decl_line' occurred 1 time(s).
5458
--- !ELF
5559
FileHeader:
5660
Class: ELFCLASS64

llvm/test/tools/llvm-dwarfdump/X86/verify_split_cu.s

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# RUN: llvm-mc %s -filetype obj -triple x86_64-linux-gnu -o - \
2-
# RUN: | not llvm-dwarfdump --no-aggregate-errors -v -verify - 2>&1 \
2+
# RUN: | not llvm-dwarfdump -v -verify - 2>&1 \
33
# RUN: | FileCheck %s --implicit-check-not=error --implicit-check-not=warning
44

55
# CHECK: Verifying dwo Units...
@@ -8,6 +8,11 @@
88
# CHECK: error: Unsupported DW_AT_location encoding: DW_FORM_data1
99
# FIXME: This should read "type unit" or just "unit" to be correct for this case/in general
1010
# CHECK: error: DIE has DW_AT_decl_file that references a file with index 1 and the compile unit has no line table
11+
# CHECK: error: Aggregated error category counts:
12+
# CHECK: error: Error category 'Compilation unit root DIE is not a unit DIE' occurred 1 time(s).
13+
# CHECK: error: Error category 'File index in DW_AT_decl_file reference CU with no line table' occurred 1 time(s).
14+
# CHECK: error: Error category 'Invalid DW_AT_location' occurred 1 time(s).
15+
# CHECK: error: Error category 'Mismatched unit type' occurred 1 time(s).
1116
# CHECK: Errors detected
1217
.section .debug_info.dwo,"e",@progbits
1318
.long .Ldebug_info_dwo_end1-.Ldebug_info_dwo_start1 # Length of Unit

0 commit comments

Comments
 (0)