[PATCH] D144293: [PowerPC] Fix the implicit casting for the emulated intrinsics
Maryam Moghadas via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Feb 21 13:06:37 PST 2023
maryammo added inline comments.
================
Comment at: clang/lib/Headers/ppc_wrappers/smmintrin.h:310
__charmask = vec_gb(__charmask);
- __v8hu __shortmask = (__v8hu)vec_unpackh(__charmask);
+ __v8hu __shortmask = (__v8hu)vec_unpackh((__v16qi)__charmask);
#ifdef __BIG_ENDIAN__
----------------
amyk wrote:
> Potentially silly question, but is it intentionally for that mask for be signed?
In altivec header, `vec_unpackh` 's parameter is either `signed char` or `bool char`, so we need explicit casting since `__charmask` is `unsigned char`.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D144293/new/
https://reviews.llvm.org/D144293
More information about the cfe-commits
mailing list