b98eb8694365b8e3bb34578a2eff2c7d00d4d8ec
[riscv-isa-sim.git] / softfloat / s_normSubnormalF32Sig.c
1
2 #include <stdint.h>
3 #include "platform.h"
4 #include "primitives.h"
5 #include "internals.h"
6
7 struct exp16_sig32 softfloat_normSubnormalF32Sig( uint_fast32_t sig )
8 {
9 int shiftCount;
10 struct exp16_sig32 z;
11
12 shiftCount = softfloat_countLeadingZeros32( sig ) - 8;
13 z.exp = 1 - shiftCount;
14 z.sig = sig<<shiftCount;
15 return z;
16
17 }
18