From 6d45b8c385572241578689992cd8336b34ae2b44 Mon Sep 17 00:00:00 2001 From: Hao Liu Date: Fri, 31 Oct 2014 02:41:37 +0000 Subject: [PATCH] [AArch64]Add 2 intrinsics vmov_n_p64/vmovq_n_p64, the alias for vdup_n_p64/vdup_n_p64. As this change is too small, commit it directly. llvm-svn: 220946 --- clang/include/clang/Basic/arm_neon.td | 2 +- clang/test/CodeGen/aarch64-poly64.c | 12 ++++++++++++ 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/clang/include/clang/Basic/arm_neon.td b/clang/include/clang/Basic/arm_neon.td index ce3b609..933f204 100644 --- a/clang/include/clang/Basic/arm_neon.td +++ b/clang/include/clang/Basic/arm_neon.td @@ -1077,7 +1077,7 @@ def VDUP_LANE2: WOpInst<"vdup_laneq", "dji", "csilUcUsUiUlPcPshfdQcQsQiQlQPcQPsQUcQUsQUiQUlQhQfQdPlQPl", OP_DUP_LN>; def DUP_N : WOpInst<"vdup_n", "ds", "dQdPlQPl", OP_DUP>; -def MOV_N : WOpInst<"vmov_n", "ds", "dQd", OP_DUP>; +def MOV_N : WOpInst<"vmov_n", "ds", "dQdPlQPl", OP_DUP>; //////////////////////////////////////////////////////////////////////////////// def COMBINE : NoTestOpInst<"vcombine", "kdd", "dPl", OP_CONC>; diff --git a/clang/test/CodeGen/aarch64-poly64.c b/clang/test/CodeGen/aarch64-poly64.c index 290cc69..a14162c 100644 --- a/clang/test/CodeGen/aarch64-poly64.c +++ b/clang/test/CodeGen/aarch64-poly64.c @@ -102,6 +102,18 @@ poly64x2_t test_vdupq_n_p64(poly64_t a) { // CHECK: dup {{v[0-9]+}}.2d, {{x[0-9]+}} } +poly64x1_t test_vmov_n_p64(poly64_t a) { + // CHECK-LABEL: test_vmov_n_p64 + return vmov_n_p64(a); + // CHECK: fmov {{d[0-9]+}}, {{x[0-9]+}} +} + +poly64x2_t test_vmovq_n_p64(poly64_t a) { + // CHECK-LABEL: test_vmovq_n_p64 + return vmovq_n_p64(a); + // CHECK: dup {{v[0-9]+}}.2d, {{x[0-9]+}} +} + poly64x1_t test_vdup_lane_p64(poly64x1_t vec) { // CHECK-LABEL: test_vdup_lane_p64 return vdup_lane_p64(vec, 0); -- 2.7.4