mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2025-02-25 21:11:25 +00:00
[VE] Add vector reduce intrinsic instructions
Add vrmax, vrmin, vfrmax, vfrmin, vrand, vror, and vrxor intrinsic instructions and regression tests. Reviewed By: simoll Differential Revision: https://reviews.llvm.org/D92941
This commit is contained in:
parent
99ad078b91
commit
4b1e329255
@ -1094,3 +1094,49 @@ let TargetPrefix = "ve" in def int_ve_vl_vfsumd_vvl : GCCBuiltin<"__builtin_ve_v
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vfsumd_vvml : GCCBuiltin<"__builtin_ve_vl_vfsumd_vvml">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256i1>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vfsums_vvl : GCCBuiltin<"__builtin_ve_vl_vfsums_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vfsums_vvml : GCCBuiltin<"__builtin_ve_vl_vfsums_vvml">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256i1>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrmaxswfstsx_vvl : GCCBuiltin<"__builtin_ve_vl_vrmaxswfstsx_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrmaxswfstsx_vvvl : GCCBuiltin<"__builtin_ve_vl_vrmaxswfstsx_vvvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrmaxswlstsx_vvl : GCCBuiltin<"__builtin_ve_vl_vrmaxswlstsx_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrmaxswlstsx_vvvl : GCCBuiltin<"__builtin_ve_vl_vrmaxswlstsx_vvvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrmaxswfstzx_vvl : GCCBuiltin<"__builtin_ve_vl_vrmaxswfstzx_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrmaxswfstzx_vvvl : GCCBuiltin<"__builtin_ve_vl_vrmaxswfstzx_vvvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrmaxswlstzx_vvl : GCCBuiltin<"__builtin_ve_vl_vrmaxswlstzx_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrmaxswlstzx_vvvl : GCCBuiltin<"__builtin_ve_vl_vrmaxswlstzx_vvvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrminswfstsx_vvl : GCCBuiltin<"__builtin_ve_vl_vrminswfstsx_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrminswfstsx_vvvl : GCCBuiltin<"__builtin_ve_vl_vrminswfstsx_vvvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrminswlstsx_vvl : GCCBuiltin<"__builtin_ve_vl_vrminswlstsx_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrminswlstsx_vvvl : GCCBuiltin<"__builtin_ve_vl_vrminswlstsx_vvvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrminswfstzx_vvl : GCCBuiltin<"__builtin_ve_vl_vrminswfstzx_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrminswfstzx_vvvl : GCCBuiltin<"__builtin_ve_vl_vrminswfstzx_vvvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrminswlstzx_vvl : GCCBuiltin<"__builtin_ve_vl_vrminswlstzx_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrminswlstzx_vvvl : GCCBuiltin<"__builtin_ve_vl_vrminswlstzx_vvvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrmaxslfst_vvl : GCCBuiltin<"__builtin_ve_vl_vrmaxslfst_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrmaxslfst_vvvl : GCCBuiltin<"__builtin_ve_vl_vrmaxslfst_vvvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrmaxsllst_vvl : GCCBuiltin<"__builtin_ve_vl_vrmaxsllst_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrmaxsllst_vvvl : GCCBuiltin<"__builtin_ve_vl_vrmaxsllst_vvvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrminslfst_vvl : GCCBuiltin<"__builtin_ve_vl_vrminslfst_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrminslfst_vvvl : GCCBuiltin<"__builtin_ve_vl_vrminslfst_vvvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrminsllst_vvl : GCCBuiltin<"__builtin_ve_vl_vrminsllst_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrminsllst_vvvl : GCCBuiltin<"__builtin_ve_vl_vrminsllst_vvvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vfrmaxdfst_vvl : GCCBuiltin<"__builtin_ve_vl_vfrmaxdfst_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vfrmaxdfst_vvvl : GCCBuiltin<"__builtin_ve_vl_vfrmaxdfst_vvvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vfrmaxdlst_vvl : GCCBuiltin<"__builtin_ve_vl_vfrmaxdlst_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vfrmaxdlst_vvvl : GCCBuiltin<"__builtin_ve_vl_vfrmaxdlst_vvvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vfrmaxsfst_vvl : GCCBuiltin<"__builtin_ve_vl_vfrmaxsfst_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vfrmaxsfst_vvvl : GCCBuiltin<"__builtin_ve_vl_vfrmaxsfst_vvvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vfrmaxslst_vvl : GCCBuiltin<"__builtin_ve_vl_vfrmaxslst_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vfrmaxslst_vvvl : GCCBuiltin<"__builtin_ve_vl_vfrmaxslst_vvvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vfrmindfst_vvl : GCCBuiltin<"__builtin_ve_vl_vfrmindfst_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vfrmindfst_vvvl : GCCBuiltin<"__builtin_ve_vl_vfrmindfst_vvvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vfrmindlst_vvl : GCCBuiltin<"__builtin_ve_vl_vfrmindlst_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vfrmindlst_vvvl : GCCBuiltin<"__builtin_ve_vl_vfrmindlst_vvvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vfrminsfst_vvl : GCCBuiltin<"__builtin_ve_vl_vfrminsfst_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vfrminsfst_vvvl : GCCBuiltin<"__builtin_ve_vl_vfrminsfst_vvvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vfrminslst_vvl : GCCBuiltin<"__builtin_ve_vl_vfrminslst_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vfrminslst_vvvl : GCCBuiltin<"__builtin_ve_vl_vfrminslst_vvvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrand_vvl : GCCBuiltin<"__builtin_ve_vl_vrand_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrand_vvml : GCCBuiltin<"__builtin_ve_vl_vrand_vvml">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256i1>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vror_vvl : GCCBuiltin<"__builtin_ve_vl_vror_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vror_vvml : GCCBuiltin<"__builtin_ve_vl_vror_vvml">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256i1>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrxor_vvl : GCCBuiltin<"__builtin_ve_vl_vrxor_vvl">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<i32>], [IntrNoMem]>;
|
||||
let TargetPrefix = "ve" in def int_ve_vl_vrxor_vvml : GCCBuiltin<"__builtin_ve_vl_vrxor_vvml">, Intrinsic<[LLVMType<v256f64>], [LLVMType<v256f64>, LLVMType<v256i1>, LLVMType<i32>], [IntrNoMem]>;
|
||||
|
@ -1317,3 +1317,49 @@ def : Pat<(int_ve_vl_vfsumd_vvl v256f64:$vy, i32:$vl), (VFSUMDvl v256f64:$vy, i3
|
||||
def : Pat<(int_ve_vl_vfsumd_vvml v256f64:$vy, v256i1:$vm, i32:$vl), (VFSUMDvml v256f64:$vy, v256i1:$vm, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vfsums_vvl v256f64:$vy, i32:$vl), (VFSUMSvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vfsums_vvml v256f64:$vy, v256i1:$vm, i32:$vl), (VFSUMSvml v256f64:$vy, v256i1:$vm, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vrmaxswfstsx_vvl v256f64:$vy, i32:$vl), (VRMAXSWFSTSXvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vrmaxswfstsx_vvvl v256f64:$vy, v256f64:$pt, i32:$vl), (VRMAXSWFSTSXvl_v v256f64:$vy, i32:$vl, v256f64:$pt)>;
|
||||
def : Pat<(int_ve_vl_vrmaxswlstsx_vvl v256f64:$vy, i32:$vl), (VRMAXSWLSTSXvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vrmaxswlstsx_vvvl v256f64:$vy, v256f64:$pt, i32:$vl), (VRMAXSWLSTSXvl_v v256f64:$vy, i32:$vl, v256f64:$pt)>;
|
||||
def : Pat<(int_ve_vl_vrmaxswfstzx_vvl v256f64:$vy, i32:$vl), (VRMAXSWFSTZXvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vrmaxswfstzx_vvvl v256f64:$vy, v256f64:$pt, i32:$vl), (VRMAXSWFSTZXvl_v v256f64:$vy, i32:$vl, v256f64:$pt)>;
|
||||
def : Pat<(int_ve_vl_vrmaxswlstzx_vvl v256f64:$vy, i32:$vl), (VRMAXSWLSTZXvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vrmaxswlstzx_vvvl v256f64:$vy, v256f64:$pt, i32:$vl), (VRMAXSWLSTZXvl_v v256f64:$vy, i32:$vl, v256f64:$pt)>;
|
||||
def : Pat<(int_ve_vl_vrminswfstsx_vvl v256f64:$vy, i32:$vl), (VRMINSWFSTSXvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vrminswfstsx_vvvl v256f64:$vy, v256f64:$pt, i32:$vl), (VRMINSWFSTSXvl_v v256f64:$vy, i32:$vl, v256f64:$pt)>;
|
||||
def : Pat<(int_ve_vl_vrminswlstsx_vvl v256f64:$vy, i32:$vl), (VRMINSWLSTSXvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vrminswlstsx_vvvl v256f64:$vy, v256f64:$pt, i32:$vl), (VRMINSWLSTSXvl_v v256f64:$vy, i32:$vl, v256f64:$pt)>;
|
||||
def : Pat<(int_ve_vl_vrminswfstzx_vvl v256f64:$vy, i32:$vl), (VRMINSWFSTZXvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vrminswfstzx_vvvl v256f64:$vy, v256f64:$pt, i32:$vl), (VRMINSWFSTZXvl_v v256f64:$vy, i32:$vl, v256f64:$pt)>;
|
||||
def : Pat<(int_ve_vl_vrminswlstzx_vvl v256f64:$vy, i32:$vl), (VRMINSWLSTZXvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vrminswlstzx_vvvl v256f64:$vy, v256f64:$pt, i32:$vl), (VRMINSWLSTZXvl_v v256f64:$vy, i32:$vl, v256f64:$pt)>;
|
||||
def : Pat<(int_ve_vl_vrmaxslfst_vvl v256f64:$vy, i32:$vl), (VRMAXSLFSTvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vrmaxslfst_vvvl v256f64:$vy, v256f64:$pt, i32:$vl), (VRMAXSLFSTvl_v v256f64:$vy, i32:$vl, v256f64:$pt)>;
|
||||
def : Pat<(int_ve_vl_vrmaxsllst_vvl v256f64:$vy, i32:$vl), (VRMAXSLLSTvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vrmaxsllst_vvvl v256f64:$vy, v256f64:$pt, i32:$vl), (VRMAXSLLSTvl_v v256f64:$vy, i32:$vl, v256f64:$pt)>;
|
||||
def : Pat<(int_ve_vl_vrminslfst_vvl v256f64:$vy, i32:$vl), (VRMINSLFSTvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vrminslfst_vvvl v256f64:$vy, v256f64:$pt, i32:$vl), (VRMINSLFSTvl_v v256f64:$vy, i32:$vl, v256f64:$pt)>;
|
||||
def : Pat<(int_ve_vl_vrminsllst_vvl v256f64:$vy, i32:$vl), (VRMINSLLSTvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vrminsllst_vvvl v256f64:$vy, v256f64:$pt, i32:$vl), (VRMINSLLSTvl_v v256f64:$vy, i32:$vl, v256f64:$pt)>;
|
||||
def : Pat<(int_ve_vl_vfrmaxdfst_vvl v256f64:$vy, i32:$vl), (VFRMAXDFSTvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vfrmaxdfst_vvvl v256f64:$vy, v256f64:$pt, i32:$vl), (VFRMAXDFSTvl_v v256f64:$vy, i32:$vl, v256f64:$pt)>;
|
||||
def : Pat<(int_ve_vl_vfrmaxdlst_vvl v256f64:$vy, i32:$vl), (VFRMAXDLSTvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vfrmaxdlst_vvvl v256f64:$vy, v256f64:$pt, i32:$vl), (VFRMAXDLSTvl_v v256f64:$vy, i32:$vl, v256f64:$pt)>;
|
||||
def : Pat<(int_ve_vl_vfrmaxsfst_vvl v256f64:$vy, i32:$vl), (VFRMAXSFSTvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vfrmaxsfst_vvvl v256f64:$vy, v256f64:$pt, i32:$vl), (VFRMAXSFSTvl_v v256f64:$vy, i32:$vl, v256f64:$pt)>;
|
||||
def : Pat<(int_ve_vl_vfrmaxslst_vvl v256f64:$vy, i32:$vl), (VFRMAXSLSTvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vfrmaxslst_vvvl v256f64:$vy, v256f64:$pt, i32:$vl), (VFRMAXSLSTvl_v v256f64:$vy, i32:$vl, v256f64:$pt)>;
|
||||
def : Pat<(int_ve_vl_vfrmindfst_vvl v256f64:$vy, i32:$vl), (VFRMINDFSTvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vfrmindfst_vvvl v256f64:$vy, v256f64:$pt, i32:$vl), (VFRMINDFSTvl_v v256f64:$vy, i32:$vl, v256f64:$pt)>;
|
||||
def : Pat<(int_ve_vl_vfrmindlst_vvl v256f64:$vy, i32:$vl), (VFRMINDLSTvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vfrmindlst_vvvl v256f64:$vy, v256f64:$pt, i32:$vl), (VFRMINDLSTvl_v v256f64:$vy, i32:$vl, v256f64:$pt)>;
|
||||
def : Pat<(int_ve_vl_vfrminsfst_vvl v256f64:$vy, i32:$vl), (VFRMINSFSTvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vfrminsfst_vvvl v256f64:$vy, v256f64:$pt, i32:$vl), (VFRMINSFSTvl_v v256f64:$vy, i32:$vl, v256f64:$pt)>;
|
||||
def : Pat<(int_ve_vl_vfrminslst_vvl v256f64:$vy, i32:$vl), (VFRMINSLSTvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vfrminslst_vvvl v256f64:$vy, v256f64:$pt, i32:$vl), (VFRMINSLSTvl_v v256f64:$vy, i32:$vl, v256f64:$pt)>;
|
||||
def : Pat<(int_ve_vl_vrand_vvl v256f64:$vy, i32:$vl), (VRANDvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vrand_vvml v256f64:$vy, v256i1:$vm, i32:$vl), (VRANDvml v256f64:$vy, v256i1:$vm, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vror_vvl v256f64:$vy, i32:$vl), (VRORvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vror_vvml v256f64:$vy, v256i1:$vm, i32:$vl), (VRORvml v256f64:$vy, v256i1:$vm, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vrxor_vvl v256f64:$vy, i32:$vl), (VRXORvl v256f64:$vy, i32:$vl)>;
|
||||
def : Pat<(int_ve_vl_vrxor_vvml v256f64:$vy, v256i1:$vm, i32:$vl), (VRXORvml v256f64:$vy, v256i1:$vm, i32:$vl)>;
|
||||
|
138
llvm/test/CodeGen/VE/VELIntrinsics/vfrmax.ll
Normal file
138
llvm/test/CodeGen/VE/VELIntrinsics/vfrmax.ll
Normal file
@ -0,0 +1,138 @@
|
||||
; RUN: llc < %s -mtriple=ve -mattr=+vpu | FileCheck %s
|
||||
|
||||
;;; Test vector floating compare and select maximum intrinsic instructions
|
||||
;;;
|
||||
;;; Note:
|
||||
;;; We test VFRMAX*vl and VFRMAX*vl_v instructions.
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vfrmaxdfst_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vfrmaxdfst_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vfrmax.d.fst %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vfrmaxdfst.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vfrmaxdfst.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vfrmaxdfst_vvvl(<256 x double> %0, <256 x double> %1) {
|
||||
; CHECK-LABEL: vfrmaxdfst_vvvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 128
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vfrmax.d.fst %v1, %v0
|
||||
; CHECK-NEXT: lea %s16, 256
|
||||
; CHECK-NEXT: lvl %s16
|
||||
; CHECK-NEXT: vor %v0, (0)1, %v1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vfrmaxdfst.vvvl(<256 x double> %0, <256 x double> %1, i32 128)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vfrmaxdfst.vvvl(<256 x double>, <256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vfrmaxdlst_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vfrmaxdlst_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vfrmax.d.lst %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vfrmaxdlst.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vfrmaxdlst.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vfrmaxdlst_vvvl(<256 x double> %0, <256 x double> %1) {
|
||||
; CHECK-LABEL: vfrmaxdlst_vvvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 128
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vfrmax.d.lst %v1, %v0
|
||||
; CHECK-NEXT: lea %s16, 256
|
||||
; CHECK-NEXT: lvl %s16
|
||||
; CHECK-NEXT: vor %v0, (0)1, %v1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vfrmaxdlst.vvvl(<256 x double> %0, <256 x double> %1, i32 128)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vfrmaxdlst.vvvl(<256 x double>, <256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vfrmaxsfst_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vfrmaxsfst_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vfrmax.s.fst %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vfrmaxsfst.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vfrmaxsfst.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vfrmaxsfst_vvvl(<256 x double> %0, <256 x double> %1) {
|
||||
; CHECK-LABEL: vfrmaxsfst_vvvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 128
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vfrmax.s.fst %v1, %v0
|
||||
; CHECK-NEXT: lea %s16, 256
|
||||
; CHECK-NEXT: lvl %s16
|
||||
; CHECK-NEXT: vor %v0, (0)1, %v1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vfrmaxsfst.vvvl(<256 x double> %0, <256 x double> %1, i32 128)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vfrmaxsfst.vvvl(<256 x double>, <256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vfrmaxslst_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vfrmaxslst_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vfrmax.s.lst %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vfrmaxslst.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vfrmaxslst.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vfrmaxslst_vvvl(<256 x double> %0, <256 x double> %1) {
|
||||
; CHECK-LABEL: vfrmaxslst_vvvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 128
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vfrmax.s.lst %v1, %v0
|
||||
; CHECK-NEXT: lea %s16, 256
|
||||
; CHECK-NEXT: lvl %s16
|
||||
; CHECK-NEXT: vor %v0, (0)1, %v1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vfrmaxslst.vvvl(<256 x double> %0, <256 x double> %1, i32 128)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vfrmaxslst.vvvl(<256 x double>, <256 x double>, i32)
|
138
llvm/test/CodeGen/VE/VELIntrinsics/vfrmin.ll
Normal file
138
llvm/test/CodeGen/VE/VELIntrinsics/vfrmin.ll
Normal file
@ -0,0 +1,138 @@
|
||||
; RUN: llc < %s -mtriple=ve -mattr=+vpu | FileCheck %s
|
||||
|
||||
;;; Test vector floating compare and select minimum intrinsic instructions
|
||||
;;;
|
||||
;;; Note:
|
||||
;;; We test VFRMIN*vl and VFRMIN*vl_v instructions.
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vfrmindfst_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vfrmindfst_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vfrmin.d.fst %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vfrmindfst.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vfrmindfst.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vfrmindfst_vvvl(<256 x double> %0, <256 x double> %1) {
|
||||
; CHECK-LABEL: vfrmindfst_vvvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 128
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vfrmin.d.fst %v1, %v0
|
||||
; CHECK-NEXT: lea %s16, 256
|
||||
; CHECK-NEXT: lvl %s16
|
||||
; CHECK-NEXT: vor %v0, (0)1, %v1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vfrmindfst.vvvl(<256 x double> %0, <256 x double> %1, i32 128)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vfrmindfst.vvvl(<256 x double>, <256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vfrmindlst_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vfrmindlst_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vfrmin.d.lst %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vfrmindlst.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vfrmindlst.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vfrmindlst_vvvl(<256 x double> %0, <256 x double> %1) {
|
||||
; CHECK-LABEL: vfrmindlst_vvvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 128
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vfrmin.d.lst %v1, %v0
|
||||
; CHECK-NEXT: lea %s16, 256
|
||||
; CHECK-NEXT: lvl %s16
|
||||
; CHECK-NEXT: vor %v0, (0)1, %v1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vfrmindlst.vvvl(<256 x double> %0, <256 x double> %1, i32 128)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vfrmindlst.vvvl(<256 x double>, <256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vfrminsfst_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vfrminsfst_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vfrmin.s.fst %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vfrminsfst.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vfrminsfst.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vfrminsfst_vvvl(<256 x double> %0, <256 x double> %1) {
|
||||
; CHECK-LABEL: vfrminsfst_vvvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 128
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vfrmin.s.fst %v1, %v0
|
||||
; CHECK-NEXT: lea %s16, 256
|
||||
; CHECK-NEXT: lvl %s16
|
||||
; CHECK-NEXT: vor %v0, (0)1, %v1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vfrminsfst.vvvl(<256 x double> %0, <256 x double> %1, i32 128)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vfrminsfst.vvvl(<256 x double>, <256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vfrminslst_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vfrminslst_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vfrmin.s.lst %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vfrminslst.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vfrminslst.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vfrminslst_vvvl(<256 x double> %0, <256 x double> %1) {
|
||||
; CHECK-LABEL: vfrminslst_vvvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 128
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vfrmin.s.lst %v1, %v0
|
||||
; CHECK-NEXT: lea %s16, 256
|
||||
; CHECK-NEXT: lvl %s16
|
||||
; CHECK-NEXT: vor %v0, (0)1, %v1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vfrminslst.vvvl(<256 x double> %0, <256 x double> %1, i32 128)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vfrminslst.vvvl(<256 x double>, <256 x double>, i32)
|
36
llvm/test/CodeGen/VE/VELIntrinsics/vrand.ll
Normal file
36
llvm/test/CodeGen/VE/VELIntrinsics/vrand.ll
Normal file
@ -0,0 +1,36 @@
|
||||
; RUN: llc < %s -mtriple=ve -mattr=+vpu | FileCheck %s
|
||||
|
||||
;;; Test vector reduction and intrinsic instructions
|
||||
;;;
|
||||
;;; Note:
|
||||
;;; We test VRAND*vl and VRAND*vml instructions.
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrand_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vrand_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrand %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vrand.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrand.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrand_vvml(<256 x double> %0, <256 x i1> %1) {
|
||||
; CHECK-LABEL: vrand_vvml:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrand %v0, %v0, %vm1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vrand.vvml(<256 x double> %0, <256 x i1> %1, i32 256)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrand.vvml(<256 x double>, <256 x i1>, i32)
|
204
llvm/test/CodeGen/VE/VELIntrinsics/vrmax.ll
Normal file
204
llvm/test/CodeGen/VE/VELIntrinsics/vrmax.ll
Normal file
@ -0,0 +1,204 @@
|
||||
; RUN: llc < %s -mtriple=ve -mattr=+vpu | FileCheck %s
|
||||
|
||||
;;; Test vector maximum intrinsic instructions
|
||||
;;;
|
||||
;;; Note:
|
||||
;;; We test VRMAX*vl and VRMAX*vl_v instructions.
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrmaxswfstsx_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vrmaxswfstsx_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmaxs.w.fst.sx %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vrmaxswfstsx.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrmaxswfstsx.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrmaxswfstsx_vvvl(<256 x double> %0, <256 x double> %1) {
|
||||
; CHECK-LABEL: vrmaxswfstsx_vvvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 128
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmaxs.w.fst.sx %v1, %v0
|
||||
; CHECK-NEXT: lea %s16, 256
|
||||
; CHECK-NEXT: lvl %s16
|
||||
; CHECK-NEXT: vor %v0, (0)1, %v1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vrmaxswfstsx.vvvl(<256 x double> %0, <256 x double> %1, i32 128)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrmaxswfstsx.vvvl(<256 x double>, <256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrmaxswlstsx_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vrmaxswlstsx_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmaxs.w.lst.sx %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vrmaxswlstsx.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrmaxswlstsx.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrmaxswlstsx_vvvl(<256 x double> %0, <256 x double> %1) {
|
||||
; CHECK-LABEL: vrmaxswlstsx_vvvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 128
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmaxs.w.lst.sx %v1, %v0
|
||||
; CHECK-NEXT: lea %s16, 256
|
||||
; CHECK-NEXT: lvl %s16
|
||||
; CHECK-NEXT: vor %v0, (0)1, %v1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vrmaxswlstsx.vvvl(<256 x double> %0, <256 x double> %1, i32 128)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrmaxswlstsx.vvvl(<256 x double>, <256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrmaxswfstzx_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vrmaxswfstzx_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmaxs.w.fst.zx %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vrmaxswfstzx.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrmaxswfstzx.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrmaxswfstzx_vvvl(<256 x double> %0, <256 x double> %1) {
|
||||
; CHECK-LABEL: vrmaxswfstzx_vvvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 128
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmaxs.w.fst.zx %v1, %v0
|
||||
; CHECK-NEXT: lea %s16, 256
|
||||
; CHECK-NEXT: lvl %s16
|
||||
; CHECK-NEXT: vor %v0, (0)1, %v1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vrmaxswfstzx.vvvl(<256 x double> %0, <256 x double> %1, i32 128)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrmaxswfstzx.vvvl(<256 x double>, <256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrmaxswlstzx_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vrmaxswlstzx_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmaxs.w.lst.zx %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vrmaxswlstzx.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrmaxswlstzx.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrmaxswlstzx_vvvl(<256 x double> %0, <256 x double> %1) {
|
||||
; CHECK-LABEL: vrmaxswlstzx_vvvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 128
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmaxs.w.lst.zx %v1, %v0
|
||||
; CHECK-NEXT: lea %s16, 256
|
||||
; CHECK-NEXT: lvl %s16
|
||||
; CHECK-NEXT: vor %v0, (0)1, %v1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vrmaxswlstzx.vvvl(<256 x double> %0, <256 x double> %1, i32 128)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrmaxswlstzx.vvvl(<256 x double>, <256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrmaxslfst_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vrmaxslfst_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmaxs.l.fst %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vrmaxslfst.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrmaxslfst.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrmaxslfst_vvvl(<256 x double> %0, <256 x double> %1) {
|
||||
; CHECK-LABEL: vrmaxslfst_vvvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 128
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmaxs.l.fst %v1, %v0
|
||||
; CHECK-NEXT: lea %s16, 256
|
||||
; CHECK-NEXT: lvl %s16
|
||||
; CHECK-NEXT: vor %v0, (0)1, %v1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vrmaxslfst.vvvl(<256 x double> %0, <256 x double> %1, i32 128)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrmaxslfst.vvvl(<256 x double>, <256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrmaxsllst_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vrmaxsllst_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmaxs.l.lst %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vrmaxsllst.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrmaxsllst.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrmaxsllst_vvvl(<256 x double> %0, <256 x double> %1) {
|
||||
; CHECK-LABEL: vrmaxsllst_vvvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 128
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmaxs.l.lst %v1, %v0
|
||||
; CHECK-NEXT: lea %s16, 256
|
||||
; CHECK-NEXT: lvl %s16
|
||||
; CHECK-NEXT: vor %v0, (0)1, %v1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vrmaxsllst.vvvl(<256 x double> %0, <256 x double> %1, i32 128)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrmaxsllst.vvvl(<256 x double>, <256 x double>, i32)
|
204
llvm/test/CodeGen/VE/VELIntrinsics/vrmin.ll
Normal file
204
llvm/test/CodeGen/VE/VELIntrinsics/vrmin.ll
Normal file
@ -0,0 +1,204 @@
|
||||
; RUN: llc < %s -mtriple=ve -mattr=+vpu | FileCheck %s
|
||||
|
||||
;;; Test vector minimum intrinsic instructions
|
||||
;;;
|
||||
;;; Note:
|
||||
;;; We test VRMIN*vl and VRMIN*vl_v instructions.
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrminswfstsx_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vrminswfstsx_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmins.w.fst.sx %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vrminswfstsx.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrminswfstsx.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrminswfstsx_vvvl(<256 x double> %0, <256 x double> %1) {
|
||||
; CHECK-LABEL: vrminswfstsx_vvvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 128
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmins.w.fst.sx %v1, %v0
|
||||
; CHECK-NEXT: lea %s16, 256
|
||||
; CHECK-NEXT: lvl %s16
|
||||
; CHECK-NEXT: vor %v0, (0)1, %v1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vrminswfstsx.vvvl(<256 x double> %0, <256 x double> %1, i32 128)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrminswfstsx.vvvl(<256 x double>, <256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrminswlstsx_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vrminswlstsx_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmins.w.lst.sx %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vrminswlstsx.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrminswlstsx.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrminswlstsx_vvvl(<256 x double> %0, <256 x double> %1) {
|
||||
; CHECK-LABEL: vrminswlstsx_vvvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 128
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmins.w.lst.sx %v1, %v0
|
||||
; CHECK-NEXT: lea %s16, 256
|
||||
; CHECK-NEXT: lvl %s16
|
||||
; CHECK-NEXT: vor %v0, (0)1, %v1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vrminswlstsx.vvvl(<256 x double> %0, <256 x double> %1, i32 128)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrminswlstsx.vvvl(<256 x double>, <256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrminswfstzx_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vrminswfstzx_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmins.w.fst.zx %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vrminswfstzx.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrminswfstzx.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrminswfstzx_vvvl(<256 x double> %0, <256 x double> %1) {
|
||||
; CHECK-LABEL: vrminswfstzx_vvvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 128
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmins.w.fst.zx %v1, %v0
|
||||
; CHECK-NEXT: lea %s16, 256
|
||||
; CHECK-NEXT: lvl %s16
|
||||
; CHECK-NEXT: vor %v0, (0)1, %v1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vrminswfstzx.vvvl(<256 x double> %0, <256 x double> %1, i32 128)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrminswfstzx.vvvl(<256 x double>, <256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrminswlstzx_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vrminswlstzx_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmins.w.lst.zx %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vrminswlstzx.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrminswlstzx.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrminswlstzx_vvvl(<256 x double> %0, <256 x double> %1) {
|
||||
; CHECK-LABEL: vrminswlstzx_vvvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 128
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmins.w.lst.zx %v1, %v0
|
||||
; CHECK-NEXT: lea %s16, 256
|
||||
; CHECK-NEXT: lvl %s16
|
||||
; CHECK-NEXT: vor %v0, (0)1, %v1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vrminswlstzx.vvvl(<256 x double> %0, <256 x double> %1, i32 128)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrminswlstzx.vvvl(<256 x double>, <256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrminslfst_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vrminslfst_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmins.l.fst %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vrminslfst.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrminslfst.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrminslfst_vvvl(<256 x double> %0, <256 x double> %1) {
|
||||
; CHECK-LABEL: vrminslfst_vvvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 128
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmins.l.fst %v1, %v0
|
||||
; CHECK-NEXT: lea %s16, 256
|
||||
; CHECK-NEXT: lvl %s16
|
||||
; CHECK-NEXT: vor %v0, (0)1, %v1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vrminslfst.vvvl(<256 x double> %0, <256 x double> %1, i32 128)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrminslfst.vvvl(<256 x double>, <256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrminsllst_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vrminsllst_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmins.l.lst %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vrminsllst.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrminsllst.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrminsllst_vvvl(<256 x double> %0, <256 x double> %1) {
|
||||
; CHECK-LABEL: vrminsllst_vvvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 128
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrmins.l.lst %v1, %v0
|
||||
; CHECK-NEXT: lea %s16, 256
|
||||
; CHECK-NEXT: lvl %s16
|
||||
; CHECK-NEXT: vor %v0, (0)1, %v1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vrminsllst.vvvl(<256 x double> %0, <256 x double> %1, i32 128)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrminsllst.vvvl(<256 x double>, <256 x double>, i32)
|
36
llvm/test/CodeGen/VE/VELIntrinsics/vror.ll
Normal file
36
llvm/test/CodeGen/VE/VELIntrinsics/vror.ll
Normal file
@ -0,0 +1,36 @@
|
||||
; RUN: llc < %s -mtriple=ve -mattr=+vpu | FileCheck %s
|
||||
|
||||
;;; Test vector reduction or intrinsic instructions
|
||||
;;;
|
||||
;;; Note:
|
||||
;;; We test VROR*vl and VROR*vml instructions.
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vror_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vror_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vror %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vror.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vror.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vror_vvml(<256 x double> %0, <256 x i1> %1) {
|
||||
; CHECK-LABEL: vror_vvml:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vror %v0, %v0, %vm1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vror.vvml(<256 x double> %0, <256 x i1> %1, i32 256)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vror.vvml(<256 x double>, <256 x i1>, i32)
|
36
llvm/test/CodeGen/VE/VELIntrinsics/vrxor.ll
Normal file
36
llvm/test/CodeGen/VE/VELIntrinsics/vrxor.ll
Normal file
@ -0,0 +1,36 @@
|
||||
; RUN: llc < %s -mtriple=ve -mattr=+vpu | FileCheck %s
|
||||
|
||||
;;; Test vector reduction exclusive or intrinsic instructions
|
||||
;;;
|
||||
;;; Note:
|
||||
;;; We test VRXOR*vl and VRXOR*vml instructions.
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrxor_vvl(<256 x double> %0) {
|
||||
; CHECK-LABEL: vrxor_vvl:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrxor %v0, %v0
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%2 = tail call fast <256 x double> @llvm.ve.vl.vrxor.vvl(<256 x double> %0, i32 256)
|
||||
ret <256 x double> %2
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrxor.vvl(<256 x double>, i32)
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
define fastcc <256 x double> @vrxor_vvml(<256 x double> %0, <256 x i1> %1) {
|
||||
; CHECK-LABEL: vrxor_vvml:
|
||||
; CHECK: # %bb.0:
|
||||
; CHECK-NEXT: lea %s0, 256
|
||||
; CHECK-NEXT: lvl %s0
|
||||
; CHECK-NEXT: vrxor %v0, %v0, %vm1
|
||||
; CHECK-NEXT: b.l.t (, %s10)
|
||||
%3 = tail call fast <256 x double> @llvm.ve.vl.vrxor.vvml(<256 x double> %0, <256 x i1> %1, i32 256)
|
||||
ret <256 x double> %3
|
||||
}
|
||||
|
||||
; Function Attrs: nounwind readnone
|
||||
declare <256 x double> @llvm.ve.vl.vrxor.vvml(<256 x double>, <256 x i1>, i32)
|
Loading…
x
Reference in New Issue
Block a user