DPDK patches and discussions
 help / color / mirror / Atom feed
* [PATCH 0/3] add diagnostics macros to make code portable
@ 2024-12-27  1:33 Andre Muezerie
  2024-12-27  1:33 ` [PATCH 1/3] lib/eal: " Andre Muezerie
                   ` (4 more replies)
  0 siblings, 5 replies; 14+ messages in thread
From: Andre Muezerie @ 2024-12-27  1:33 UTC (permalink / raw)
  Cc: dev, Andre Muezerie

It was a common pattern to have "GCC diagnostic ignored" pragmas
sprinkled over the code and only activate these pragmas for certain
compilers (gcc and clang). Clang supports GCCΓÇÖs pragma for
compatibility with existing source code, so #pragma GCC diagnostic
and #pragma clang diagnostic are synonyms for Clang
(https://clang.llvm.org/docs/UsersManual.html).

Now that effort is being made to make the code compatible with MSVC
these expressions would become more complex. It makes sense to hide
this complexity behind macros. This makes maintenance easier as these
macros are defined in a single place. As a plus the code becomes
more readable as well.

Andre Muezerie (3):
  lib/eal: add diagnostics macros to make code portable
  drivers/common: add diagnostics macros to make code portable
  drivers/net: add diagnostics macros to make code portable

 drivers/common/idpf/idpf_common_rxtx_avx512.c |  4 +--
 drivers/net/axgbe/axgbe_rxtx.h                | 12 +++----
 drivers/net/cpfl/cpfl_rxtx_vec_common.h       |  4 +--
 drivers/net/dpaa2/dpaa2_rxtx.c                | 15 ++------
 drivers/net/fm10k/fm10k_rxtx_vec.c            |  4 +--
 drivers/net/hns3/hns3_rxtx_vec_neon.h         |  2 +-
 .../net/i40e/i40e_recycle_mbufs_vec_common.c  |  2 +-
 drivers/net/i40e/i40e_rxtx_common_avx.h       |  4 +--
 drivers/net/i40e/i40e_rxtx_vec_altivec.c      |  2 +-
 drivers/net/i40e/i40e_rxtx_vec_avx2.c         |  4 +--
 drivers/net/i40e/i40e_rxtx_vec_avx512.c       |  4 +--
 drivers/net/i40e/i40e_rxtx_vec_common.h       |  4 +--
 drivers/net/i40e/i40e_rxtx_vec_neon.c         |  3 +-
 drivers/net/i40e/i40e_rxtx_vec_sse.c          |  4 +--
 drivers/net/iavf/iavf_rxtx_vec_avx2.c         |  4 +--
 drivers/net/iavf/iavf_rxtx_vec_avx512.c       |  4 +--
 drivers/net/iavf/iavf_rxtx_vec_common.h       |  4 +--
 drivers/net/iavf/iavf_rxtx_vec_sse.c          |  4 +--
 drivers/net/ice/ice_rxtx_common_avx.h         |  4 +--
 drivers/net/ice/ice_rxtx_vec_avx2.c           |  4 +--
 drivers/net/ice/ice_rxtx_vec_avx512.c         |  4 +--
 drivers/net/ice/ice_rxtx_vec_common.h         |  4 +--
 drivers/net/ice/ice_rxtx_vec_sse.c            |  4 +--
 drivers/net/idpf/idpf_rxtx_vec_common.h       |  4 +--
 .../ixgbe/ixgbe_recycle_mbufs_vec_common.c    |  2 +-
 drivers/net/ixgbe/ixgbe_rxtx_vec_neon.c       |  2 +-
 drivers/net/ixgbe/ixgbe_rxtx_vec_sse.c        |  4 +--
 drivers/net/mlx5/mlx5_flow.c                  |  6 ++--
 drivers/net/mlx5/mlx5_rxtx_vec_altivec.h      |  6 ++--
 drivers/net/mlx5/mlx5_rxtx_vec_neon.h         |  2 +-
 drivers/net/mlx5/mlx5_rxtx_vec_sse.h          |  4 +--
 drivers/net/tap/tap_flow.c                    |  6 ++--
 drivers/net/virtio/virtio_rxtx_simple.c       |  4 +--
 lib/eal/include/rte_common.h                  | 34 +++++++++++++++++++
 34 files changed, 77 insertions(+), 101 deletions(-)

--
2.47.0.vfs.0.3


^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2024-12-28  3:19 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-12-27  1:33 [PATCH 0/3] add diagnostics macros to make code portable Andre Muezerie
2024-12-27  1:33 ` [PATCH 1/3] lib/eal: " Andre Muezerie
2024-12-27  1:33 ` [PATCH 2/3] drivers/common: " Andre Muezerie
2024-12-27 17:57   ` Stephen Hemminger
2024-12-27 19:43     ` Andre Muezerie
2024-12-27  1:33 ` [PATCH 3/3] drivers/net: " Andre Muezerie
2024-12-28  0:45 ` [PATCH v2 0/3] " Andre Muezerie
2024-12-28  0:45   ` [PATCH v2 1/3] lib/eal: " Andre Muezerie
2024-12-28  0:45   ` [PATCH v2 2/3] drivers/common: " Andre Muezerie
2024-12-28  0:45   ` [PATCH v2 3/3] drivers/net: " Andre Muezerie
2024-12-28  3:18 ` [PATCH v3 0/3] " Andre Muezerie
2024-12-28  3:18   ` [PATCH v3 1/3] lib/eal: " Andre Muezerie
2024-12-28  3:18   ` [PATCH v3 2/3] drivers/common: " Andre Muezerie
2024-12-28  3:18   ` [PATCH v3 3/3] drivers/net: " Andre Muezerie

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).