Wire Sysio Wire Sysion 1.0.0
Loading...
Searching...
No Matches
f16_lt.c File Reference
#include <stdbool.h>
#include <stdint.h>
#include "platform.h"
#include "internals.h"
#include "softfloat.h"
Include dependency graph for f16_lt.c:

Go to the source code of this file.

Functions

bool f16_lt (float16_t a, float16_t b)
 

Function Documentation

◆ f16_lt()

bool f16_lt ( float16_t a,
float16_t b )

Definition at line 43 of file f16_lt.c.

44{
45 union ui16_f16 uA;
46 uint_fast16_t uiA;
47 union ui16_f16 uB;
48 uint_fast16_t uiB;
49 bool signA, signB;
50
51 uA.f = a;
52 uiA = uA.ui;
53 uB.f = b;
54 uiB = uB.ui;
55 if ( isNaNF16UI( uiA ) || isNaNF16UI( uiB ) ) {
57 return false;
58 }
59 signA = signF16UI( uiA );
60 signB = signF16UI( uiB );
61 return
62 (signA != signB) ? signA && ((uint16_t) ((uiA | uiB)<<1) != 0)
63 : (uiA != uiB) && (signA ^ (uiA < uiB));
64
65}
const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
Definition pointer.h:1181
void softfloat_raiseFlags(uint_fast8_t flags)
#define isNaNF16UI(a)
Definition internals.h:88
#define signF16UI(a)
Definition internals.h:83
@ softfloat_flag_invalid
Definition softfloat.h:89
unsigned short uint16_t
Definition stdint.h:125
uint16_t uint_fast16_t
Definition stdint.h:155
float16_t f
Definition internals.h:45
Here is the call graph for this function: