2018-03-06 23:56:20 +08:00
|
|
|
# RUN: mkdir -p %t/.build-id/1b
|
|
|
|
# RUN: yaml2obj %s > %t/.build-id/1b/8a73ac238390e32a7ff4ac8ebe4d6a41ecf5c9.debug
|
|
|
|
# RUN: cd %t
|
|
|
|
# RUN: llvm-objcopy --strip-all --add-gnu-debuglink=.build-id/1b/8a73ac238390e32a7ff4ac8ebe4d6a41ecf5c9.debug %t/.build-id/1b/8a73ac238390e32a7ff4ac8ebe4d6a41ecf5c9.debug %t/stripped.out
|
|
|
|
# RUN: lldb-test module-sections %t/stripped.out | FileCheck %s
|
|
|
|
|
|
|
|
# CHECK: Name: .debug_frame
|
2018-04-30 03:47:48 +08:00
|
|
|
# CHECK-NEXT: Type: dwarf-frame
|
2018-03-06 23:56:20 +08:00
|
|
|
# CHECK-NEXT: VM size: 0
|
|
|
|
# CHECK-NEXT: File size: 8
|
|
|
|
|
|
|
|
--- !ELF
|
|
|
|
FileHeader:
|
|
|
|
Class: ELFCLASS64
|
|
|
|
Data: ELFDATA2LSB
|
|
|
|
Type: ET_EXEC
|
|
|
|
Machine: EM_X86_64
|
|
|
|
Entry: 0x00000000004003D0
|
|
|
|
Sections:
|
|
|
|
- Name: .note.gnu.build-id
|
|
|
|
Type: SHT_NOTE
|
|
|
|
Flags: [ SHF_ALLOC ]
|
|
|
|
Address: 0x0000000000400274
|
|
|
|
AddressAlign: 0x0000000000000004
|
|
|
|
Content: 040000001400000003000000474E55001B8A73AC238390E32A7FF4AC8EBE4D6A41ECF5C9
|
|
|
|
- Name: .text
|
|
|
|
Type: SHT_PROGBITS
|
|
|
|
Flags: [ SHF_ALLOC, SHF_EXECINSTR ]
|
|
|
|
Address: 0x00000000004003D0
|
|
|
|
AddressAlign: 0x0000000000000010
|
|
|
|
Content: DEADBEEFBAADF00D
|
|
|
|
- Name: .debug_frame
|
|
|
|
Type: SHT_PROGBITS
|
|
|
|
AddressAlign: 0x0000000000000008
|
|
|
|
Content: DEADBEEFBAADF00D
|
|
|
|
Symbols:
|
|
|
|
Local:
|
|
|
|
- Name: main
|
|
|
|
Type: STT_FUNC
|
|
|
|
Section: .text
|
|
|
|
Value: 0x00000000004003D0
|
|
|
|
Size: 0x0000000000000008
|
|
|
|
...
|