public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* Should we be using unlikely() around tests of GFP_ZERO?
@ 2011-01-02 23:48 Theodore Ts'o
  2011-01-03  3:46 ` Minchan Kim
  2011-01-03 17:23 ` Matt Mackall
  0 siblings, 2 replies; 9+ messages in thread
From: Theodore Ts'o @ 2011-01-02 23:48 UTC (permalink / raw)
  To: Christoph Lameter, Pekka Enberg, Matt Mackall, linux-mm; +Cc: linux-kernel


Given the patches being busily submitted by trivial patch submitters to
make use kmem_cache_zalloc(), et. al, I believe we should remove the
unlikely() tests around the (gfp_flags & __GFP_ZERO) tests, such as:

-	if (unlikely((flags & __GFP_ZERO) && objp))
+	if ((flags & __GFP_ZERO) && objp)
		memset(objp, 0, obj_size(cachep));

Agreed?  If so, I'll send a patch...

	    					- Ted

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2011-01-03 17:23 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-01-02 23:48 Should we be using unlikely() around tests of GFP_ZERO? Theodore Ts'o
2011-01-03  3:46 ` Minchan Kim
2011-01-03  7:40   ` Pekka Enberg
2011-01-03 13:45     ` Steven Rostedt
2011-01-03 14:10       ` Pekka Enberg
2011-01-03 14:26         ` Steven Rostedt
2011-01-03 13:58     ` Ted Ts'o
2011-01-03 14:09       ` Pekka Enberg
2011-01-03 17:23 ` Matt Mackall

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox