Add support for Vector Sum Saturated on PowerPC

This commit is contained in:
Luca Barbato 2017-08-04 00:19:58 +00:00
parent eec1c178b3
commit c3041e8b9e
2 changed files with 12 additions and 0 deletions

View File

@ -212,6 +212,13 @@
"llvm": "vsum4shs", "llvm": "vsum4shs",
"ret": "s32", "ret": "s32",
"args": ["0N", "0"] "args": ["0N", "0"]
},
{
"intrinsic": "sums",
"width": [128],
"llvm": "vsumsws",
"ret": "s32",
"args": ["0", "0"]
} }
] ]
} }

View File

@ -392,6 +392,11 @@ pub fn find(name: &str) -> Option<Intrinsic> {
output: &::I32x4, output: &::I32x4,
definition: Named("llvm.ppc.altivec.vsum4shs") definition: Named("llvm.ppc.altivec.vsum4shs")
}, },
"_vec_sums" => Intrinsic {
inputs: { static INPUTS: [&'static Type; 2] = [&::I32x4, &::I32x4]; &INPUTS },
output: &::I32x4,
definition: Named("llvm.ppc.altivec.vsumsws")
},
_ => return None, _ => return None,
}) })
} }