Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions
vfp.h File Reference

Go to the source code of this file.

Data Structures

struct  vfp_single
 
struct  vfp_double
 
struct  op
 

Macros

#define vfp_sign_negate(sign)   (sign ^ 0x8000)
 
#define VFP_SINGLE_MANTISSA_BITS   (23)
 
#define VFP_SINGLE_EXPONENT_BITS   (8)
 
#define VFP_SINGLE_LOW_BITS   (32 - VFP_SINGLE_MANTISSA_BITS - 2)
 
#define VFP_SINGLE_LOW_BITS_MASK   ((1 << VFP_SINGLE_LOW_BITS) - 1)
 
#define VFP_SINGLE_SIGNIFICAND_QNAN   (1 << (VFP_SINGLE_MANTISSA_BITS - 1 + VFP_SINGLE_LOW_BITS))
 
#define vfp_single_packed_sign(v)   ((v) & 0x80000000)
 
#define vfp_single_packed_negate(v)   ((v) ^ 0x80000000)
 
#define vfp_single_packed_abs(v)   ((v) & ~0x80000000)
 
#define vfp_single_packed_exponent(v)   (((v) >> VFP_SINGLE_MANTISSA_BITS) & ((1 << VFP_SINGLE_EXPONENT_BITS) - 1))
 
#define vfp_single_packed_mantissa(v)   ((v) & ((1 << VFP_SINGLE_MANTISSA_BITS) - 1))
 
#define VFP_NUMBER   (1<<0)
 
#define VFP_ZERO   (1<<1)
 
#define VFP_DENORMAL   (1<<2)
 
#define VFP_INFINITY   (1<<3)
 
#define VFP_NAN   (1<<4)
 
#define VFP_NAN_SIGNAL   (1<<5)
 
#define VFP_QNAN   (VFP_NAN)
 
#define VFP_SNAN   (VFP_NAN|VFP_NAN_SIGNAL)
 
#define vfp_single_normaliseround(sd, vsd, fpscr, except, func)   __vfp_single_normaliseround(sd,vsd,fpscr,except)
 
#define VFP_REG_ZERO   16
 
#define VFP_DOUBLE_MANTISSA_BITS   (52)
 
#define VFP_DOUBLE_EXPONENT_BITS   (11)
 
#define VFP_DOUBLE_LOW_BITS   (64 - VFP_DOUBLE_MANTISSA_BITS - 2)
 
#define VFP_DOUBLE_LOW_BITS_MASK   ((1 << VFP_DOUBLE_LOW_BITS) - 1)
 
#define VFP_DOUBLE_SIGNIFICAND_QNAN   (1ULL << (VFP_DOUBLE_MANTISSA_BITS - 1 + VFP_DOUBLE_LOW_BITS))
 
#define vfp_double_packed_sign(v)   ((v) & (1ULL << 63))
 
#define vfp_double_packed_negate(v)   ((v) ^ (1ULL << 63))
 
#define vfp_double_packed_abs(v)   ((v) & ~(1ULL << 63))
 
#define vfp_double_packed_exponent(v)   (((v) >> VFP_DOUBLE_MANTISSA_BITS) & ((1 << VFP_DOUBLE_EXPONENT_BITS) - 1))
 
#define vfp_double_packed_mantissa(v)   ((v) & ((1ULL << VFP_DOUBLE_MANTISSA_BITS) - 1))
 
#define VFP_NAN_FLAG   0x100
 
#define VFP_EXCEPTION_ERROR   ((u32)-1 & ~VFP_NAN_FLAG)
 
#define OP_SCALAR   (1 << 0)
 
#define OP_SD   (1 << 1)
 
#define OP_DD   (1 << 1)
 
#define OP_SM   (1 << 2)
 

Functions

s32 vfp_get_float (unsigned int reg)
 
void vfp_put_float (s32 val, unsigned int reg)
 
u32 __vfp_single_normaliseround (int sd, struct vfp_single *vs, u32 fpscr, u32 exceptions)
 
u64 vfp_get_double (unsigned int reg)
 
void vfp_put_double (u64 val, unsigned int reg)
 
u32 vfp_double_normaliseround (int dd, struct vfp_double *vd, u32 fpscr, u32 exceptions, const char *func)
 
u32 vfp_estimate_sqrt_significand (u32 exponent, u32 significand)
 
void vfp_save_state (void *location, u32 fpexc)
 

Macro Definition Documentation

#define OP_DD   (1 << 1)

Definition at line 372 of file vfp.h.

#define OP_SCALAR   (1 << 0)

Definition at line 370 of file vfp.h.

#define OP_SD   (1 << 1)

Definition at line 371 of file vfp.h.

#define OP_SM   (1 << 2)

Definition at line 373 of file vfp.h.

#define VFP_DENORMAL   (1<<2)

Definition at line 220 of file vfp.h.

#define VFP_DOUBLE_EXPONENT_BITS   (11)

Definition at line 277 of file vfp.h.

#define VFP_DOUBLE_LOW_BITS   (64 - VFP_DOUBLE_MANTISSA_BITS - 2)

Definition at line 278 of file vfp.h.

