brintos

brintos / llvm-project-archived public Read only

0
0
Text · 2.3 KiB · 39d41f3 Raw
75 lines · yaml
1# RUN: yaml2obj %s -o %t2# RUN: llvm-readobj -r %t | FileCheck %s --check-prefix=RELOCS3# RUN: obj2yaml %t | FileCheck %s --check-prefix=YAML4 5# RELOCS:      Relocations [6# RELOCS-NEXT:   Section (1) .text {7# RELOCS-NEXT:     0x3 IMAGE_REL_AMD64_REL32 .rdata (0)8# RELOCS-NEXT:     0xA IMAGE_REL_AMD64_REL32 .rdata (1)9# RELOCS-NEXT:     0x11 IMAGE_REL_AMD64_REL32 foo (2)10# RELOCS-NEXT:   }11# RELOCS-NEXT: ]12 13## Check that we usually output relocations with SymbolName.14## For relocations with a non-unique symbol name, output15## SymbolTableIndex instead.16 17# YAML:          Relocations:18# YAML-NEXT:       - VirtualAddress:  319# YAML-NEXT:         SymbolTableIndex: 020# YAML-NEXT:         Type:            IMAGE_REL_AMD64_REL3221# YAML-NEXT:       - VirtualAddress:  1022# YAML-NEXT:         SymbolTableIndex: 123# YAML-NEXT:         Type:            IMAGE_REL_AMD64_REL3224# YAML-NEXT:       - VirtualAddress:  1725# YAML-NEXT:         SymbolName:      foo26# YAML-NEXT:         Type:            IMAGE_REL_AMD64_REL3227 28--- !COFF29header:30  Machine:         IMAGE_FILE_MACHINE_AMD6431  Characteristics: [  ]32sections:33  - Name:            .text34    Characteristics: [  ]35    Alignment:       436    SectionData:     488B0500000000488B0500000000488B050000000037    Relocations:38      - VirtualAddress:  339        SymbolTableIndex: 040        Type:            IMAGE_REL_AMD64_REL3241      - VirtualAddress:  1042        SymbolTableIndex: 143        Type:            IMAGE_REL_AMD64_REL3244      - VirtualAddress:  1745        SymbolName:      foo46        Type:            IMAGE_REL_AMD64_REL3247  - Name:            .rdata48    Characteristics: [  ]49    Alignment:       150    SectionData:     '00'51  - Name:            .rdata52    Characteristics: [  ]53    Alignment:       154    SectionData:     '01'55symbols:56  - Name:            .rdata57    Value:           058    SectionNumber:   259    SimpleType:      IMAGE_SYM_TYPE_NULL60    ComplexType:     IMAGE_SYM_DTYPE_NULL61    StorageClass:    IMAGE_SYM_CLASS_STATIC62  - Name:            .rdata63    Value:           064    SectionNumber:   365    SimpleType:      IMAGE_SYM_TYPE_NULL66    ComplexType:     IMAGE_SYM_DTYPE_NULL67    StorageClass:    IMAGE_SYM_CLASS_STATIC68  - Name:            foo69    Value:           070    SectionNumber:   371    SimpleType:      IMAGE_SYM_TYPE_NULL72    ComplexType:     IMAGE_SYM_DTYPE_NULL73    StorageClass:    IMAGE_SYM_CLASS_EXTERNAL74...75