X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=app%2Ftest%2Ftest_distributor_perf.c;h=b25f79a3486c8df079c1721fb47711142d27e618;hb=c17af95a19e30c8d89eb96ceca99f60474ca2ac4;hp=664530ff9e333fb62f02f0637628ebda9122e3aa;hpb=bb79646a47643c8802788ae2e9e99d81c1f9fcc0;p=dpdk.git diff --git a/app/test/test_distributor_perf.c b/app/test/test_distributor_perf.c index 664530ff9e..b25f79a348 100644 --- a/app/test/test_distributor_perf.c +++ b/app/test/test_distributor_perf.c @@ -25,7 +25,7 @@ static volatile unsigned worker_idx; struct worker_stats { volatile unsigned handled_packets; } __rte_cache_aligned; -struct worker_stats worker_stats[RTE_MAX_LCORE]; +static struct worker_stats worker_stats[RTE_MAX_LCORE]; /* * worker thread used for testing the time to do a round-trip of a cache @@ -54,10 +54,10 @@ time_cache_line_switch(void) /* allocate a full cache line for data, we use only first byte of it */ uint64_t data[RTE_CACHE_LINE_SIZE*3 / sizeof(uint64_t)]; - unsigned i, slaveid = rte_get_next_lcore(rte_lcore_id(), 0, 0); + unsigned int i, workerid = rte_get_next_lcore(rte_lcore_id(), 0, 0); volatile uint64_t *pdata = &data[0]; *pdata = 1; - rte_eal_remote_launch((lcore_function_t *)flip_bit, &data[0], slaveid); + rte_eal_remote_launch((lcore_function_t *)flip_bit, &data[0], workerid); while (*pdata) rte_pause(); @@ -72,7 +72,7 @@ time_cache_line_switch(void) while (*pdata) rte_pause(); *pdata = 2; - rte_eal_wait_lcore(slaveid); + rte_eal_wait_lcore(workerid); printf("==== Cache line switch test ===\n"); printf("Time for %u iterations = %"PRIu64" ticks\n", (1<