Skip to contentSkip to conversation

cuckoo_hash build failure with gcc-8

BUG Stephen Hemminger 2 participants 2 messages Mar 29, 2018 – Apr 4, 2018

lore
Share & tools
lore
#0 lore raw

Cuckoo hash has build failure with gcc-8.
The casting here is suspect anyway. It should be fixed more directly.

CC rte_table_hash_cuckoo.o
lib/librte_table/rte_table_hash_cuckoo.c: In function ‘rte_table_hash_cuckoo_create’:
lib/librte_table/rte_table_hash_cuckoo.c:110:16: error: cast between incompatible function types from ‘rte_table_hash_op_hash’ {aka ‘long unsigned int (*)(void *, void *, unsigned int, long unsigned int)’} to ‘uint32_t (*)(const void *, uint32_t, uint32_t)’ {aka ‘unsigned int (*)(const void *, unsigned int, unsigned int)’} [-Werror=cast-function-type]
.hash_func = (rte_hash_function)(p->f_hash),

                ^

cc1: all warnings being treated as errors

#1 lore raw

+Cc Pablo

29/03/2018 18:39, Stephen Hemminger:

Quoted 9 lines

Cuckoo hash has build failure with gcc-8.
The casting here is suspect anyway. It should be fixed more directly.

CC rte_table_hash_cuckoo.o
lib/librte_table/rte_table_hash_cuckoo.c: In function ‘rte_table_hash_cuckoo_create’:
lib/librte_table/rte_table_hash_cuckoo.c:110:16: error: cast between incompatible function types from ‘rte_table_hash_op_hash’ {aka ‘long unsigned int (*)(void *, void *, unsigned int, long unsigned int)’} to ‘uint32_t (*)(const void *, uint32_t, uint32_t)’ {aka ‘unsigned int (*)(const void *, unsigned int, unsigned int)’} [-Werror=cast-function-type]
.hash_func = (rte_hash_function)(p->f_hash),

                ^

cc1: all warnings being treated as errors