aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/acl.am
diff options
context:
space:
mode:
authorAndrew Yourtchenko <ayourtch@gmail.com>2018-05-18 18:48:00 +0200
committerDamjan Marion <dmarion.lists@gmail.com>2018-05-22 17:39:07 +0000
commit3e0ee6ec3ce1d3f32c1faca7514048e55412220e (patch)
tree9bc2e1a1cfd74a3c7f0b7422fc889e65e7e8c794 /src/plugins/acl.am
parent14864770be4068b34ffc1124f47f5e9fe2a929d2 (diff)
acl-plugin: refactor to introduce multiarch dataplane functions
This commit splits the functions from fa_node.c into the pure dataplane node functions (which are multiarch-compiled), session management node functions (which are compiled only once), and session find/add/delete functions which are split out into the inlines. As part of the refactoring: - get rid of BV() macros in the affected chunk of code, rather use the explicit bihash function names. - add the magic trailer to the new files to ensure make checkstyle watches them. - move the bihash_template.c include for 40_8 bihash into acl.c Change-Id: I4d781e9ec4307ea84e92af93c09470ea2bd0c375 Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
Diffstat (limited to 'src/plugins/acl.am')
-rw-r--r--src/plugins/acl.am40
1 files changed, 39 insertions, 1 deletions
diff --git a/src/plugins/acl.am b/src/plugins/acl.am
index b67191ec938..7d723402615 100644
--- a/src/plugins/acl.am
+++ b/src/plugins/acl.am
@@ -14,17 +14,55 @@
vppapitestplugins_LTLIBRARIES += acl_test_plugin.la
vppplugins_LTLIBRARIES += acl_plugin.la
+acl_plugin_la_LDFLAGS = $(AM_LDFLAGS)
+acl_plugin_la_LDFLAGS += -Wl,-lm,-ldl
+
+
+
+acl_plugin_la_LIBADD =
+
acl_plugin_la_SOURCES = \
acl/acl.c \
acl/hash_lookup.c \
acl/lookup_context.c \
- acl/fa_node.c \
+ acl/sess_mgmt_node.c \
+ acl/dataplane_node.c \
acl/l2sess.h \
acl/manual_fns.h \
acl/acl_plugin.api.h
API_FILES += acl/acl.api
+if CPU_X86_64
+acl_multiversioning_files = \
+ acl/dataplane_node.c
+
+
+if CC_SUPPORTS_AVX2
+###############################################################
+# AVX2
+###############################################################
+libacl_plugin_avx2_la_SOURCES = $(acl_multiversioning_files)
+libacl_plugin_avx2_la_CFLAGS = \
+ $(AM_CFLAGS) @CPU_AVX2_FLAGS@ \
+ -DCLIB_MULTIARCH_VARIANT=avx2
+noinst_LTLIBRARIES += libacl_plugin_avx2.la
+acl_plugin_la_LIBADD += libacl_plugin_avx2.la
+endif
+
+if CC_SUPPORTS_AVX512
+###############################################################
+# AVX512
+###############################################################
+libacl_plugin_avx512_la_SOURCES = $(acl_multiversioning_files)
+libacl_plugin_avx512_la_CFLAGS = \
+ $(AM_CFLAGS) @CPU_AVX512_FLAGS@ \
+ -DCLIB_MULTIARCH_VARIANT=avx512
+noinst_LTLIBRARIES += libacl_plugin_avx512.la
+acl_plugin_la_LIBADD += libacl_plugin_avx512.la
+endif
+endif
+
nobase_apiinclude_HEADERS += \
acl/acl_all_api_h.h \
acl/acl_msg_enum.h \