• Nathan Chancellor's avatar
    kbuild: Enable -Wtautological-compare · afe956c5
    Nathan Chancellor authored
    Currently, we disable -Wtautological-compare, which in turn disables a
    bunch of more specific tautological comparison warnings that are useful
    for the kernel such as -Wtautological-bitwise-compare. See clang's
    documentation below for the other warnings that are suppressed by
    -Wtautological-compare. Now that all of the major/noisy warnings have
    been fixed, enable -Wtautological-compare so that more issues can be
    caught at build time by various continuous integration setups.
    
    -Wtautological-constant-out-of-range-compare is kept disabled under a
    normal build but visible at W=1 because there are places in the kernel
    where a constant or variable size can change based on the kernel
    configuration. These are not fixed in a clean/concise way and the ones
    I have audited so far appear to be harmless. It is not a subgroup but
    rather just one warning so we do not lose out on much coverage by
    default.
    
    Link: https://github.com/ClangBuiltLinux/linux/issues/488
    Link: http://releases....
    afe956c5
Makefile.extrawarn 2.74 KB