2016-05-27 17:12, Jerin Jacob: > IMHO, I think we should have means to abstract this _logical_ changes > under conditional compilation flags and any arch/platform can choose > to select what it suites better for that arch/platform. > > We may NOT need to have frequent patches to select the specific > configuration, but logical patches under compilation flags can be accepted and > each arch/platform can choose specific set configuration when we make > the final release candidate for the release. > > Any thoughts?
Yes having some #ifdefs for arch configuration may be reasonnable. But other methods must be preffered first: 1/ try implementing the function in arch-specific files 2/ and check at runtime if (rte_cpu_get_flag_enabled(RTE_CPUFLAG_X 3/ or check #ifdef RTE_MACHINE_CPUFLAG_X 4/ or check #ifdef RTE_ARCH_Y 5/ or check a specific #ifdef RTE_FEATURE_NAME to choose in config files The option 2 is a nice to have which implies other options. Maybe that doc/guides/contributing/design.rst needs to be updated.