From d2e5d9db030f5ad48d82d68e433691685c4d3092 Mon Sep 17 00:00:00 2001 From: Rui Ueyama Date: Tue, 3 Nov 2020 22:57:37 +0900 Subject: [PATCH] temporary --- test/hello.s | 24 ++++++++++++++++++++++++ test/static.s | 24 ------------------------ 2 files changed, 24 insertions(+), 24 deletions(-) create mode 100644 test/hello.s delete mode 100644 test/static.s diff --git a/test/hello.s b/test/hello.s new file mode 100644 index 00000000..a6564b97 --- /dev/null +++ b/test/hello.s @@ -0,0 +1,24 @@ +// RUN: cc -o %t.o -c %s +// RUN: mold -o %t.exe /usr/lib/x86_64-linux-gnu/crt1.o \ +// RUN: /usr/lib/x86_64-linux-gnu/crti.o \ +// RUN: /usr/lib/gcc/x86_64-linux-gnu/9/crtbeginT.o \ +// RUN: %t.o \ +// RUN: /usr/lib/gcc/x86_64-linux-gnu/9/libgcc.a \ +// RUN: /usr/lib/gcc/x86_64-linux-gnu/9/libgcc_eh.a \ +// RUN: /usr/lib/x86_64-linux-gnu/libc.a \ +// RUN: /usr/lib/gcc/x86_64-linux-gnu/9/crtend.o \ +// RUN: /usr/lib/x86_64-linux-gnu/crtn.o +// RUN: %t.exe + + .text + .globl main +main: + lea msg(%rip), %rdi + xor %rax, %rax + call printf + xor %rax, %rax + ret + + .data +msg: + .string "Hello world\n" diff --git a/test/static.s b/test/static.s deleted file mode 100644 index 2eae99da..00000000 --- a/test/static.s +++ /dev/null @@ -1,24 +0,0 @@ -# RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t.o -# RUN: mold -o %t.exe \ -# RUN: /usr/lib/x86_64-linux-gnu/crt1.o \ -# RUN: /usr/lib/x86_64-linux-gnu/crti.o \ -# RUN: /usr/lib/gcc/x86_64-linux-gnu/9/crtbeginT.o \ -# RUN: %t.o \ -# RUN: /usr/lib/gcc/x86_64-linux-gnu/9/libgcc.a \ -# RUN: /usr/lib/gcc/x86_64-linux-gnu/9/libgcc_eh.a \ -# RUN: /usr/lib/x86_64-linux-gnu/libc.a \ -# RUN: /usr/lib/gcc/x86_64-linux-gnu/9/crtend.o \ -# RUN: /usr/lib/x86_64-linux-gnu/crtn.o - - .text - .globl main -main: - lea .Lhello(%rip), %rdi - xor %eax, %eax - call printf - xor %edi, %edi - call exit - - .data -.Lhello: - .ascii "Hello world!\n"