projects
/
libfirm
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
868297f
)
Copy the sign bit when truncating a float tarval.
author
Christoph Mallon
<christoph.mallon@gmx.de>
Mon, 8 Dec 2008 17:18:11 +0000
(17:18 +0000)
committer
Christoph Mallon
<christoph.mallon@gmx.de>
Mon, 8 Dec 2008 17:18:11 +0000
(17:18 +0000)
[r24403]
ir/tv/fltcalc.c
patch
|
blob
|
history
diff --git
a/ir/tv/fltcalc.c
b/ir/tv/fltcalc.c
index
0f162da
..
eedee4d
100644
(file)
--- a/
ir/tv/fltcalc.c
+++ b/
ir/tv/fltcalc.c
@@
-811,7
+811,10
@@
static void _trunc(const fp_value *a, fp_value *result) {
/* and the mask and return the result */
sc_and(_mant(a), temp, _mant(result));
- if (a != result) memcpy(_exp(result), _exp(a), value_size);
+ if (a != result) {
+ memcpy(_exp(result), _exp(a), value_size);
+ result->sign = a->sign;
+ }
}
/********