diff options
author | David Blaikie <dblaikie@gmail.com> | 2016-02-26 07:30:15 +0000 |
---|---|---|
committer | David Blaikie <dblaikie@gmail.com> | 2016-02-26 07:30:15 +0000 |
commit | f1958da1c33b5f456ec759eb24c2a807071ebc90 (patch) | |
tree | 317117aa1d20fa52ca361e276e41353e22837034 /llvm/test/tools | |
parent | 5d6d4dc3061777393f4d2b830186a2f716c689a0 (diff) | |
download | bcm5719-llvm-f1958da1c33b5f456ec759eb24c2a807071ebc90.tar.gz bcm5719-llvm-f1958da1c33b5f456ec759eb24c2a807071ebc90.zip |
llvm-dwp: provide diagnostics for duplicate DWO IDs
These diagnostics aren't perfect - in the case of merging several dwos
into dwps and those dwps into more dwps - just getting the message about
the original source file name might not be much help (since it's the
same in both dwos, by definition - but doesn't tell you which chain of
dwps to backtrack)
It might be worth adding the DW_AT_dwo_id to the split debug info to
improve the diagnostic experience - might help track down the duplicates
better.
llvm-svn: 261988
Diffstat (limited to 'llvm/test/tools')
-rw-r--r-- | llvm/test/tools/llvm-dwp/Inputs/duplicate/ac.dwp | bin | 0 -> 1288 bytes | |||
-rw-r--r-- | llvm/test/tools/llvm-dwp/Inputs/duplicate/bc.dwp | bin | 0 -> 1288 bytes | |||
-rw-r--r-- | llvm/test/tools/llvm-dwp/Inputs/duplicate/c.dwo | bin | 0 -> 1169 bytes | |||
-rw-r--r-- | llvm/test/tools/llvm-dwp/X86/duplicate.test | 18 |
4 files changed, 18 insertions, 0 deletions
diff --git a/llvm/test/tools/llvm-dwp/Inputs/duplicate/ac.dwp b/llvm/test/tools/llvm-dwp/Inputs/duplicate/ac.dwp Binary files differnew file mode 100644 index 00000000000..e4f3d103657 --- /dev/null +++ b/llvm/test/tools/llvm-dwp/Inputs/duplicate/ac.dwp diff --git a/llvm/test/tools/llvm-dwp/Inputs/duplicate/bc.dwp b/llvm/test/tools/llvm-dwp/Inputs/duplicate/bc.dwp Binary files differnew file mode 100644 index 00000000000..9696e3155d7 --- /dev/null +++ b/llvm/test/tools/llvm-dwp/Inputs/duplicate/bc.dwp diff --git a/llvm/test/tools/llvm-dwp/Inputs/duplicate/c.dwo b/llvm/test/tools/llvm-dwp/Inputs/duplicate/c.dwo Binary files differnew file mode 100644 index 00000000000..7c5c91101ef --- /dev/null +++ b/llvm/test/tools/llvm-dwp/Inputs/duplicate/c.dwo diff --git a/llvm/test/tools/llvm-dwp/X86/duplicate.test b/llvm/test/tools/llvm-dwp/X86/duplicate.test new file mode 100644 index 00000000000..1330cf37fed --- /dev/null +++ b/llvm/test/tools/llvm-dwp/X86/duplicate.test @@ -0,0 +1,18 @@ +RUN: not llvm-dwp %p/../Inputs/duplicate/c.dwo %p/../Inputs/duplicate/c.dwo -o %t 2>&1 \ +RUN: | FileCheck --check-prefix=CHECK %s + +RUN: not llvm-dwp %p/../Inputs/duplicate/c.dwo %p/../Inputs/duplicate/bc.dwp -o %t 2>&1 \ +RUN: | FileCheck --check-prefix=CHECK --check-prefix=DWP2 %s + +RUN: not llvm-dwp %p/../Inputs/duplicate/ac.dwp %p/../Inputs/duplicate/c.dwo -o %t 2>&1 \ +RUN: | FileCheck --check-prefix=CHECK --check-prefix=DWP1 %s + +RUN: not llvm-dwp %p/../Inputs/duplicate/ac.dwp %p/../Inputs/duplicate/bc.dwp -o %t 2>&1 \ +RUN: | FileCheck --check-prefix=CHECK --check-prefix=DWP1 --check-prefix=DWP2 %s + +Build from a, b, and c.c all containing a single void() func by the name of the file. + +CHECK: Duplicate DWO ID ({{.*}}) in 'c.c' +DWP1-SAME: (from '{{.*}}ac.dwp') +CHECK-SAME: and 'c.c' +DWP2-SAME: (from '{{.*}}bc.dwp') |