Make two implicit casts from double to int explicit to silence compiler
warnings about them. The casts are required during the computation of
exponentiation.
Signed-off-by: Sven Linker <sven.linker(a)kernkonzept.com>
---
libm/e_exp.c | 2 +-
libm/s_expm1.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/libm/e_exp.c b/libm/e_exp.c
index ffa556120..f694f67d1 100644
--- a/libm/e_exp.c
+++ b/libm/e_exp.c
@@ -126,7 +126,7 @@ double __ieee754_exp(double x) /* default IEEE double exp */
if(hx < 0x3FF0A2B2) { /* and |x| < 1.5 ln2 */
hi = x-ln2HI[xsb]; lo=ln2LO[xsb]; k = 1-xsb-xsb;
} else {
- k = invln2*x+halF[xsb];
+ k = (int32_t)(invln2*x+halF[xsb]);
t = k;
hi = x - t*ln2HI[0]; /* t*ln2HI is exact here */
lo = t*ln2LO[0];
diff --git a/libm/s_expm1.c b/libm/s_expm1.c
index 8e51ae748..85defefa4 100644
--- a/libm/s_expm1.c
+++ b/libm/s_expm1.c
@@ -159,7 +159,7 @@ double expm1(double x)
else
{hi = x + ln2_hi; lo = -ln2_lo; k = -1;}
} else {
- k = invln2*x+((xsb==0)?0.5:-0.5);
+ k = (int32_t)(invln2*x+((xsb==0)?0.5:-0.5));
t = k;
hi = x - t*ln2_hi; /* t*ln2_hi is exact here */
lo = t*ln2_lo;
--
2.43.0
The parameters are not used in the function variant without vdso
support, so tell this to the compiler to avoid a warning. Also fix the
indentation to be in-line with other functions in the file.
---
ldso/ldso/dl-vdso.c | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/ldso/ldso/dl-vdso.c b/ldso/ldso/dl-vdso.c
index 196cbbb3b..01309011d 100755
--- a/ldso/ldso/dl-vdso.c
+++ b/ldso/ldso/dl-vdso.c
@@ -28,14 +28,14 @@
#ifndef __VDSO_SUPPORT__
- void load_vdso(void *sys_info_ehdr, char **envp ){
+void load_vdso( void *sys_info_ehdr attribute_unused,
+ char **envp attribute_unused ){
#ifdef __SUPPORT_LD_DEBUG__
- if ( _dl_debug_vdso != 0 ){
- _dl_dprintf(2,"_dl_vdso support not enabled\n" );
- }
-
-#endif
+ if ( _dl_debug_vdso != 0 ){
+ _dl_dprintf(2,"_dl_vdso support not enabled\n" );
}
+#endif
+}
#else
void *_dl__vdso_gettimeofday = 0;
--
2.43.0
Hi,
I released uClibc-ng 1.0.49 on Saturday.
Many gcc 14.1.0 fixes were added thanks to Dmitry and Max.
Xtensa FDPIC support was added by Max.
git shortlog v1.0.49...v1.0.48
Dmitry Chestnykh (6):
Correct uClibc compilation.
Fix uClibc build for nds32 with gcc-14.
Fix riscv32 build with gcc-14.
riscv32: Fix `struct ucontext` definition.
Fix wrong `struct ucontext_t` typedef for all arches.
Cast to proper types inside atomic macroses.
Fabrice Fontaine (1):
libc/sysdeps/linux/common/utime.c: fix riscv32 build
Joe Damato (1):
epoll.h: Add epoll ioctls
Max Filippov (9):
iconv: fix type mismatches
ldso: FDPIC: fix type mismatches
ldso: arm: fix build with gcc-14
malloc/memalign: avoid integer overflow
fix kernel_stat64 definition
linuxthreads: enable unwinding over signal frames
xtensa: use compiler-provided XCHAL macros
xtensa: make _init and _fini hidden
xtensa: add FDPIC support
Waldemar Brodkorb (9):
futimesat: add missing header
sparc64: Fix incorrect sigreturn stub function implementation
csky: allow time64
m68k: fix noMMU ELF compile with gcc 14.x
Revert "nds32: sync with binutils 2.37, gcc 11.2 and linux 5.10.93 changes"
m68k: fix for m68000 cpu
config: make ctor/dtor visible again
config: enable TIME64 by default
bump version for 1.0.49 release
Yuriy Kolerov (1):
libc: cast free() argument to void * in wchar.c
best regards
Waldemar