1
0
Files
linux/arch/x86/include/asm
Hannes Frederic Sowa e5a2c89995 fast_hash: avoid indirect function calls
By default the arch_fast_hash hashing function pointers are initialized
to jhash(2). If during boot-up a CPU with SSE4.2 is detected they get
updated to the CRC32 ones. This dispatching scheme incurs a function
pointer lookup and indirect call for every hashing operation.

rhashtable as a user of arch_fast_hash e.g. stores pointers to hashing
functions in its structure, too, causing two indirect branches per
hashing operation.

Using alternative_call we can get away with one of those indirect branches.

Acked-by: Daniel Borkmann <dborkman@redhat.com>
Cc: Thomas Graf <tgraf@suug.ch>
Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
2014-11-05 22:01:21 -05:00
..
2014-08-26 13:45:50 -04:00
2014-08-26 13:45:49 -04:00
2014-10-03 22:15:56 +01:00
2014-05-02 11:34:17 -07:00
2014-03-04 21:47:51 +01:00
2014-05-08 08:15:34 +02:00
2013-08-05 06:35:33 -07:00
2013-02-03 18:16:27 -05:00
2014-04-07 16:36:15 -07:00
2014-09-22 13:35:52 +02:00
2013-04-22 15:45:03 +09:30
2014-02-27 08:07:39 -08:00
2014-09-01 10:15:31 +02:00
2014-06-06 16:08:11 -07:00
2014-06-04 16:53:57 -07:00
2014-04-18 14:20:46 +02:00