AI Engine-ML Intrinsics User Guide  (v2023.2)

Overview

Mode setting intrinsics to get and set bits in the control and status register.

The rounding and saturation in the srs intrinsics (Shift-Round-Saturate) is controlled through special mode setting commands.

Modules

 Control registers
 Intrinsics to set,get and clear the control registers.
 
 Status registers
 Intrinsics to set,get and clear the status registers.
 

Rounding Modes

#define rnd_floor   0
 No rounding - Truncate LSB, always round down (towards negative infinity) More...
 
#define rnd_ceil   1
 No rounding - Always round up (towards positive infinity) More...
 
#define rnd_sym_floor   2
 No rounding - Truncate LSB, always round towards 0. More...
 
#define rnd_sym_ceil   3
 No rounding - Always round up towards infinity. More...
 
#define rnd_neg_inf   8
 Round halfway towards negative infinity. More...
 
#define rnd_pos_inf   9
 Round halfway towards positive infinity. More...
 
#define rnd_sym_zero   10
 Round halfway towards zero (away from infinity) More...
 
#define rnd_sym_inf   11
 Round halfway towards infinity (away from zero) More...
 
#define rnd_conv_even   12
 Round halfway towards nearest even number. More...
 
#define rnd_conv_odd   13
 Round halfway towards nearest odd number. More...
 

Macro Definition Documentation

◆ rnd_ceil

#define rnd_ceil   1

No rounding - Always round up (towards positive infinity)

◆ rnd_conv_even

#define rnd_conv_even   12

Round halfway towards nearest even number.

◆ rnd_conv_odd

#define rnd_conv_odd   13

Round halfway towards nearest odd number.

◆ rnd_floor

#define rnd_floor   0

No rounding - Truncate LSB, always round down (towards negative infinity)

◆ rnd_neg_inf

#define rnd_neg_inf   8

Round halfway towards negative infinity.

◆ rnd_pos_inf

#define rnd_pos_inf   9

Round halfway towards positive infinity.

◆ rnd_sym_ceil

#define rnd_sym_ceil   3

No rounding - Always round up towards infinity.

◆ rnd_sym_floor

#define rnd_sym_floor   2

No rounding - Truncate LSB, always round towards 0.

◆ rnd_sym_inf

#define rnd_sym_inf   11

Round halfway towards infinity (away from zero)

◆ rnd_sym_zero

#define rnd_sym_zero   10

Round halfway towards zero (away from infinity)