08-01-2011, 04:01 AM
I have recently implemented the vfpu VFIM instruction on my emulator. And in the process I have seen a couple of things I want to notice:
http://code.google.com/p/pspautotests/so...u/vfpu.elf
- On my constant's test. This is my output:
inf,1.414214,0.707107,1.128379
0.636620,0.318310,0.785398,1.570796
3.141593,2.718282,1.442695,0.434294
0.693147,2.302585,6.283185,0.523599
0.301030,3.321928,0.866025,0.000000
- But on jpcsp the output is:
340282346638528859811704183484516925440.000000,1.414214,0.707107,1.128379
0.636620,0.318310,0.785398,1.570796
3.141593,2.718282,1.442695,0.434294
0.693147,2.302585,6.283185,0.523599
0.301030,3.321928,0.866025,0.000000
It seems that the "inf" (infinity constant) is different.
I tried to run it on my psp to check the real behaviour. But it crashes at the begining. Do you know what could be the problem?
Also, implementing the VFIM instruction I have seen that you are storing the output as if it was VD. But the register number is getted from the place of the VT register. It is really using the VD register? Because if not, prefixes could get wrong. Probably the VD in a different offset, but I wanted to be sure and to avoid headaches in the future. We can also make a test for all the vfpu missing stuff including that. Testing all the instructions, with all the special cases, with prefixes and for example verifying that prefixes only affects to one instruction...
http://code.google.com/p/pspautotests/so...u/vfpu.elf
- On my constant's test. This is my output:
inf,1.414214,0.707107,1.128379
0.636620,0.318310,0.785398,1.570796
3.141593,2.718282,1.442695,0.434294
0.693147,2.302585,6.283185,0.523599
0.301030,3.321928,0.866025,0.000000
- But on jpcsp the output is:
340282346638528859811704183484516925440.000000,1.414214,0.707107,1.128379
0.636620,0.318310,0.785398,1.570796
3.141593,2.718282,1.442695,0.434294
0.693147,2.302585,6.283185,0.523599
0.301030,3.321928,0.866025,0.000000
It seems that the "inf" (infinity constant) is different.
I tried to run it on my psp to check the real behaviour. But it crashes at the begining. Do you know what could be the problem?
Also, implementing the VFIM instruction I have seen that you are storing the output as if it was VD. But the register number is getted from the place of the VT register. It is really using the VD register? Because if not, prefixes could get wrong. Probably the VD in a different offset, but I wanted to be sure and to avoid headaches in the future. We can also make a test for all the vfpu missing stuff including that. Testing all the instructions, with all the special cases, with prefixes and for example verifying that prefixes only affects to one instruction...