lkml.org 
[lkml]   [2011]   [Jun]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: How to measure enable_kernel_fpu overhead?
> Different CPU models. This years CPUs does this and next years that.

Er, yes, exactly. That's why we have multiple code paths, and
run-time selection of the best. The basic principle is used rather
a lot in the Linux kernel, e.g. the alternative() feature.

To me the closest equivalent is the RAID6 code, which has no less than 12
different versions (5 integer, 4 AltiVec, 1 MMX, 1 SSE1, and 1 SSE2),
and on x86 it benchmarks the 8 different versions at boot time and
chooses the best.

What confuses me is:
> I would suggest KISS.

This suggestion is not quite clear to me; I'm not quite sure what you
think is "simple". Do you mean always use the integer code and ignore
the SSE registers? Or something else?

Could you expand on that remark a little, please?

Thank you!


\
 
 \ /
  Last update: 2011-06-05 03:53    [W:0.048 / U:0.280 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site