[PATCH] D95135: Fix signedness in vector bitcast evaluation
Sven van Haastregt via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Jan 21 07:40:39 PST 2021
svenvh added inline comments.
================
Comment at: clang/test/CodeGenOpenCL/vector_literals.cl:71
+ // CHECK: extractelement <2 x i32> %{{[0-9]+}}, i64 0
+ unsigned int withCast = ((int2)((int2)(12, 34))).s0;
+}
----------------
Anastasia wrote:
> I wonder if both `(int2)` are needed i.e. the cast one could be ommitted?
The cast is actually necessary, because the fix is in the code that handles the cast (`case CK_BitCast` if you expand the code above my change).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D95135/new/
https://reviews.llvm.org/D95135
More information about the cfe-commits
mailing list