[dpdk-dev] [PATCH] net/mlx5: restrict workaround of gcc AVX512F bug
Jerin Jacob
jerin.jacob at caviumnetworks.com
Tue Nov 13 06:12:23 CET 2018
-----Original Message-----
> Date: Tue, 13 Nov 2018 01:01:22 +0100
> From: Thomas Monjalon <thomas at monjalon.net>
> To: dev at dpdk.org
> Cc: yskoh at mellanox.com, shahafs at mellanox.com, ferruh.yigit at intel.com,
> bruce.richardson at intel.com, konstantin.ananyev at intel.com,
> christian.ehrhardt at canonical.com, justin.parus at microsoft.com
> Subject: [dpdk-dev] [PATCH] net/mlx5: restrict workaround of gcc AVX512F bug
> X-Mailer: git-send-email 2.19.0
>
> +/*
> + * GCC bug workaround for rte_memcpy broken when optimized for AVX512.
> + * Details are in https://bugs.dpdk.org/show_bug.cgi?id=97
> + * AVX512F is disabled for affected functions (calling mlx5_tx_complete).
> + */
> +#if defined(__clang__) || defined(__INTEL_COMPILER)
Probably you need to add check here for non x86 as no-avx512f valid only
for x86.
➜ [ctest] $ cat target.c
void __attribute__((target("no-avx512f"))) test_fn(void)
{
}
int main(void)
{
test_fn();
}
➜ [ctest] $ aarch64-linux-gnu-gcc -Wall target.c
target.c:5:1: error: pragma or attribute 'target("no-avx512f")' is not
valid
{
^
➜ [ctest] $ gcc -Wall target.c
➜ [ctest] $
> +#define MLX5_WORKAROUND_GCC_BUG_AVX512F
> +#else
> +#define MLX5_WORKAROUND_GCC_BUG_AVX512F __attribute__((target("no-avx512f")))
> +#endif
> +
More information about the dev
mailing list