diff options
author | Rodrigo Obregon <robregon@ti.com> | 2010-11-05 12:15:26 -0500 |
---|---|---|
committer | Rodrigo Obregon <robregon@ti.com> | 2010-11-05 12:15:26 -0500 |
commit | fddaafcedaac344845afd24f0b00660a846d0eba (patch) | |
tree | d6a4f03ff0ab38551c06442afd3685fa039ba52c | |
parent | 96c03c7dcc8cad59f2b8f3e6fef6a77a43750756 (diff) | |
download | bionic-fddaafcedaac344845afd24f0b00660a846d0eba.tar.gz |
Bionic: Aliasing problems with frexpf
This patch fixes a known bug in bionic libm
due to aliasing issues in gcc 4.2 and 4.4; more
specifically in frexpf.
The function frexpf is used to extract the
mantissa and exponent from a double precision number.
The bug has already been reported here:
https://code.google.com/p/android/issues/detail?id=6697
Change-Id: I2e1f2e0a45906642d2225b9d150ed391d2bf331c
Signed-off-by: Rodrigo Obregon <robregon@ti.com>
-rw-r--r-- | libm/src/s_frexpf.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libm/src/s_frexpf.c b/libm/src/s_frexpf.c index 89d464b4d..c18cd54c6 100644 --- a/libm/src/s_frexpf.c +++ b/libm/src/s_frexpf.c @@ -39,6 +39,6 @@ frexpf(float x, int *eptr) } *eptr += (ix>>23)-126; hx = (hx&0x807fffff)|0x3f000000; - *(int*)&x = hx; + SET_FLOAT_WORD(x,hx); return x; } |