This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
__attribute__ ifunc examples?
- From: James Cloos <cloos at jhcloos dot com>
- To: gcc-help at gcc dot gnu dot org
- Date: Wed, 14 Mar 2012 10:21:34 -0400
- Subject: __attribute__ ifunc examples?
- Copyright: Copyright 2012 James Cloos
- Openpgp: ED7DAEA6; url=http://jhcloos.com/public_key/0xED7DAEA6.asc
- Openpgp-fingerprint: E9E9 F828 61A4 6EA9 0F2B 63E7 997A 9F17 ED7D AEA6
Does anyone have a worked example in C of using attribute ifunc to
dispatch over the various x86 SSE/AVX flags, as well as arm neon?
Must one call cpuid manually, or are flags already available to check?
I haven't found any via goog (and the C++ example I found was
incompatible with the gcc-4.6 syntax for ifunc), and glibc's
support for it is too opaque for grep.
Thanks,
-JimC
--
James Cloos <cloos@jhcloos.com> OpenPGP: 1024D/ED7DAEA6