33 lines · plain
1# RUN: rm -rf %t && mkdir -p %t2# RUN: llvm-mc -triple=arm64e-apple-darwin -filetype=obj -o %t/main.o %s3# RUN: llvm-mc -triple=arm64-apple-darwin -filetype=obj -o %t/x.arm64.o \4# RUN: %S/Inputs/x-1.s5# RUN: llvm-ar crs %t/libX.arm64.a %t/x.arm64.o6# RUN: llvm-mc -triple=arm64e-apple-darwin -filetype=obj -o %t/x.arm64e.o \7# RUN: %S/Inputs/x-0.s8# RUN: llvm-ar crs %t/libX.arm64e.a %t/x.arm64e.o9# RUN: llvm-lipo --create --output %t/libX.a %t/libX.arm64.a %t/libX.arm64e.a10# RUN: llvm-jitlink -noexec -check=%s %t/main.o -L%t -lX11#12# Create a universal archive with two slices (arm64e, arm64) each containing13# a definition of X: in arm64e X = 0, in arm64 X = 1.14# Check that if we load an arm64e object file then we link the arm64e slice15# of the archive by verifying that X = 0.16#17 18# jitlink-check: *{4}x = 019 20 .section __TEXT,__text,regular,pure_instructions21 .globl _main22 .p2align 223_main:24 mov w0, #025 ret26 27 .section __DATA,__data28 .globl p29p:30 .quad x31 32.subsections_via_symbols33