On 31-07-15, 11:41, Vlastimil Babka wrote: > [+CC Steven Rostedt] > > Any idea what the compiler does in the case of > "if (likely(IS_ERR(...)))"? There are apparently such cases in the source. > > does the "likely" somehow override the "unlikely" of IS_ERR, or is > the resulting code a mess?
Good point. While fixing all the sites, I saw some code like that. Then before posting the series, I tried to look at what compilers do to such codes and they generated exactly same code for: likely(unlikely(x)) and unlikely(x). So, either those call sites should drop the likely bits or we supply them with another raw version of the macro :) Or if my tests were wrong, then please lemme know. -- viresh -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/