1 ## This is a test case to check how obj2yaml dumps symbols.
3 ## Check that we only dump Size and Value keys when
4 ## their values are not 0.
6 # RUN: yaml2obj %s -o %t1
7 # RUN: obj2yaml %t1 | FileCheck %s --check-prefix=FIELDS-DEF
10 # FIELDS-DEF-NEXT: - Name: foo
11 # FIELDS-DEF-NEXT: - Name: bar
12 # FIELDS-DEF-NEXT: Value: 0x1
13 # FIELDS-DEF-NEXT: Size: 0x1
14 # FIELDS-DEF-NEXT: ...
29 ## Check how we dump unnamed section symbols.
30 ## Check we are able to handle the section symbol for the null section.
31 ## Document we name them with a section name they describe.
33 # RUN: yaml2obj --docnum=2 %s -o %t2
34 # RUN: obj2yaml %t2 | FileCheck %s --check-prefix=SECTION-SYM
36 # SECTION-SYM: --- !ELF
37 # SECTION-SYM-NEXT: FileHeader:
38 # SECTION-SYM-NEXT: Class: ELFCLASS64
39 # SECTION-SYM-NEXT: Data: ELFDATA2LSB
40 # SECTION-SYM-NEXT: Type: ET_REL
41 # SECTION-SYM-NEXT: Sections:
42 # SECTION-SYM-NEXT: - Name: .section
43 # SECTION-SYM-NEXT: Type: SHT_PROGBITS
44 # SECTION-SYM-NEXT: Symbols:
45 # SECTION-SYM-NEXT: - Type: STT_SECTION
46 # SECTION-SYM-NEXT: - Name: .section
47 # SECTION-SYM-NEXT: Type: STT_SECTION
48 # SECTION-SYM-NEXT: Section: .section
49 # SECTION-SYM-NEXT: - Name: .section
50 # SECTION-SYM-NEXT: Type: STT_SECTION
51 # SECTION-SYM-NEXT: Section: .section
52 # SECTION-SYM-NEXT: ...