16__rte_lpm_lookup_vec(
const struct rte_lpm *lpm,
const uint32_t *ips,
20 svuint32_t v_ip, v_idx, v_tbl24, v_tbl8, v_hop;
21 svuint32_t v_mask_xv, v_mask_v, v_mask_hop;
22 svbool_t pg = svwhilelt_b32(i, n);
26 v_ip = svld1(pg, &ips[i]);
28 v_idx = svlsr_x(pg, v_ip, 8);
30 v_tbl24 = svld1_gather_index(pg, (
const uint32_t *)lpm->tbl24,
36 v_mask_xv = svdup_u32_z(pg, RTE_LPM_VALID_EXT_ENTRY_BITMASK);
38 pv = svcmpeq(pg, svand_z(pg, v_tbl24, v_mask_xv), v_mask_v);
40 v_mask_hop = svdup_u32_z(pg, 0x00ffffff);
42 v_hop = svand_x(pv, v_tbl24, v_mask_hop);
43 svst1(pv, &next_hops[i], v_hop);
46 pv = svcmpeq(pg, svand_z(pg, v_tbl24, v_mask_xv), v_mask_xv);
48 v_idx = svand_x(pv, v_tbl24, svdup_u32_z(pv, 0xffffff));
49 v_idx = svmul_x(pv, v_idx, RTE_LPM_TBL8_GROUP_NUM_ENTRIES);
50 v_idx = svadd_x(pv, svand_x(pv, v_ip, svdup_u32_z(pv, 0xff)),
53 v_tbl8 = svld1_gather_index(pv, (
const uint32_t *)lpm->tbl8,
56 pv = svcmpeq(pv, svand_z(pv, v_tbl8, v_mask_v), v_mask_v);
58 v_hop = svand_x(pv, v_tbl8, v_mask_hop);
59 svst1(pv, &next_hops[i], v_hop);
62 pg = svwhilelt_b32(i, n);
63 }
while (svptest_any(svptrue_b32(), pg));
72 vst1q_s32((int32_t *)ips, ip);
73 for (i = 0; i < 4; i++)
76 __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