From 9ac17104b80f4a6fae6b093aba36d00627be6df1 Mon Sep 17 00:00:00 2001 From: MerryMage Date: Sat, 20 Jun 2020 00:12:09 +0100 Subject: [PATCH] arm: Add missing file vec_internal.h Missing from commit 1df7314dc3d2acbc827841599ec95ce8b35712ff. Ported from qemu a04b68e1d4c4f0cd5cd7542697b1b230b84532f5. --- qemu/target/arm/vec_internal.h | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 qemu/target/arm/vec_internal.h diff --git a/qemu/target/arm/vec_internal.h b/qemu/target/arm/vec_internal.h new file mode 100644 index 00000000..00a82777 --- /dev/null +++ b/qemu/target/arm/vec_internal.h @@ -0,0 +1,33 @@ +/* + * ARM AdvSIMD / SVE Vector Helpers + * + * Copyright (c) 2020 Linaro + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, see . + */ + +#ifndef TARGET_ARM_VEC_INTERNALS_H +#define TARGET_ARM_VEC_INTERNALS_H + +static inline void clear_tail(void *vd, uintptr_t opr_sz, uintptr_t max_sz) +{ + uint64_t *d = vd + opr_sz; + uintptr_t i; + + for (i = opr_sz; i < max_sz; i += 8) { + *d++ = 0; + } +} + +#endif /* TARGET_ARM_VEC_INTERNALS_H */