Files
clang-p2996/llvm/test/CodeGen/LoongArch/e_flags.ll
WANG Xuerui 4e2dfd3589 [LoongArch] Updates for the LoongArch ELF psABI v2.01 revision
The e_flags of existing object files are all 0x3 which happens to be
compatible. From this commit on, all LoongArch objects produced with
upstream LLVM will be of object file ABI v1, which is already supported
by binutils' master branch (to be released as 2.40), and is allowed by
the same binutils version to interlink with v0 objects so the existing
distributions have time to migrate.

Differential Revision: https://reviews.llvm.org/D134601
2022-10-13 19:12:26 +08:00

18 lines
663 B
LLVM

; RUN: llc --mtriple=loongarch32 --filetype=obj %s -o %t-la32
; RUN: llvm-readelf -h %t-la32 | FileCheck %s --check-prefixes=ILP32,ABI-D --match-full-lines
; RUN: llc --mtriple=loongarch64 --filetype=obj %s -o %t-la64
; RUN: llvm-readelf -h %t-la64 | FileCheck %s --check-prefixes=LP64,ABI-D --match-full-lines
;; Note that we have not support the -target-abi option to select specific ABI.
;; See comments in LoongArchELFStreamer.cpp. So here we only check the default behaviour.
;; After -target-abi is supported, we can add more tests.
; LP64: Class: ELF64
; ILP32: Class: ELF32
; ABI-D: Flags: 0x43, DOUBLE-FLOAT, OBJ-v1
define void @foo() {
ret void
}