Pavel Labath | 452bd87 | 2018-06-07 10:35:28 +0000 | [diff] [blame] | 1 | // Test that we return complete results when only a part of the binary is built |
| 2 | // with an index. |
| 3 | |
| 4 | // REQUIRES: lld |
| 5 | |
Zachary Turner | 58db03a | 2018-11-19 15:12:34 +0000 | [diff] [blame] | 6 | // RUN: %clang %s -g -c -o %t-1.o --target=x86_64-pc-linux -DONE -mllvm -accel-tables=Dwarf |
| 7 | // RUN: %clang %s -g -c -o %t-2.o --target=x86_64-pc-linux -DTWO -mllvm -accel-tables=Dwarf |
Pavel Labath | 452bd87 | 2018-06-07 10:35:28 +0000 | [diff] [blame] | 8 | // RUN: ld.lld %t-1.o %t-2.o -o %t |
| 9 | // RUN: lldb-test symbols --find=variable --name=foo %t | FileCheck %s |
| 10 | |
| 11 | // CHECK: Found 2 variables: |
| 12 | #ifdef ONE |
| 13 | namespace one { |
| 14 | int foo; |
| 15 | // CHECK-DAG: name = "foo", {{.*}} decl = dwarf5-partial-index.cpp:[[@LINE-1]] |
| 16 | } // namespace one |
| 17 | extern "C" void _start() {} |
| 18 | #else |
| 19 | namespace two { |
| 20 | int foo; |
| 21 | // CHECK-DAG: name = "foo", {{.*}} decl = dwarf5-partial-index.cpp:[[@LINE-1]] |
| 22 | } // namespace two |
| 23 | #endif |