reactos/sdk/lib
Colin Finck bd0a28d1e4 Fix the MSVC version of ldexp filling up the FPU stack and bailing out with #IND after a few calls. Additionally, add it back to libcntpr.
MSVC was previously given a "result" variable to copy the fscale result from st(0). This led to another "fld" FPU stack push at the very end without popping the source value from the FPU stack.
Moreover, this copy isn't even needed: A simple "fstp st(1)" at the end pops an element from the FPU stack while effectively storing the result in st(0), the register used for returning a double value.
This problem didn't affect GCC, as it is only given the "fscale" instruction and does all necessary stack operations itself.

However, looking into the CRT sources, I found many other i386 implementations with inline assembly suffering from the same problem.
Fortunately, they have been replaced by pure assembly implementations a while ago, so it's time to finally remove them.
ldexp would have also been a candidate for a pure assembly implementation, but the required check for NaN and setting errno (verified on Win2003) already outweighs the benefits.
And we cannot just do a NaN check with FUCOMI as this is an i686/pentiumpro instruction while we're still targeting i586/pentium.

I'm also using this opportunity to clean up the ldexp.c header and only put in the remaining contributors as returned by "git blame".

Thanks to NightWolve1975 for reporting the problem! (https://twitter.com/nightwolve1975/status/1099042477531643912)
2019-03-03 16:11:27 +01:00
..
3rdparty [FREETYPE] Handle allocation failures in our stack-saving hacks. CORE-15642 2019-01-28 14:31:49 +01:00
atl [ATL] Add GET_X_LPARAM and GET_Y_LPARAM to atlwin.h 2019-01-15 14:34:53 +02:00
cmlib [CMLIB] Assign a signature to the in-memory HHIVE registry hive structure. CORE-15753 2019-02-17 01:21:37 +01:00
comsupp Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
conutils [CONUTILS] In ConWrite(), emit an \r when a \n is encountered but not already preceded by \r. 2018-08-23 17:04:53 +02:00
cportlib Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
cpprt [CPPRT] Implement __std_terminate wrapper for Clang-CL 2019-02-12 19:31:33 +01:00
crt Fix the MSVC version of ldexp filling up the FPU stack and bailing out with #IND after a few calls. Additionally, add it back to libcntpr. 2019-03-03 16:11:27 +01:00
cryptlib Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
debugsup Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
delayimp [DELAYIMP] Fix/Merge definitions of __pfnDliNotifyHook2 and __pfnDliFailureHook2 2018-06-13 23:28:15 +02:00
dmilib [DRWTSN32] Add SMBIOS data to the system information (#1017) 2018-11-21 21:49:15 +01:00
dnslib Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
drivers [RXCE] Fix leftover 2019-01-03 16:59:45 +01:00
dxguid Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
epsapi Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
evtlib [EVTLIB] Silence some DPRINTs. 2018-04-22 02:53:40 +02:00
fast486 [REACTOS] Fix misc 64 bit issues (#783) 2019-01-05 10:50:11 +01:00
fslib [VFATLIB] Don't forcibly delete LFN when not in RW mode 2019-02-14 10:13:32 +01:00
gcc_ssp Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
inflib [SDK] Fix 64 bit issues 2018-07-01 14:45:21 +02:00
ioevent Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
lsalib Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
nt Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
ppcmmu Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
pseh Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
rossym [NTOSKRNL][ROSSYM] ZwReadFile() calls: Use explicit NULL instead of ambiguous 0. CORE-13910 2017-10-27 13:38:02 +02:00
rossym_new [NTOSKRNL][ROSSYM] ZwReadFile() calls: Use explicit NULL instead of ambiguous 0. CORE-13910 2017-10-27 13:38:02 +02:00
rtl [RTL] Fix GCC build. 2019-02-17 09:59:49 +01:00
runtmchk Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
scrnsave Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
skiplist [SDK] Fix 64 bit issues 2018-07-01 14:45:21 +02:00
smlib Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
strmiids Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
tdilib [TDILIB] Make tdiGetSetOfThings() return useful status 2018-11-18 16:30:45 +01:00
udmihelp [DRWTSN32] Add SMBIOS data to the system information (#1017) 2018-11-21 21:49:15 +01:00
uuid [NTDLL] Check the process manifest at startup for a compatibility section. 2018-04-09 19:36:09 +02:00
wdmguid Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
CMakeLists.txt [SDK] Add user-mode DMI/SMBIOS helper library 2018-08-12 14:21:56 +02:00