diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2015-03-24 21:31:36 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2015-03-24 21:31:36 +0000 |
commit | fb911942f1434f3d1750f83f25f5e42c80e60638 (patch) | |
tree | 1678c4a4f0182e4029a86d135aa4a1b7d09e3c41 /test/elf/Mips/e-flags-merge-9.test |
Notes
Diffstat (limited to 'test/elf/Mips/e-flags-merge-9.test')
-rw-r--r-- | test/elf/Mips/e-flags-merge-9.test | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/test/elf/Mips/e-flags-merge-9.test b/test/elf/Mips/e-flags-merge-9.test new file mode 100644 index 0000000000000..dea32f07cb9e6 --- /dev/null +++ b/test/elf/Mips/e-flags-merge-9.test @@ -0,0 +1,43 @@ +# Check that LLD shows an error and does not link files with mips32r2 +# and mips64 instructions sets. + +# RUN: yaml2obj -format=elf -docnum 1 %s > %t-32r2.o +# RUN: yaml2obj -format=elf -docnum 2 %s > %t-64.o + +# RUN: not lld -flavor gnu -target mipsel -shared -o %t.so \ +# RUN: %t-32r2.o %t-64.o 2>&1 | FileCheck %s + +# CHECK: Linking modules with incompatible ISA + +# 32r2.o +--- +FileHeader: + Class: ELFCLASS32 + Data: ELFDATA2LSB + Type: ET_REL + Machine: EM_MIPS + Flags: [EF_MIPS_ABI_O32, EF_MIPS_ARCH_32R2] + +Sections: + - Name: .text + Type: SHT_PROGBITS + Flags: [ SHF_ALLOC, SHF_EXECINSTR ] + AddressAlign: 0x04 + Size: 0x04 + +# 64.o +--- +FileHeader: + Class: ELFCLASS32 + Data: ELFDATA2LSB + Type: ET_REL + Machine: EM_MIPS + Flags: [EF_MIPS_ABI_O32, EF_MIPS_ARCH_64, EF_MIPS_32BITMODE] + +Sections: + - Name: .text + Type: SHT_PROGBITS + Flags: [ SHF_ALLOC, SHF_EXECINSTR ] + AddressAlign: 0x04 + Size: 0x04 +... |