Andi Kleen <andi@xxxxxxxxxxxxxx> writes: > On Mon, Jun 20, 2011 at 02:17:32PM -0700, Junio C Hamano wrote: >> Andi Kleen <andi@xxxxxxxxxxxxxx> writes: >> >> > From: Andi Kleen <ak@xxxxxxxxxxxxxxx> >> > >> > Add a lot of dummy returns to silence "control flow reaches >> > end of non void function" warnings with disabled noreturn. >> > >> > If NO_NORETURN is not disabled they will be all optimized away. >> >> I think this is probably a bad move, given that the previous patch is a > > This is basically the patch you suggested. Do you have some other suggestion > now? Sorry, I do not recall suggesting to add these dummy returns. The NO_NORETURN workaround (your [1/3]) is what I remember. >> these will introduce noise for build without NO_NORETURN (either when >> profile feedback is not used, or when profile feedback build is in use and >> it no longer requires the NO_NORETURN workaround). > > I fixed the noise in a followon patch. I suspect that we are talking about different warnings. The extra unreachable returns this patch adds will introduce more "unreachable code" warnings, which was what my message you are responding to is about. While I agree with you that this patch will now squelch "control flow reaches end of non void function" warnings (which is your justification for this patch), I am just pointing out that it is like robbing Peter to pay Paul. -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html