summaryrefslogtreecommitdiffstats
path: root/src/cmake
AgeCommit message (Expand)AuthorFilesLines
2021-09-27misc: move part of vpe apis to vlibmemoryFlorin Coras1-0/+30
2021-08-20build: fix external plugin buildBenoît Ganne1-0/+1
2021-08-18vat2: add shared memory argumentOle Troan1-6/+5
2021-07-27vppinfra: introduce CLIB_CACHE_PREFETCH_BYTESDamjan Marion1-37/+27
2021-07-16build: fix formatting of CMake config outputDamjan Marion1-1/+3
2021-05-27build: kindly ask python not to polute src/Damjan Marion1-4/+4
2021-05-11build: compiler flags handling cleanupDamjan Marion4-3/+8
2021-05-06build: add FORCE_ON option for multiarch variantsDamjan Marion2-4/+24
2021-05-01build: add option to turn off some march variantsDamjan Marion1-41/+81
2021-04-30build: declare some CMake variables as advancedDamjan Marion2-0/+10
2021-04-30misc: experimental configure scriptDamjan Marion1-6/+6
2021-04-18vppinfra: remove linux/syscall.hDamjan Marion1-23/+0
2021-04-02build: create _objs target for each libraryDamjan Marion1-3/+10
2021-02-08misc: support api generated dependency for multiarch sourceOle Troan4-15/+31
2021-01-21avf: use write combining store for queues tail updateRadu Nicolau1-0/+4
2020-12-25build: add plugin dependencies only when presentRuslan Babayev1-1/+3
2020-11-25api: vat2 and json autogeneration for api messagesOle Troan3-2/+57
2020-11-05build: link time optimization for release buildsDamjan Marion1-1/+8
2020-11-05build: run garbage collection while linking pluginsDamjan Marion1-0/+3
2020-10-19misc: don't export symbols from pluginsDamjan Marion1-0/+1
2020-10-15build: forward dependencies to arch-specific libsAloys Augustin3-5/+10
2020-08-27vppinfra: Multiarch support for OCTEONTX2 SoCNitin Saxena1-0/+4
2020-06-19build: add cmake dependency from test plugin to apiTom Seidenberg1-0/+3
2020-06-17build: cmake cross-compilation fixesDamjan Marion1-1/+1
2020-05-08build: various improvementsDamjan Marion4-5/+7
2020-04-30build: rework x86 CPU variantsDamjan Marion1-5/+9
2020-04-30build: support arch-specific compiling for Neoverse N1Lijian.Zhang1-0/+4
2020-04-29build: detect GNU Assembler AVX-512 bug and disable AVX-512 variants if neededDamjan Marion1-4/+24
2020-03-31vlib: move pci api types from vnet/pci to vlib/pciJakub Grajciar1-2/+1
2020-01-27crypto-ia32: add VAES support for AES-CBCDamjan Marion1-0/+1
2019-12-17build: export vapi generation in vpp-devOliver Giles4-10/+84
2019-11-14vcl: Handle newer Glibc (>2.28) where fcntl is actually fcntl64Carl Smith1-0/+9
2019-11-04build: install generated api enum and type headersDave Barach1-0/+2
2019-09-25api: split api generated filesOle Troan2-1/+3
2019-09-05build: fix unsupported CMake comparison operationjialv011-1/+1
2019-08-19build: fix vpp compilation failure on ThunderX2 and AmpJianlin Lv1-1/+1
2019-07-31build: Append build number for cpack packagesYohanPipereau1-31/+32
2019-07-25build: vppapigen search VPP_INCLUDE_DIR if setBenoît Ganne1-2/+8
2019-07-25build: package .api files in vpp-devBenoît Ganne1-1/+1
2019-06-07build: add -Wall and -fno-common, fix reported issuesBenoît Ganne3-3/+1
2019-05-14Build packages for generic Arm architectureLijian.Zhang1-0/+2
2019-03-28cmake: add vpp_plugin_find_library macroDamjan Marion1-0/+9
2019-03-18Fix build with newer linux headersDamjan Marion1-0/+10
2019-02-14Add -fno-common compile optionBenoît Ganne2-2/+2
2019-01-26cmake: add support for linking with DPDK shared libsDamjan Marion1-0/+13
2019-01-25cmake: execute git from src directoryDamjan Marion1-0/+1
2019-01-22cmake: don't set SONAME for pluginsDamjan Marion1-0/+2
2019-01-20Rework of debian packagingDamjan Marion1-2/+1
2019-01-17cmake: initial cross-compilation supportDamjan Marion1-1/+4
2018-11-30API: Add dependency on compiler for API .json and .api generation.Ole Troan1-2/+2
an> rule_index); ASSERT (rp); if (!RT (rule_is_match_for_key) (key, rp)) return MMA_TABLE_INVALID_INDEX; for (i = 0; i < vec_len (rp->next_indices); i++) { rv = RT (mma_rules_table_lookup) (srt, key, rp->next_indices[i]); if (rv != MMA_TABLE_INVALID_INDEX) return (rv); } return (rp->action_index); } u32 RT (mma_rules_table_lookup_rule) (RTT (mma_rules_table) * srt, RTT (mma_mask_or_match) * key, u32 rule_index) { RTT (mma_rule) * rp; u32 rv; int i; ASSERT (rule_index != MMA_TABLE_INVALID_INDEX); rp = RT (mma_rules_table_get_rule) (srt, rule_index); ASSERT (rp); if (!RT (rule_is_match_for_key) (key, rp)) return MMA_TABLE_INVALID_INDEX; for (i = 0; i < vec_len (rp->next_indices); i++) { rv = RT (mma_rules_table_lookup_rule) (srt, key, rp->next_indices[i]); if (rv != MMA_TABLE_INVALID_INDEX) return (rv); } return rule_index; } static RTT (mma_rules_table) * RTT (sort_srt); int RT (mma_sort_indices) (void *e1, void *e2) { u32 *ri1 = e1, *ri2 = e2; RTT (mma_rule) * rule1, *rule2; rule1 = RT (mma_rules_table_get_rule) (RTT (sort_srt), *ri1); rule2 = RT (mma_rules_table_get_rule) (RTT (sort_srt), *ri2); return RTT (sort_srt)->rule_cmp_fn (rule1, rule2); } void RT (mma_sort) (RTT (mma_rules_table) * srt, u32 * next_indices) { RTT (sort_srt) = srt; vec_sort_with_function (next_indices, RT (mma_sort_indices)); } int RT (mma_rules_table_add_rule) (RTT (mma_rules_table) * srt, RTT (mma_rule) * rule) { u32 parent_index, i, *next_indices = 0, added = 0, rule_index; RTT (mma_rule) * parent, *child; rule_index = RT (mma_rules_table_rule_index) (srt, rule); parent_index = RT (mma_rules_table_lookup_rule) (srt, &rule->match, srt->root_index); parent = RT (mma_rules_table_get_rule) (srt, parent_index); if (RT (rule_is_exact_match) (rule, parent)) { parent->action_index = rule->action_index; RT (mma_rule_free) (srt, rule); return -1; } if (vec_len (parent->next_indices) == 0) { vec_add1 (parent->next_indices, rule_index); return 0; } /* Check if new rule is parent of some of the existing children */ for (i = 0; i < vec_len (parent->next_indices); i++) { child = RT (mma_rules_table_get_rule) (srt, parent->next_indices[i]); if (RT (rule_is_match_for_key) (&child->match, rule)) { vec_add1 (rule->next_indices, parent->next_indices[i]); if (!added) { vec_add1 (next_indices, rule_index); added = 1; } } else { if (!added && srt->rule_cmp_fn (rule, child) < 0) { vec_add1 (next_indices, rule_index); added = 1; } vec_add1 (next_indices, parent->next_indices[i]); } } if (!added) vec_add1 (next_indices, rule_index); vec_free (parent->next_indices); parent->next_indices = next_indices; return 0; } int RT (mma_rules_table_del_rule) (RTT (mma_rules_table) * srt, RTT (mma_rule) * rule, u32 rule_index) { RTT (mma_rule) * rp; u32 rv; int i; ASSERT (rule_index != MMA_TABLE_INVALID_INDEX); rp = RT (mma_rules_table_get_rule) (srt, rule_index); if (!RT (rule_is_match_for_key) (&rule->match, rp)) return MMA_TABLE_INVALID_INDEX; if (RT (rule_is_exact_match) (rule, rp)) { if (rule_index == srt->root_index) rp->action_index = MMA_TABLE_INVALID_INDEX; return 1; } for (i = 0; i < vec_len (rp->next_indices); i++) { rv = RT (mma_rules_table_del_rule) (srt, rule, rp->next_indices[i]); if (rv == 1) { RTT (mma_rule) * child; u32 *next_indices = 0, *new_elts, left_to_add; child = RT (mma_rules_table_get_rule) (srt, rp->next_indices[i]); ASSERT (RT (rule_is_exact_match) (rule, child)); if (i != 0) { vec_add2 (next_indices, new_elts, i); clib_memcpy (new_elts, rp->next_indices, i * sizeof (u32)); } if (vec_len (child->next_indices)) vec_append (next_indices, child->next_indices); left_to_add = vec_len (rp->next_indices) - i - 1; if (left_to_add) { vec_add2 (next_indices, new_elts, left_to_add); clib_memcpy (new_elts, &rp->next_indices[i + 1], left_to_add * sizeof (u32)); } RT (mma_rule_free) (srt, child); vec_free (rp->next_indices); rp->next_indices = next_indices; return 0; } else if (rv == 0) return rv; } return MMA_TABLE_INVALID_INDEX; } /* * fd.io coding-style-patch-verification: ON * * Local Variables: * eval: (c-set-style "gnu") * End: */