Add Vector Compare Greater-Than
This commit is contained in:
parent
e2b5a6b3bc
commit
a1995d3973
2 changed files with 46 additions and 0 deletions
|
|
@ -4,9 +4,11 @@
|
|||
"llvm_prefix": "llvm.ppc.altivec.",
|
||||
"number_info": {
|
||||
"unsigned": {
|
||||
"kind" : "u",
|
||||
"data_type_short": { "8": "b", "16": "h", "32": "w", "64": "d" }
|
||||
},
|
||||
"signed": {
|
||||
"kind" : "s",
|
||||
"data_type_short": { "8": "b", "16": "h", "32": "w", "64": "d" }
|
||||
},
|
||||
"float": {}
|
||||
|
|
@ -42,6 +44,20 @@
|
|||
"llvm": "vcmpequ{0.data_type_short}",
|
||||
"ret": "s(8-32)",
|
||||
"args": ["0", "0"]
|
||||
},
|
||||
{
|
||||
"intrinsic": "cmpgt{1.kind}{1.data_type_short}",
|
||||
"width": [128],
|
||||
"llvm": "vcmpgt{1.kind}{1.data_type_short}",
|
||||
"ret": "s(8-32)",
|
||||
"args": ["0u", "1"]
|
||||
},
|
||||
{
|
||||
"intrinsic": "cmpgt{1.kind}{1.data_type_short}",
|
||||
"width": [128],
|
||||
"llvm": "vcmpgt{1.kind}{1.data_type_short}",
|
||||
"ret": "s(8-32)",
|
||||
"args": ["0", "1"]
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -52,6 +52,36 @@ pub fn find(name: &str) -> Option<Intrinsic> {
|
|||
output: &::I32x4,
|
||||
definition: Named("llvm.ppc.altivec.vcmpequw")
|
||||
},
|
||||
"_vec_cmpgtub" => Intrinsic {
|
||||
inputs: { static INPUTS: [&'static Type; 2] = [&::U8x16, &::U8x16]; &INPUTS },
|
||||
output: &::I8x16,
|
||||
definition: Named("llvm.ppc.altivec.vcmpgtub")
|
||||
},
|
||||
"_vec_cmpgtuh" => Intrinsic {
|
||||
inputs: { static INPUTS: [&'static Type; 2] = [&::U16x8, &::U16x8]; &INPUTS },
|
||||
output: &::I16x8,
|
||||
definition: Named("llvm.ppc.altivec.vcmpgtuh")
|
||||
},
|
||||
"_vec_cmpgtuw" => Intrinsic {
|
||||
inputs: { static INPUTS: [&'static Type; 2] = [&::U32x4, &::U32x4]; &INPUTS },
|
||||
output: &::I32x4,
|
||||
definition: Named("llvm.ppc.altivec.vcmpgtuw")
|
||||
},
|
||||
"_vec_cmpgtsb" => Intrinsic {
|
||||
inputs: { static INPUTS: [&'static Type; 2] = [&::I8x16, &::I8x16]; &INPUTS },
|
||||
output: &::I8x16,
|
||||
definition: Named("llvm.ppc.altivec.vcmpgtsb")
|
||||
},
|
||||
"_vec_cmpgtsh" => Intrinsic {
|
||||
inputs: { static INPUTS: [&'static Type; 2] = [&::I16x8, &::I16x8]; &INPUTS },
|
||||
output: &::I16x8,
|
||||
definition: Named("llvm.ppc.altivec.vcmpgtsh")
|
||||
},
|
||||
"_vec_cmpgtsw" => Intrinsic {
|
||||
inputs: { static INPUTS: [&'static Type; 2] = [&::I32x4, &::I32x4]; &INPUTS },
|
||||
output: &::I32x4,
|
||||
definition: Named("llvm.ppc.altivec.vcmpgtsw")
|
||||
},
|
||||
_ => return None,
|
||||
})
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue