summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--libm/Android.mk17
-rw-r--r--libm/arm/e_pow.S6
-rw-r--r--libm/arm/s_cos.S2
-rw-r--r--libm/arm/s_sin.S2
-rw-r--r--libm/src/e_pow.c2
-rw-r--r--libm/src/math_private.h4
6 files changed, 17 insertions, 16 deletions
diff --git a/libm/Android.mk b/libm/Android.mk
index 67c3cb2..fcc1f89 100644
--- a/libm/Android.mk
+++ b/libm/Android.mk
@@ -158,13 +158,9 @@ ifeq ($(TARGET_ARCH),arm)
src/s_scalbn.c \
src/s_scalbnf.c
- ifeq ($(ARCH_ARM_HAVE_NEON),true)
- libm_common_src_files += \
- arm/e_pow.S
- endif
-
ifeq ($(TARGET_USE_KRAIT_BIONIC_OPTIMIZATION),true)
libm_common_src_files += \
+ arm/e_pow.S \
arm/s_cos.S \
arm/s_sin.S \
arm/e_sqrtf.S \
@@ -178,8 +174,13 @@ ifeq ($(TARGET_ARCH),arm)
src/e_sqrt.c
endif
- libm_common_includes = $(LOCAL_PATH)/arm
+ ifeq ($(TARGET_USE_SPARROW_BIONIC_OPTIMIZATION),true)
+ libm_common_src_files += \
+ arm/e_pow.S
+ libm_common_cflags += -DSPARROW_NEON_OPTIMIZATION
+ endif
+ libm_common_includes = $(LOCAL_PATH)/arm
else
libm_common_src_files += \
src/s_cos.c \
@@ -223,6 +224,8 @@ LOCAL_ARM_MODE := arm
LOCAL_C_INCLUDES += $(libm_common_includes)
LOCAL_CFLAGS := $(libm_common_cflags)
+LOCAL_CFLAGS:= $(libm_common_cflags)
+
LOCAL_MODULE:= libm
LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/Android.mk
@@ -243,6 +246,8 @@ LOCAL_ARM_MODE := arm
LOCAL_C_INCLUDES += $(libm_common_includes)
LOCAL_CFLAGS := $(libm_common_cflags)
+LOCAL_CFLAGS:= $(libm_common_cflags)
+
LOCAL_MODULE:= libm
LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/Android.mk
diff --git a/libm/arm/e_pow.S b/libm/arm/e_pow.S
index b057308..0a69d3e 100644
--- a/libm/arm/e_pow.S
+++ b/libm/arm/e_pow.S
@@ -1,4 +1,4 @@
-@ Copyright (c) 2012, Code Aurora Forum. All rights reserved.
+@ Copyright (c) 2012, The Linux Foundation. All rights reserved.
@
@ Redistribution and use in source and binary forms, with or without
@ modification, are permitted provided that the following conditions are
@@ -9,7 +9,7 @@
@ copyright notice, this list of conditions and the following
@ disclaimer in the documentation and/or other materials provided
@ with the distribution.
-@ * Neither the name of Code Aurora Forum, Inc. nor the names of its
+@ * Neither the name of The Linux Foundation nor the names of its
@ contributors may be used to endorse or promote products derived
@ from this software without specific prior written permission.
@
@@ -101,9 +101,7 @@
#define vmov_f32 fconsts
#define vmovne_f64 fconstdne
-#if defined(KRAIT_NEON_OPTIMIZATION)
#define KRAIT_NO_AAPCS_VFP_MODE
-#endif
ENTRY(pow)
#if defined(KRAIT_NO_AAPCS_VFP_MODE)
diff --git a/libm/arm/s_cos.S b/libm/arm/s_cos.S
index 30a6767..450acbf 100644
--- a/libm/arm/s_cos.S
+++ b/libm/arm/s_cos.S
@@ -9,7 +9,7 @@
@ copyright notice, this list of conditions and the following
@ disclaimer in the documentation and/or other materials provided
@ with the distribution.
-@ * Neither the name of Code Aurora Forum, Inc. nor the names of its
+@ * Neither the name of The Linux Foundation nor the names of its
@ contributors may be used to endorse or promote products derived
@ from this software without specific prior written permission.
@
diff --git a/libm/arm/s_sin.S b/libm/arm/s_sin.S
index 9c3366c..6224d43 100644
--- a/libm/arm/s_sin.S
+++ b/libm/arm/s_sin.S
@@ -9,7 +9,7 @@
@ copyright notice, this list of conditions and the following
@ disclaimer in the documentation and/or other materials provided
@ with the distribution.
-@ * Neither the name of Code Aurora Forum, Inc. nor the names of its
+@ * Neither the name of The Linux Foundation nor the names of its
@ contributors may be used to endorse or promote products derived
@ from this software without specific prior written permission.
@
diff --git a/libm/src/e_pow.c b/libm/src/e_pow.c
index 5bb7f7b..c3f4d10 100644
--- a/libm/src/e_pow.c
+++ b/libm/src/e_pow.c
@@ -95,7 +95,7 @@ ivln2_h = 1.44269502162933349609e+00, /* 0x3FF71547, 0x60000000 =24b 1/ln2*/
ivln2_l = 1.92596299112661746887e-08; /* 0x3E54AE0B, 0xF85DDF44 =1/ln2 tail*/
double
-#if defined(__ARM_NEON__)
+#if defined(KRAIT_NEON_OPTIMIZATION) || defined(SPARROW_NEON_OPTIMIZATION)
__full_ieee754_pow(double x, double y)
#else
__ieee754_pow(double x, double y)
diff --git a/libm/src/math_private.h b/libm/src/math_private.h
index 888272d..92249eb 100644
--- a/libm/src/math_private.h
+++ b/libm/src/math_private.h
@@ -257,10 +257,8 @@ cpackl(long double x, long double y)
#define __ieee754_ldexpf ldexpf
/* fdlibm kernel function */
-#if defined(__ARM_NEON__)
-double __full_ieee754_pow(double,double);
-#endif
#if defined(KRAIT_NEON_OPTIMIZATION)
+double __full_ieee754_pow(double,double);
int __ieee754_rem_pio2(double,double*) __attribute__((pcs("aapcs-vfp")));
double __kernel_sin(double,double,int) __attribute__((pcs("aapcs-vfp")));
double __kernel_cos(double,double) __attribute__((pcs("aapcs-vfp")));