Imported Upstream version 5.18.0.182

Former-commit-id: f9d55cf82631bfd710c387739687e5845296aea1
This commit is contained in:
Xamarin Public Jenkins (auto-signing)
2018-10-26 08:32:15 +00:00
parent 8625704ad8
commit b716dc8d12
28490 changed files with 76 additions and 3866845 deletions

View File

@@ -1,67 +0,0 @@
; Test floating-point control register intrinsics.
;
; RUN: llc < %s -mtriple=s390x-linux-gnu | FileCheck %s
declare void @llvm.s390.sfpc(i32)
declare i32 @llvm.s390.efpc()
; SFPC.
define void @test_sfpc(i32 %fpc) {
; CHECK-LABEL: test_sfpc:
; CHECK: sfpc %r2
; CHECK: br %r14
call void @llvm.s390.sfpc(i32 %fpc)
ret void
}
; EFPC.
define i32 @test_efpc() {
; CHECK-LABEL: test_efpc:
; CHECK: efpc %r2
; CHECK: br %r14
%res = call i32 @llvm.s390.efpc()
ret i32 %res
}
; LFPC.
define void @test_lfpc1(i32 *%ptr) {
; CHECK-LABEL: test_lfpc1:
; CHECK: lfpc 0(%r2)
; CHECK: br %r14
%fpc = load i32, i32 *%ptr
call void @llvm.s390.sfpc(i32 %fpc)
ret void
}
; LFPC with offset.
define void @test_lfpc2(i32 *%ptr) {
; CHECK-LABEL: test_lfpc2:
; CHECK: lfpc 4092(%r2)
; CHECK: br %r14
%ptr1 = getelementptr i32, i32 *%ptr, i32 1023
%fpc = load i32, i32 *%ptr1
call void @llvm.s390.sfpc(i32 %fpc)
ret void
}
; STFPC.
define void @test_stfpc1(i32 *%ptr) {
; CHECK-LABEL: test_stfpc1:
; CHECK: stfpc 0(%r2)
; CHECK: br %r14
%fpc = call i32 @llvm.s390.efpc()
store i32 %fpc, i32 *%ptr
ret void
}
; STFPC with offset.
define void @test_stfpc2(i32 *%ptr) {
; CHECK-LABEL: test_stfpc2:
; CHECK: stfpc 4092(%r2)
; CHECK: br %r14
%fpc = call i32 @llvm.s390.efpc()
%ptr1 = getelementptr i32, i32 *%ptr, i32 1023
store i32 %fpc, i32 *%ptr1
ret void
}