[clang] [llvm] [Arm] Generate explicit bitcasts in NeonEmitter (PR #121802)

Momchil Velikov via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 8 06:56:50 PST 2025


================
@@ -1382,14 +1382,15 @@ void Intrinsic::emitBodyAsBuiltinCall() {
     Type CastToType = T;
 
     // Check if an explicit cast is needed.
-    if (CastToType.isVector() &&
-        (LocalCK == ClassB || (T.isHalf() && !T.isScalarForMangling()))) {
-      CastToType.makeInteger(8, true);
-      Arg = "(" + CastToType.str() + ")" + Arg;
-    } else if (CastToType.isVector() && LocalCK == ClassI) {
-      if (CastToType.isInteger())
-        CastToType.makeSigned();
-      Arg = "(" + CastToType.str() + ")" + Arg;
+    if (CastToType.isVector()) {
----------------
momchil-velikov wrote:

It's an omission. Also the return value cast, it's either redundant or needs to be a bitcast too. Will fix.

https://github.com/llvm/llvm-project/pull/121802


More information about the llvm-commits mailing list