Rev 652 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 652 | Rev 653 | ||
---|---|---|---|
Line 51... | Line 51... | ||
51 | { |
51 | { |
52 | return ((a==b)||(((a.binary| b.binary)&0x7FFFFFFF)==0)); /* a equals to b or both are zeros (with any sign) */ |
52 | return ((a==b)||(((a.binary| b.binary)&0x7FFFFFFF)==0)); /* a equals to b or both are zeros (with any sign) */ |
53 | } |
53 | } |
54 | 54 | ||
55 | /** |
55 | /** |
56 | * @return 1, if a>b - but NaNs are not recognized |
56 | * @return 1, if a<b - but NaNs are not recognized |
57 | */ |
57 | */ |
58 | inline int isFloat32lt(float32 a, float32 b) |
58 | inline int isFloat32lt(float32 a, float32 b) |
59 | { |
59 | { |
60 | if (((a.binary| b.binary)&0x7FFFFFFF)==0) { |
60 | if (((a.binary| b.binary)&0x7FFFFFFF)==0) { |
61 | return 0; |
61 | return 0; |
Line 64... | Line 64... | ||
64 | b.parts.sign^=b.parts.sign; |
64 | b.parts.sign^=b.parts.sign; |
65 | return (a.binary<b.binary); |
65 | return (a.binary<b.binary); |
66 | 66 | ||
67 | } |
67 | } |
68 | 68 | ||
- | 69 | /** |
|
- | 70 | * @return 1, if a>b - but NaNs are not recognized |
|
- | 71 | */ |
|
- | 72 | inline int isFloat32gt(float32 a, float32 b) |
|
- | 73 | { |
|
- | 74 | if (((a.binary| b.binary)&0x7FFFFFFF)==0) { |
|
- | 75 | return 0; |
|
- | 76 | }; |
|
- | 77 | a.parts.sign^=a.parts.sign; |
|
- | 78 | b.parts.sign^=b.parts.sign; |
|
- | 79 | return (a.binary>b.binary); |
|
- | 80 | ||
- | 81 | } |
|
- | 82 | ||
69 | 83 |