mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-24 11:42:57 +01:00
c4056176b9
The jcvt intrinsic defined in ACLE [1] is available when ARM_FEATURE_JCVT is defined. This change introduces the AArch64 intrinsic, wires it up to the instruction and a new clang builtin function. The __ARM_FEATURE_JCVT macro is now defined when an Armv8.3-A or higher target is used. I've implemented the target detection logic in Clang so that this feature is enabled for architectures from armv8.3-a onwards (so -march=armv8.4-a also enables this, for example). make check-all didn't show any new failures. [1] https://developer.arm.com/docs/101028/latest/data-processing-intrinsics Differential Revision: https://reviews.llvm.org/D64495 llvm-svn: 366197
11 lines
266 B
LLVM
11 lines
266 B
LLVM
; RUN: llc -mtriple=arm64-eabi -mattr=+jsconv -o - %s | FileCheck %s
|
|
|
|
define i32 @test_jcvt(double %v) {
|
|
; CHECK-LABEL: test_jcvt:
|
|
; CHECK: fjcvtzs w0, d0
|
|
%val = call i32 @llvm.aarch64.fjcvtzs(double %v)
|
|
ret i32 %val
|
|
}
|
|
|
|
declare i32 @llvm.aarch64.fjcvtzs(double)
|