Add support for Vector Multiply Sum Saturated on PowerPC

This commit is contained in:
Luca Barbato 2017-08-04 00:19:58 +00:00
parent 078c3ddbe3
commit cccf3e7a5c
2 changed files with 17 additions and 0 deletions

View File

@ -184,6 +184,13 @@
"llvm": "vmsumshm",
"ret": "s32",
"args": ["s16", "s16", "s32"]
},
{
"intrinsic": "msum{0.kind}hs",
"width": [128],
"llvm": "vmsum{0.kind}hs",
"ret": "i32",
"args": ["0N", "0N", "0"]
}
]
}

View File

@ -362,6 +362,16 @@ pub fn find(name: &str) -> Option<Intrinsic> {
output: &::I32x4,
definition: Named("llvm.ppc.altivec.vmsumshm")
},
"_vec_msumshs" => Intrinsic {
inputs: { static INPUTS: [&'static Type; 3] = [&::I16x8, &::I16x8, &::I32x4]; &INPUTS },
output: &::I32x4,
definition: Named("llvm.ppc.altivec.vmsumshs")
},
"_vec_msumuhs" => Intrinsic {
inputs: { static INPUTS: [&'static Type; 3] = [&::U16x8, &::U16x8, &::U32x4]; &INPUTS },
output: &::U32x4,
definition: Named("llvm.ppc.altivec.vmsumuhs")
},
_ => return None,
})
}