First post, by canadacow
Sooo... I've been working on optimizing the code associated with the MT-32. I consider the low-pass filter, which presently uses floating point code, as a bottleneck in my program's execution. So, today I tried to make an interger/fixed point version of the routine. I discovered that fixed point 32 bit integers are not precise enough for the filter. I tried instead to use 64 bit integers within Visual C (__int64). Using a fixed point of 20 bits I was able to gain enough precision for the filter to work. Interestingly, however, it doesn't seem that the 64 bit integer version is any faster than the floating point version. Infact, a disassembly listing shows that the floating point version has fewer instructions (though I don't know what it comes out to cycle wise) than the 64 bit instructions. It seems for any multiplications and shifts, C has to resort to function calls to do the 64 bit math. I'm sure this slows it down a good bit. Anyone out there have any suggestions on what I could do? Anyone have any experience with high precision and fixed point math?