Skip to content

Commit 1216763

Browse files
committed
[VE] Add SVOB intrinsic instruction
Add SVOB intrinsic instruction and a regression test. Reviewed By: simoll Differential Revision: https://reviews.llvm.org/D94279
1 parent 8e3230f commit 1216763

File tree

3 files changed

+28
-0
lines changed

3 files changed

+28
-0
lines changed

llvm/include/llvm/IR/IntrinsicsVE.td

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,10 @@
11
// Define intrinsics written by hand
22

3+
// VEL Intrinsic instructions.
4+
let TargetPrefix = "ve" in {
5+
def int_ve_vl_svob : GCCBuiltin<"__builtin_ve_vl_svob">,
6+
Intrinsic<[], [], [IntrHasSideEffects]>;
7+
}
8+
39
// Define intrinsics automatically generated
410
include "llvm/IR/IntrinsicsVEVL.gen.td"

llvm/lib/Target/VE/VEInstrIntrinsicVL.td

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@
22

33
// Define intrinsics written by hand
44

5+
// SVOB pattern.
6+
def : Pat<(int_ve_vl_svob), (SVOB)>;
7+
58
// The lsv and lvs patterns
69
def : Pat<(int_ve_vl_lsv_vvss v256f64:$pt, i32:$sy, i64:$sz),
710
(LSVrr_v (INSERT_SUBREG (i64 (IMPLICIT_DEF)), i32:$sy, sub_i32),
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
; RUN: llc < %s -mtriple=ve -mattr=+vpu | FileCheck %s
2+
3+
;;; Test set vector out-of-order memory access boundary intrinsic instructions
4+
;;;
5+
;;; Note:
6+
;;; We test SVOB instruction.
7+
8+
; Function Attrs: nounwind
9+
define fastcc void @svob_svob() {
10+
; CHECK-LABEL: svob_svob:
11+
; CHECK: # %bb.0:
12+
; CHECK-NEXT: svob
13+
; CHECK-NEXT: b.l.t (, %s10)
14+
tail call void @llvm.ve.vl.svob()
15+
ret void
16+
}
17+
18+
; Function Attrs: nounwind
19+
declare void @llvm.ve.vl.svob()

0 commit comments

Comments
 (0)