brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.2 KiB · fdfc925 Raw
34 lines · yaml
1## Check we can produce 32/64 bits outputs with a different endianness.2 3# RUN: yaml2obj -D BITS=64 -D ENCODE=LSB %s | llvm-readobj --file-headers - | \4# RUN:   FileCheck %s --check-prefix=LE645# RUN: yaml2obj -D BITS=64 -D ENCODE=MSB %s | llvm-readobj --file-headers - | \6# RUN:   FileCheck %s --check-prefix=BE647# RUN: yaml2obj -D BITS=32 -D ENCODE=LSB %s | llvm-readobj --file-headers - | \8# RUN:   FileCheck %s --check-prefix=LE329# RUN: yaml2obj -D BITS=32 -D ENCODE=MSB %s | llvm-readobj --file-headers - | \10# RUN:   FileCheck %s --check-prefix=BE3211 12# LE64:      Class: 64-bit (0x2)13# LE64-NEXT: DataEncoding: LittleEndian (0x1)14 15# BE64:      Class: 64-bit (0x2)16# BE64-NEXT: DataEncoding: BigEndian (0x2)17 18# LE32:      Class: 32-bit (0x1)19# LE32-NEXT: DataEncoding: LittleEndian (0x1)20 21# BE32:      Class: 32-bit (0x1)22# BE32-NEXT: DataEncoding: BigEndian (0x2)23 24# RUN: not yaml2obj --docnum=1 -D BITS=16 -D ENCODE=LSB %s 2>&1 | FileCheck --check-prefix=BAD %s25# RUN: not yaml2obj --docnum=1 -D BITS=32 -D ENCODE= %s 2>&1 | FileCheck --check-prefix=BAD %s26 27# BAD: error: unknown enumerated scalar28 29--- !ELF30FileHeader: !FileHeader31  Class: ELFCLASS[[BITS]]32  Data:  ELFDATA2[[ENCODE]]33  Type:  ET_EXEC34