#define VFP_DOUBLE_LOW_BITS_MASK   ((1 << VFP_DOUBLE_LOW_BITS) - 1)

Definition at line 279 of file vfp.h.

#define VFP_DOUBLE_MANTISSA_BITS   (52)

Definition at line 276 of file vfp.h.

#define vfp_double_packed_abs (   v)    ((v) & ~(1ULL << 63))

Definition at line 291 of file vfp.h.

#define vfp_double_packed_exponent (   v)    (((v) >> VFP_DOUBLE_MANTISSA_BITS) & ((1 << VFP_DOUBLE_EXPONENT_BITS) - 1))

Definition at line 292 of file vfp.h.

#define vfp_double_packed_mantissa (   v)    ((v) & ((1ULL << VFP_DOUBLE_MANTISSA_BITS) - 1))

Definition at line 293 of file vfp.h.

#define vfp_double_packed_negate (   v)    ((v) ^ (1ULL << 63))

Definition at line 290 of file vfp.h.

#define vfp_double_packed_sign (   v)    ((v) & (1ULL << 63))

Definition at line 289 of file vfp.h.

#define VFP_DOUBLE_SIGNIFICAND_QNAN   (1ULL << (VFP_DOUBLE_MANTISSA_BITS - 1 + VFP_DOUBLE_LOW_BITS))

Definition at line 284 of file vfp.h.

#define VFP_EXCEPTION_ERROR   ((u32)-1 & ~VFP_NAN_FLAG)

Definition at line 361 of file vfp.h.

#define VFP_INFINITY   (1<<3)

Definition at line 221 of file vfp.h.

#define VFP_NAN   (1<<4)

Definition at line 222 of file vfp.h.

#define VFP_NAN_FLAG   0x100

Definition at line 353 of file vfp.h.

#define VFP_NAN_SIGNAL   (1<<5)

Definition at line 223 of file vfp.h.

#define VFP_NUMBER   (1<<0)

Definition at line 218 of file vfp.h.

#define VFP_QNAN   (VFP_NAN)

Definition at line 225 of file vfp.h.

#define VFP_REG_ZERO   16

Definition at line 271 of file vfp.h.

#define vfp_sign_negate (   sign)    (sign ^ 0x8000)

Definition at line 147 of file vfp.h.

#define VFP_SINGLE_EXPONENT_BITS   (8)

Definition at line 168 of file vfp.h.

#define VFP_SINGLE_LOW_BITS   (32 - VFP_SINGLE_MANTISSA_BITS - 2)

Definition at line 169 of file vfp.h.

#define VFP_SINGLE_LOW_BITS_MASK   ((1 << VFP_SINGLE_LOW_BITS) - 1)

Definition at line 170 of file vfp.h.

#define VFP_SINGLE_MANTISSA_BITS   (23)

Definition at line 167 of file vfp.h.

#define vfp_single_normaliseround (   sd,
  vsd,
  fpscr,
  except,
  func 
)    __vfp_single_normaliseround(sd,vsd,fpscr,except)

Definition at line 248 of file vfp.h.

#define vfp_single_packed_abs (   v)    ((v) & ~0x80000000)

Definition at line 182 of file vfp.h.

#define vfp_single_packed_exponent (   v)    (((v) >> VFP_SINGLE_MANTISSA_BITS) & ((1 << VFP_SINGLE_EXPONENT_BITS) - 1))

Definition at line 183 of file vfp.h.

#define vfp_single_packed_mantissa (   v)    ((v) & ((1 << VFP_SINGLE_MANTISSA_BITS) - 1))

Definition at line 184 of file vfp.h.

#define vfp_single_packed_negate (   v)    ((v) ^ 0x80000000)

Definition at line 181 of file vfp.h.

#define vfp_single_packed_sign (   v)    ((v) & 0x80000000)

Definition at line 180 of file vfp.h.

#define VFP_SINGLE_SIGNIFICAND_QNAN   (1 << (VFP_SINGLE_MANTISSA_BITS - 1 + VFP_SINGLE_LOW_BITS))

Definition at line 175 of file vfp.h.

#define VFP_SNAN   (VFP_NAN|VFP_NAN_SIGNAL)

Definition at line 226 of file vfp.h.

#define VFP_ZERO   (1<<1)

Definition at line 219 of file vfp.h.

Function Documentation

u32 __vfp_single_normaliseround ( int  sd,
struct vfp_single vs,
u32  fpscr,
u32  exceptions 
)

Definition at line 70 of file vfpsingle.c.

u32 vfp_double_normaliseround ( int  dd,
struct vfp_double vd,
u32  fpscr,
u32  exceptions,
const char func 
)

Definition at line 70 of file vfpdouble.c.

u32 vfp_estimate_sqrt_significand ( u32  exponent,
u32  significand 
)

Definition at line 287 of file vfpsingle.c.

u64 vfp_get_double ( unsigned int  reg)
s32 vfp_get_float ( unsigned int  reg)
void vfp_put_double ( u64  val,
unsigned int  reg 
)
void vfp_put_float ( s32  val,
unsigned int  reg 
)
void vfp_save_state ( void location,
u32  fpexc 
)