aboutsummaryrefslogtreecommitdiffstats
path: root/test/tools/llvm-objdump/X86/macho-universal-x86_64.i386.test
diff options
context:
space:
mode:
Diffstat (limited to 'test/tools/llvm-objdump/X86/macho-universal-x86_64.i386.test')
-rw-r--r--test/tools/llvm-objdump/X86/macho-universal-x86_64.i386.test44
1 files changed, 44 insertions, 0 deletions
diff --git a/test/tools/llvm-objdump/X86/macho-universal-x86_64.i386.test b/test/tools/llvm-objdump/X86/macho-universal-x86_64.i386.test
new file mode 100644
index 0000000..e4fd37a
--- /dev/null
+++ b/test/tools/llvm-objdump/X86/macho-universal-x86_64.i386.test
@@ -0,0 +1,44 @@
+RUN: llvm-objdump %p/Inputs/macho-universal.x86_64.i386 -d -m -no-show-raw-insn -full-leading-addr -print-imm-hex -arch all \
+RUN: | FileCheck %s -check-prefix UEXE-all
+RUN: llvm-objdump %p/Inputs/macho-universal-archive.x86_64.i386 -d -m -no-show-raw-insn -full-leading-addr -print-imm-hex -arch i386 \
+RUN: | FileCheck %s -check-prefix UArchive-i386
+RUN: llvm-objdump %p/Inputs/macho-universal.x86_64.i386 -universal-headers -m \
+RUN: | FileCheck %s -check-prefix FAT
+
+UEXE-all: macho-universal.x86_64.i386 (architecture x86_64):
+UEXE-all: (__TEXT,__text) section
+UEXE-all: _main:
+UEXE-all: 0000000100000f60 pushq %rbp
+UEXE-all: 0000000100000f61 movq %rsp, %rbp
+UEXE-all: macho-universal.x86_64.i386 (architecture i386):
+UEXE-all: (__TEXT,__text) section
+UEXE-all: _main:
+UEXE-all: 00001fa0 pushl %ebp
+UEXE-all: 00001fa1 movl %esp, %ebp
+
+UArchive-i386: Archive : {{.*}}/macho-universal-archive.x86_64.i386
+UArchive-i386: macho-universal-archive.x86_64.i386(foo.o):
+UArchive-i386: (__TEXT,__text) section
+UArchive-i386: _foo:
+UArchive-i386: 00000000 pushl %ebp
+UArchive-i386: 00000001 movl %esp, %ebp
+UArchive-i386: 00000003 popl %ebp
+UArchive-i386: 00000004 retl
+
+FAT: Fat headers
+FAT: fat_magic FAT_MAGIC
+FAT: nfat_arch 2
+FAT: architecture x86_64
+FAT: cputype CPU_TYPE_X86_64
+FAT: cpusubtype CPU_SUBTYPE_X86_64_ALL
+FAT: capabilities CPU_SUBTYPE_LIB64
+FAT: offset 4096
+FAT: size 4360
+FAT: align 2^12 (4096)
+FAT: architecture i386
+FAT: cputype CPU_TYPE_I386
+FAT: cpusubtype CPU_SUBTYPE_I386_ALL
+FAT: capabilities 0x0
+FAT: offset 12288
+FAT: size 4336
+FAT: align 2^12 (4096)