[PATCH v2] ARM: Add Cortex-A15 optimized NEON and VFP memcpy routines, with IFUNC.

Carlos O'Donell carlos@redhat.com
Wed Apr 17 17:51:00 GMT 2013


On 04/16/2013 02:25 AM, Will Newton wrote:
> +size_t
> +__libc_ifunc_impl_list (const char *name, struct libc_ifunc_impl *array,
> +			size_t max)
> +{
> +  size_t i = 0;
> +  int hwcap;
> +
> +  hwcap = GLRO(dl_hwcap);
> +
> +  IFUNC_IMPL (i, name, memcpy,
> +	      IFUNC_IMPL_ADD (array, i, memcpy, hwcap & HWCAP_ARM_NEON,
> +			      __memcpy_neon)
> +	      IFUNC_IMPL_ADD (array, i, memcpy, hwcap & HWCAP_ARM_VFPv3,
> +			      __memcpy_vfp)
> +	      IFUNC_IMPL_ADD (array, i, memcpy, 1, __memcpy_arm));
> +
> +  return i;
> +}

If unaligned access is a requirement why not check for it here?

While unaligned access is virtually free on ARMv6 or higher it
is still possible for the U-bit to be disabled and for this to
crash on such systems.

Cheers,
Carlos.



More information about the Libc-ports mailing list