> -----Original Message-----
> From: Pai G, Sunil <[email protected]>
> Sent: Thursday 23 June 2022 08:01
> To: [email protected]
> Cc: [email protected]; Finn, Emma <[email protected]>; Van Haaren, Harry
> <[email protected]>; Ferriter, Cian <[email protected]>
> Subject: [PATCH] dpif-netdev: Simplify AVX512 build time checks to enhance 
> readability.
> 
> The preprocessor comparison string to check AVX512 capabilities are
> lengthy and effecting user readability. Simpify this by aliasing the checks.
> 
> Suggested-by: Eelco Chaudron <[email protected]>
> Signed-off-by: Sunil Pai G <[email protected]>
> ---
>  lib/dpif-netdev-private-dpif.c    |  6 ++++--
>  lib/dpif-netdev-private-extract.c |  3 +--
>  lib/dpif-netdev-private-extract.h | 10 +++++-----
>  3 files changed, 10 insertions(+), 9 deletions(-)
> 

I looked to see if we could apply the simplification done below for DPIF and 
MFEX to the DPCLS code, but I can see that the AVX512 build checks are only 
performed in one place for the DPCLS, so it doesn't make sense to do it for 
DPCLS. I guess if there are more places to perform the DPCLS AVX512 build 
checks in the future, then we can add a similar alias. For now what you've done 
makes sense.

<snip actual diff away>

All the changes LGTM. I also tested on the usual GCC 4.8, 4.9, 5 and 9 to test 
with all the different AVX512 ISA generating capabilities present and not. This 
all still works as expected.

Thanks for making the code better here Sunil.

Acked-by: Cian Ferriter <[email protected]>
_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev

Reply via email to