Request: Long double (80bit) functions in x86/x64 assembly for WinUAE
Another weird request, eab probably is wrong forum but...
Because MSVC does not support long doubles (they are alias to double. No, don't discuss any reasons here!) and I'd like to have host FPU emulated long double support (not everyone wants or needs slower bit perfect softfloat floating point emulation). So I'd like to do following ugly solution: I need x86/x64 assembly file that has functions for each basic floating point function that takes two parameters, input (pointer to long double) and output (also pointer to long double) For example following C code in x86/x64 assemly: Code:
void fadd(void *srclongdouble, void *dstlongdouble) Same for all other basic floating point functions. (sub, neg, mul, div etc..) but I am sure I can do them if I have one simple example (fadd) that handles weird x86 FPU stack stuff I don't want to know... And functions to convert long double to int/double and back. |
Apologies as it's not exactly what you are after but have you considered the Berkeley Soft Float library? http://www.jhauser.us/arithmetic/SoftFloat.html It supports 80-bit double precision.
At worst it might be useful to compile it and see what the resulting assembly looks like for the functions you are after if noone can help. |
Softfloat is already used in softfloat mode but it is much slower than native FPU because it needs lots of integer calculations, some of them need to be 128 bit wide.
I want to use host FPU directly. EDIT: I think I finally got it. (also: x86 syntax is ugly) |
All times are GMT +2. The time now is 06:49. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.