diff options
author | Ralf Baechle <ralf@linux-mips.org> | 2014-04-18 18:36:32 -0400 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2014-05-21 05:12:57 -0400 |
commit | 9e8bad1f9c0370b2635175b34d6151b90a53da5c (patch) | |
tree | 0971254e7d21761a5dec3f946e2f65c9fd43e844 /arch/mips/math-emu/sp_tint.c | |
parent | bee1653593b39ac85b45a057bb8c22dc1489cf6a (diff) |
MIPS: math-emu: Turn macros into functions where possible.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch/mips/math-emu/sp_tint.c')
-rw-r--r-- | arch/mips/math-emu/sp_tint.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/arch/mips/math-emu/sp_tint.c b/arch/mips/math-emu/sp_tint.c index a69dfe5dda3a..febcf5cc4fbc 100644 --- a/arch/mips/math-emu/sp_tint.c +++ b/arch/mips/math-emu/sp_tint.c | |||
@@ -30,7 +30,7 @@ int ieee754sp_tint(union ieee754sp x) | |||
30 | { | 30 | { |
31 | COMPXSP; | 31 | COMPXSP; |
32 | 32 | ||
33 | CLEARCX; | 33 | ieee754_clearcx(); |
34 | 34 | ||
35 | EXPLODEXSP; | 35 | EXPLODEXSP; |
36 | FLUSHXSP; | 36 | FLUSHXSP; |
@@ -39,7 +39,7 @@ int ieee754sp_tint(union ieee754sp x) | |||
39 | case IEEE754_CLASS_SNAN: | 39 | case IEEE754_CLASS_SNAN: |
40 | case IEEE754_CLASS_QNAN: | 40 | case IEEE754_CLASS_QNAN: |
41 | case IEEE754_CLASS_INF: | 41 | case IEEE754_CLASS_INF: |
42 | SETCX(IEEE754_INVALID_OPERATION); | 42 | ieee754_setcx(IEEE754_INVALID_OPERATION); |
43 | return ieee754si_xcpt(ieee754si_indef(), "sp_tint", x); | 43 | return ieee754si_xcpt(ieee754si_indef(), "sp_tint", x); |
44 | case IEEE754_CLASS_ZERO: | 44 | case IEEE754_CLASS_ZERO: |
45 | return 0; | 45 | return 0; |
@@ -53,7 +53,7 @@ int ieee754sp_tint(union ieee754sp x) | |||
53 | return -0x80000000; | 53 | return -0x80000000; |
54 | /* Set invalid. We will only use overflow for floating | 54 | /* Set invalid. We will only use overflow for floating |
55 | point overflow */ | 55 | point overflow */ |
56 | SETCX(IEEE754_INVALID_OPERATION); | 56 | ieee754_setcx(IEEE754_INVALID_OPERATION); |
57 | return ieee754si_xcpt(ieee754si_indef(), "sp_tint", x); | 57 | return ieee754si_xcpt(ieee754si_indef(), "sp_tint", x); |
58 | } | 58 | } |
59 | /* oh gawd */ | 59 | /* oh gawd */ |
@@ -99,11 +99,11 @@ int ieee754sp_tint(union ieee754sp x) | |||
99 | } | 99 | } |
100 | if ((xm >> 31) != 0) { | 100 | if ((xm >> 31) != 0) { |
101 | /* This can happen after rounding */ | 101 | /* This can happen after rounding */ |
102 | SETCX(IEEE754_INVALID_OPERATION); | 102 | ieee754_setcx(IEEE754_INVALID_OPERATION); |
103 | return ieee754si_xcpt(ieee754si_indef(), "sp_tint", x); | 103 | return ieee754si_xcpt(ieee754si_indef(), "sp_tint", x); |
104 | } | 104 | } |
105 | if (round || sticky) | 105 | if (round || sticky) |
106 | SETCX(IEEE754_INEXACT); | 106 | ieee754_setcx(IEEE754_INEXACT); |
107 | } | 107 | } |
108 | if (xs) | 108 | if (xs) |
109 | return -xm; | 109 | return -xm; |