aarch64: add single instruction math functions
this should increase performance and reduce code size on aarch64. the compiled code was checked against using __builtin_* instead of inline asm with gcc-6.2.0. lrint is two instructions. c with inline asm is used because it is safer than a pure asm implementation, this prevents ll{rint,round} to be an alias of l{rint,round} (because the types don't match) and depends on gcc style inline asm support. ceil, floor, round, trunc can either raise inexact on finite non-integer inputs or not raise any exceptions. the new implementation does not raise exceptions while the generic c code does. on aarch64, the underflow exception is signaled before rounding (ieee 754 allows both before and after rounding, but it must be consistent), the generic fma c code signals it after rounding so using single instruction fixes a slight conformance issue too.
Showing
src/math/aarch64/ceil.c
0 → 100644
src/math/aarch64/ceilf.c
0 → 100644
src/math/aarch64/fabs.c
0 → 100644
src/math/aarch64/fabs.s
已删除
100644 → 0
src/math/aarch64/fabsf.c
0 → 100644
src/math/aarch64/fabsf.s
已删除
100644 → 0
src/math/aarch64/floor.c
0 → 100644
src/math/aarch64/floorf.c
0 → 100644
src/math/aarch64/fma.c
0 → 100644
src/math/aarch64/fmaf.c
0 → 100644
src/math/aarch64/fmax.c
0 → 100644
src/math/aarch64/fmaxf.c
0 → 100644
src/math/aarch64/fmin.c
0 → 100644
src/math/aarch64/fminf.c
0 → 100644
src/math/aarch64/llrint.c
0 → 100644
src/math/aarch64/llrintf.c
0 → 100644
src/math/aarch64/llround.c
0 → 100644
src/math/aarch64/llroundf.c
0 → 100644
src/math/aarch64/lrint.c
0 → 100644
src/math/aarch64/lrintf.c
0 → 100644
src/math/aarch64/lround.c
0 → 100644
src/math/aarch64/lroundf.c
0 → 100644
src/math/aarch64/nearbyint.c
0 → 100644
src/math/aarch64/nearbyintf.c
0 → 100644
src/math/aarch64/rint.c
0 → 100644
src/math/aarch64/rintf.c
0 → 100644
src/math/aarch64/round.c
0 → 100644
src/math/aarch64/roundf.c
0 → 100644
src/math/aarch64/sqrt.c
0 → 100644
src/math/aarch64/sqrt.s
已删除
100644 → 0
src/math/aarch64/sqrtf.c
0 → 100644
src/math/aarch64/sqrtf.s
已删除
100644 → 0
src/math/aarch64/trunc.c
0 → 100644
src/math/aarch64/truncf.c
0 → 100644
想要评论请 注册 或 登录