1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 19:23:23 +01:00
llvm-mirror/test/CodeGen/PowerPC/aix-xcoff-endian-error.ll
Hubert Tong bc72f56aea [Target][XCOFF] Correctly halt when mixing AIX or XCOFF with ppc64le
The code to prevent using `PPCXCOFFMCAsmInfo` with little-endian targets
used an incorrect check. Also, there does not appear to be sufficient
earlier checking to prevent failing this check, so the check here is
upgraded to be a `report_fatal_error`.

`PPCAIXAsmPrinter` was also missing a check against use with
little-endian targets. This patch adds such a check in.
2020-05-08 16:51:34 -04:00

14 lines
571 B
LLVM

; Check that use of the AIX/XCOFF related classes with ppc64le would
; cause llc to die with an appropriate message instead of proceeding
; with an invalid state.
; RUN: not --crash llc < %s -mtriple powerpc64le--aix-xcoff 2>&1 \
; RUN: | FileCheck --check-prefix=AIXXCOFF %s
; AIXXCOFF: ERROR: XCOFF is not supported for little-endian
; RUN: not --crash llc < %s -mtriple powerpc64le--aix-macho 2>&1 \
; RUN: | FileCheck --check-prefix=AIXMACHO %s
; AIXMACHO: ERROR: cannot create AIX PPC Assembly Printer for a little-endian target
define i32 @a() { ret i32 0 }