Forum Discussion
Altera_Forum
Honored Contributor
15 years agoNIOS2 HW & DIV Instructions + FPU
Hello i am in charge of designing a system that does a lot of complex sin/cos/* instructions and i need them to be fast. I am using NIOS2-F at 100mhz in a Cyclone IV. I've enabled HW and DIV ...
Altera_Forum
Honored Contributor
15 years agoI am using the 60-1 and 60-2 flags without having a FPU added to the Nios II core.
I made this tests to see if float operations are working
static float legal;
static float legal2;
legal = 3.4;
legal2 = 2;
log_msg("Multiplicando: %f -- Dividindo: %f", legal * legal2, legal/legal2);
legal = 4;
legal2 = 2.3;
log_msg("Multiplicando: %f -- Dividindo: %f", legal * legal2, legal/legal2);
legal = 4.5;
legal2 = 2.3;
log_msg("Multiplicando: %f -- Dividindo: %f", legal * legal2, legal/legal2);
legal = 4.3148981934;
legal2 = 2.313319843;
log_msg("Multiplicando: %f -- Dividindo: %f", legal * legal2, legal/legal2);
legal = 4.3148981934;
legal2 = 2.313319843;
The results were all good.. is my test right? If i remove those flags my processing suffer a lot of loss