efriedma updated this revision to Diff 224496. Repository: rC Clang
CHANGES SINCE LAST ACTION https://reviews.llvm.org/D68838/new/ https://reviews.llvm.org/D68838 Files: test/CodeGen/aarch64-v8.2a-neon-intrinsics.c utils/TableGen/NeonEmitter.cpp Index: utils/TableGen/NeonEmitter.cpp =================================================================== --- utils/TableGen/NeonEmitter.cpp +++ utils/TableGen/NeonEmitter.cpp @@ -1442,7 +1442,8 @@ } // Check if an explicit cast is needed. - if (CastToType.isVector() && LocalCK == ClassB) { + if (CastToType.isVector() && + (LocalCK == ClassB || (T.isHalf() && !T.isScalarForMangling()))) { CastToType.makeInteger(8, true); Arg = "(" + CastToType.str() + ")" + Arg; } else if (CastToType.isVector() && LocalCK == ClassI) { Index: test/CodeGen/aarch64-v8.2a-neon-intrinsics.c =================================================================== --- test/CodeGen/aarch64-v8.2a-neon-intrinsics.c +++ test/CodeGen/aarch64-v8.2a-neon-intrinsics.c @@ -1,5 +1,5 @@ // RUN: %clang_cc1 -triple arm64-none-linux-gnu -target-feature +neon -target-feature +fullfp16 -target-feature +v8.2a\ -// RUN: -fallow-half-arguments-and-returns -S -disable-O0-optnone -emit-llvm -o - %s \ +// RUN: -fallow-half-arguments-and-returns -flax-vector-conversions=none -S -disable-O0-optnone -emit-llvm -o - %s \ // RUN: | opt -S -mem2reg \ // RUN: | FileCheck %s
Index: utils/TableGen/NeonEmitter.cpp =================================================================== --- utils/TableGen/NeonEmitter.cpp +++ utils/TableGen/NeonEmitter.cpp @@ -1442,7 +1442,8 @@ } // Check if an explicit cast is needed. - if (CastToType.isVector() && LocalCK == ClassB) { + if (CastToType.isVector() && + (LocalCK == ClassB || (T.isHalf() && !T.isScalarForMangling()))) { CastToType.makeInteger(8, true); Arg = "(" + CastToType.str() + ")" + Arg; } else if (CastToType.isVector() && LocalCK == ClassI) { Index: test/CodeGen/aarch64-v8.2a-neon-intrinsics.c =================================================================== --- test/CodeGen/aarch64-v8.2a-neon-intrinsics.c +++ test/CodeGen/aarch64-v8.2a-neon-intrinsics.c @@ -1,5 +1,5 @@ // RUN: %clang_cc1 -triple arm64-none-linux-gnu -target-feature +neon -target-feature +fullfp16 -target-feature +v8.2a\ -// RUN: -fallow-half-arguments-and-returns -S -disable-O0-optnone -emit-llvm -o - %s \ +// RUN: -fallow-half-arguments-and-returns -flax-vector-conversions=none -S -disable-O0-optnone -emit-llvm -o - %s \ // RUN: | opt -S -mem2reg \ // RUN: | FileCheck %s
_______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits