Changes in uspace/lib/softfloat/generic/common.c [9d58539:88d5c1e] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/softfloat/generic/common.c
r9d58539 r88d5c1e 66 66 * @return Finished double-precision float. 67 67 */ 68 float64 finish Float64(int32_t cexp, uint64_t cfrac, char sign)68 float64 finish_float64(int32_t cexp, uint64_t cfrac, char sign) 69 69 { 70 70 float64 result; … … 140 140 * @return Finished quadruple-precision float. 141 141 */ 142 float128 finish Float128(int32_t cexp, uint64_t cfrac_hi, uint64_t cfrac_lo,142 float128 finish_float128(int32_t cexp, uint64_t cfrac_hi, uint64_t cfrac_lo, 143 143 char sign, uint64_t shift_out) 144 144 { … … 238 238 * @return Number of detected leading zeroes. 239 239 */ 240 int count Zeroes8(uint8_t i)240 int count_zeroes8(uint8_t i) 241 241 { 242 242 return zeroTable[i]; … … 249 249 * @return Number of detected leading zeroes. 250 250 */ 251 int count Zeroes32(uint32_t i)251 int count_zeroes32(uint32_t i) 252 252 { 253 253 int j; 254 254 for (j = 0; j < 32; j += 8) { 255 255 if (i & (0xFF << (24 - j))) { 256 return (j + count Zeroes8(i >> (24 - j)));256 return (j + count_zeroes8(i >> (24 - j))); 257 257 } 258 258 } … … 267 267 * @return Number of detected leading zeroes. 268 268 */ 269 int count Zeroes64(uint64_t i)269 int count_zeroes64(uint64_t i) 270 270 { 271 271 int j; 272 272 for (j = 0; j < 64; j += 8) { 273 273 if (i & (0xFFll << (56 - j))) { 274 return (j + count Zeroes8(i >> (56 - j)));274 return (j + count_zeroes8(i >> (56 - j))); 275 275 } 276 276 } … … 286 286 * @param fraction Fraction with hidden bit shifted to 30th bit. 287 287 */ 288 void round Float32(int32_t *exp, uint32_t *fraction)288 void round_float32(int32_t *exp, uint32_t *fraction) 289 289 { 290 290 /* rounding - if first bit after fraction is set then round up */ … … 312 312 * @param fraction Fraction with hidden bit shifted to 62nd bit. 313 313 */ 314 void round Float64(int32_t *exp, uint64_t *fraction)314 void round_float64(int32_t *exp, uint64_t *fraction) 315 315 { 316 316 /* rounding - if first bit after fraction is set then round up */ … … 339 339 * @param frac_lo Low part of fraction part with hidden bit shifted to 126th bit. 340 340 */ 341 void round Float128(int32_t *exp, uint64_t *frac_hi, uint64_t *frac_lo)341 void round_float128(int32_t *exp, uint64_t *frac_hi, uint64_t *frac_lo) 342 342 { 343 343 uint64_t tmp_hi, tmp_lo;
Note:
See TracChangeset
for help on using the changeset viewer.