From: Tim Northover Date: Tue, 12 Jul 2016 17:38:50 +0000 (+0000) Subject: AArch64: fix return type of vqmovun_high_*. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=1cda5f1160423a020d8b39539344d088c0d5c900;p=clang AArch64: fix return type of vqmovun_high_*. These should be returning an unsigned quantity. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@275195 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/clang/Basic/arm_neon.td b/include/clang/Basic/arm_neon.td index 44325fde9f..5605fc6de2 100644 --- a/include/clang/Basic/arm_neon.td +++ b/include/clang/Basic/arm_neon.td @@ -967,7 +967,7 @@ def XTN2 : SOpInst<"vmovn_high", "qhk", "silUsUiUl", OP_XTN>; //////////////////////////////////////////////////////////////////////////////// // Signed integer saturating extract and unsigned narrow to high -def SQXTUN2 : SOpInst<"vqmovun_high", "qhk", "sil", OP_SQXTUN>; +def SQXTUN2 : SOpInst<"vqmovun_high", "emd", "HsHiHl", OP_SQXTUN>; //////////////////////////////////////////////////////////////////////////////// // Integer saturating extract and narrow to high diff --git a/test/Sema/arm64-neon-header.c b/test/Sema/arm64-neon-header.c new file mode 100644 index 0000000000..0ae082113a --- /dev/null +++ b/test/Sema/arm64-neon-header.c @@ -0,0 +1,7 @@ +// RUN: %clang_cc1 -triple arm64-apple-darwin -target-feature +neon -Wvector-conversion -fsyntax-only -ffreestanding -verify %s + +#include + +int16x8_t foo(int8x8_t p0, int16x8_t p1) { + return vqmovun_high_s16(p0, p1); // expected-warning {{incompatible vector types returning 'uint8x16_t'}} +}