| 1 |
# Tests the case where a DW_TAG_subprogram for a method declaration |
| 2 |
# got uniqued into a DW_TAG_subprogram with the same linkage name (but |
| 3 |
# different DW_AT_name). Make sure the DW_TAG_subprogram DIE for the |
| 4 |
# definition, which previously pointed to the now de-deduplicated declaration, |
| 5 |
# gets inserted into the .debug_names table using the DW_AT_name of the canonical |
| 6 |
# declaration DW_TAG_subprogram. |
| 7 |
# |
| 8 |
# Object files compiled as follows: |
| 9 |
# clang -g -c -o 1.o Inputs/odr-uniquing-DW_AT_name-conflict/lib1.cpp |
| 10 |
# clang -g -c -o 2.o Inputs/odr-uniquing-DW_AT_name-conflict/lib2.cpp |
| 11 |
|
| 12 |
# RUN: dsymutil -f -oso-prepend-path=%p/../Inputs/odr-uniquing-DW_AT_name-conflict -y %p/dummy-debug-map-arm64.map -o - \ |
| 13 |
# RUN: | llvm-dwarfdump --verify - | FileCheck %s |
| 14 |
|
| 15 |
# RUN: dsymutil --linker parallel -f -oso-prepend-path=%p/../Inputs/odr-uniquing-DW_AT_name-conflict -y %p/dummy-debug-map-arm64.map -o - \ |
| 16 |
# RUN: | not llvm-dwarfdump --verify - | FileCheck %s --check-prefix=PARALLEL-ODR |
| 17 |
|
| 18 |
# RUN: dsymutil -f -oso-prepend-path=%p/../Inputs/odr-uniquing-DW_AT_name-conflict -y %p/dummy-debug-map-arm64.map -no-odr -o - \ |
| 19 |
# RUN: | llvm-dwarfdump --verify - | FileCheck %s |
| 20 |
|
| 21 |
# RUN: dsymutil --linker parallel -f -oso-prepend-path=%p/../Inputs/odr-uniquing-DW_AT_name-conflict -y %p/dummy-debug-map-arm64.map -no-odr -o - \ |
| 22 |
# RUN: | llvm-dwarfdump --verify - | FileCheck %s |
| 23 |
|
| 24 |
# CHECK: No errors. |
| 25 |
|
| 26 |
# FIXME: parallel DWARFLinker uses wrong DW_AT_name when inserting uniqued subprogram into .debug_names |
| 27 |
# PARALLEL-ODR: Verifying .debug_names... |
| 28 |
# PARALLEL-ODR-NEXT: error: Name Index {{.*}} mismatched Name of DIE |