[PATCH] Detect i586 and i686 features at run-time
H.J. Lu
hjl.tools@gmail.com
Tue Aug 18 18:25:00 GMT 2015
On Tue, Aug 18, 2015 at 10:30 AM, H.J. Lu <hjl.tools@gmail.com> wrote:
> On Tue, Aug 18, 2015 at 9:16 AM, Joseph Myers <joseph@codesourcery.com> wrote:
>> On Tue, 18 Aug 2015, H.J. Lu wrote:
>>
>>> My change is based on sysdeps/x86/bits/string.h and
>>> sysdeps/x86/bits/byteswap.h. None of them check
>>> __i586__ nor __i686__.
>>
>> Maybe
>>
>> (a) there should be a new (installed) bits/ header for x86, say
>> bits/x86-arch.h, that defines __x86_arch to 4, 5 or 6 depending on such
>> macros, so the logic doesn't need duplicating;
>>
>
> We can add cpu-features.h to installed header to provide both
> run-time and compile-time CPU feature detection.
>
Here is a patch which does that. OK for master?
--
H.J.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Detect-i586-and-i686-features-at-run-time.patch
Type: text/x-patch
Size: 4885 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/libc-alpha/attachments/20150818/f4ea0083/attachment.bin>
More information about the Libc-alpha
mailing list