Initialize prev_tsc to cur_tsc. This avoids running the TX queue drain
in the first iteration of the packet processing loop.
Signed-off-by: Kathleen Capella <kathleen.capella@arm.com>
Reviewed-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>
const uint64_t drain_tsc = (rte_get_tsc_hz() + US_PER_S - 1) /
US_PER_S * BURST_TX_DRAIN_US;
const uint64_t drain_tsc = (rte_get_tsc_hz() + US_PER_S - 1) /
US_PER_S * BURST_TX_DRAIN_US;
lcore_id = rte_lcore_id();
qconf = &lcore_conf[lcore_id];
lcore_id = rte_lcore_id();
qconf = &lcore_conf[lcore_id];
lcore_id, portid, queueid);
}
lcore_id, portid, queueid);
}
+ cur_tsc = rte_rdtsc();
+ prev_tsc = cur_tsc;
/*
* TX burst queue drain
/*
* TX burst queue drain
+
+ cur_tsc = rte_rdtsc();
const uint64_t drain_tsc = (rte_get_tsc_hz() + US_PER_S - 1) /
US_PER_S * BURST_TX_DRAIN_US;
const uint64_t drain_tsc = (rte_get_tsc_hz() + US_PER_S - 1) /
US_PER_S * BURST_TX_DRAIN_US;
lcore_id = rte_lcore_id();
qconf = &lcore_conf[lcore_id];
lcore_id = rte_lcore_id();
qconf = &lcore_conf[lcore_id];
lcore_id, portid, queueid);
}
lcore_id, portid, queueid);
}
+ cur_tsc = rte_rdtsc();
+ prev_tsc = cur_tsc;
/*
* TX burst queue drain
/*
* TX burst queue drain
portid, qconf);
#endif /* X86 */
}
portid, qconf);
#endif /* X86 */
}
+
+ cur_tsc = rte_rdtsc();