- typedef float Register;
-
- extern Register Exec(const Register & a, const Register & b, Opcode op);
-
+ typedef enum {EVEN=0x00, ZERO=0x01, UP=0x10, DOWN=0x11} Rmode; // Rounding mode; to even, towards zero, always up, always down
+ typedef std::bitset<32> Register;
+ extern Register Exec(const Register & a, const Register & b, Opcode op, Rmode rmode = EVEN); // operate with registers
+ extern float Exec(float a, float b, Opcode op, Rmode rmode = EVEN); //converts floats into registers and back