17__rte_lpm_lookup_vec(
const struct rte_lpm *lpm,
const uint32_t *ips,
21 svuint32_t v_ip, v_idx, v_tbl24, v_tbl8, v_hop;
22 svuint32_t v_mask_xv, v_mask_v, v_mask_hop;
23 svbool_t pg = svwhilelt_b32(i, n);
27 v_ip = svld1(pg, &ips[i]);
29 v_idx = svlsr_x(pg, v_ip, 8);
31 v_tbl24 = svld1_gather_index(pg, (
const uint32_t *)lpm->tbl24,
37 v_mask_xv = svdup_u32_z(pg, RTE_LPM_VALID_EXT_ENTRY_BITMASK);
39 pv = svcmpeq(pg, svand_z(pg, v_tbl24, v_mask_xv), v_mask_v);
41 v_mask_hop = svdup_u32_z(pg, 0x00ffffff);
43 v_hop = svand_x(pv, v_tbl24, v_mask_hop);
44 svst1(pv, &next_hops[i], v_hop);
47 pv = svcmpeq(pg, svand_z(pg, v_tbl24, v_mask_xv), v_mask_xv);
49 v_idx = svand_x(pv, v_tbl24, svdup_u32_z(pv, 0xffffff));
50 v_idx = svmul_x(pv, v_idx, RTE_LPM_TBL8_GROUP_NUM_ENTRIES);
51 v_idx = svadd_x(pv, svand_x(pv, v_ip, svdup_u32_z(pv, 0xff)),
54 v_tbl8 = svld1_gather_index(pv, (
const uint32_t *)lpm->tbl8,
57 pv = svcmpeq(pv, svand_z(pv, v_tbl8, v_mask_v), v_mask_v);
59 v_hop = svand_x(pv, v_tbl8, v_mask_hop);
60 svst1(pv, &next_hops[i], v_hop);
63 pg = svwhilelt_b32(i, n);
64 }
while (svptest_any(svptrue_b32(), pg));
73 vst1q_s32((int32_t *)ips, ip);
74 for (i = 0; i < 4; i++)
77 __rte_lpm_lookup_vec(lpm, ips, hop, 4);
static void rte_lpm_lookupx4(const struct rte_lpm *lpm, xmm_t ip, uint32_t hop[4], uint32_t defv)
#define RTE_LPM_LOOKUP_SUCCESS