[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Sun, 11 Nov 2012 17:50:56 -0500 (EST)
From: David Miller <davem@...emloft.net>
To: xi.wang@...il.com
Cc: netdev@...r.kernel.org
Subject: Re: [PATCH] ipv4: avoid undefined behavior in do_ip_setsockopt()
From: Xi Wang <xi.wang@...il.com>
Date: Sun, 11 Nov 2012 17:18:55 -0500
> On 11/11/12 5:02 PM, David Miller wrote:
>>
>> This code is a fast bit test on purpose. You're making the
>> code slower.
>
> No, it's the opposite. All modern compilers optimize switch cases
> into a fast bit test.
Indeed, I even checked sparc64 with gcc-4.6 and it looks good.
Thanks for the clarification, I'll apply this, thanks.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists