1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-22 18:54:02 +01:00
llvm-mirror/test/CodeGen/AArch64/2s-complement-asm.ll
Tim Northover 81311224cc AArch64: treat MC expressions as 2s complement arithmetic.
We had a couple of over-zealous diagnostics that meant IR with a reasonable and
valid interpretation was rejected.
2020-10-08 11:54:51 +01:00

10 lines
484 B
LLVM

; RUN: llc -mtriple=arm64-apple-ios %s -filetype=obj -o - | llvm-objdump --macho --section __DATA,__data - | FileCheck %s
; CHECK: Contents of (__DATA,__data) section
; CHECK: 0000002a 59ed145d
@other = global i32 42
@var = global i32 sub(i32 646102975,
i32 add (i32 trunc(i64 sub(i64 ptrtoint(i32* @var to i64),
i64 ptrtoint(i32* @other to i64)) to i32),
i32 3432360802))