Replace use of __alignof__(T) with C11 alignof(T) to improve portability
between toolchains.

Signed-off-by: Tyler Retzlaff <roret...@linux.microsoft.com>
---
 app/test-eventdev/test_order_common.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/app/test-eventdev/test_order_common.c 
b/app/test-eventdev/test_order_common.c
index 6f00f24..a9894c6 100644
--- a/app/test-eventdev/test_order_common.c
+++ b/app/test-eventdev/test_order_common.c
@@ -2,6 +2,8 @@
  * Copyright(c) 2017 Cavium, Inc
  */
 
+#include <stdalign.h>
+
 #include "test_order_common.h"
 
 int
@@ -139,12 +141,12 @@
        static const struct rte_mbuf_dynfield flow_id_dynfield_desc = {
                .name = "test_event_dynfield_flow_id",
                .size = sizeof(flow_id_t),
-               .align = __alignof__(flow_id_t),
+               .align = alignof(flow_id_t),
        };
        static const struct rte_mbuf_dynfield seqn_dynfield_desc = {
                .name = "test_event_dynfield_seqn",
                .size = sizeof(seqn_t),
-               .align = __alignof__(seqn_t),
+               .align = alignof(seqn_t),
        };
 
        test_order = rte_zmalloc_socket(test->name, sizeof(struct test_order),
-- 
1.8.3.1

Reply via email to