[lld] r207738 - [Mips] Follow-up to the r207687. Add the test to check MIPS specific
Simon Atanasyan
simon at atanasyan.com
Wed Apr 30 22:12:32 PDT 2014
Author: atanasyan
Date: Thu May 1 00:12:32 2014
New Revision: 207738
URL: http://llvm.org/viewvc/llvm-project?rev=207738&view=rev
Log:
[Mips] Follow-up to the r207687. Add the test to check MIPS specific
arguments of the -m command line option.
Added:
lld/trunk/test/elf/Mips/opt-emulation.test
Added: lld/trunk/test/elf/Mips/opt-emulation.test
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/test/elf/Mips/opt-emulation.test?rev=207738&view=auto
==============================================================================
--- lld/trunk/test/elf/Mips/opt-emulation.test (added)
+++ lld/trunk/test/elf/Mips/opt-emulation.test Thu May 1 00:12:32 2014
@@ -0,0 +1,43 @@
+# Check MIPS specific arguments of the -m command line option.
+
+# RUN: yaml2obj -format=elf %s > %t-obj
+# RUN: lld -flavor gnu -target mipsel -m elf32ltsmip -o %t-exe %t-obj
+# RUN: llvm-readobj -file-headers %t-exe | FileCheck -check-prefix=LE-O32 %s
+
+# LE-O32: Class: 32-bit (0x1)
+# LE-O32: DataEncoding: LittleEndian (0x1)
+# LE-O32: FileVersion: 1
+# LE-O32: OS/ABI: SystemV (0x0)
+# LE-O32: ABIVersion: 0
+# LE-O32: Machine: EM_MIPS (0x8)
+# LE-O32: Version: 1
+# LE-O32: Flags [ (0x70001005)
+# LE-O32-NEXT: 0x1
+# LE-O32-NEXT: 0x4
+# LE-O32-NEXT: 0x1000
+# LE-O32-NEXT: 0x10000000
+# LE-O32-NEXT: 0x20000000
+# LE-O32-NEXT: 0x40000000
+# LE-O32-NEXT: ]
+
+!ELF
+FileHeader: !FileHeader
+ Class: ELFCLASS32
+ Data: ELFDATA2LSB
+ Type: ET_REL
+ Machine: EM_MIPS
+ Flags: [EF_MIPS_CPIC]
+
+Sections:
+- Name: .text
+ Type: SHT_PROGBITS
+ Content: "00000000"
+ AddressAlign: 16
+ Flags: [SHF_EXECINSTR, SHF_ALLOC]
+
+Symbols:
+ Global:
+ - Name: __start
+ Section: .text
+ Value: 0x0
+ Size: 4
More information about the llvm-commits
mailing list