Hacker News new | ask | show | jobs
by vunderba 14 days ago
I saw your reply was deleted, so I'm responding here just for future interesting info:

QuickBASIC 4.5 is not QBASIC. QB 4.5 will use a real x87 if it finds one.

On builds where DOSBox's FPU is only 64-bit (MSVC builds, ARM builds too), you'll get that drift you were describing describing. (X# 50, 49.99999999999)

I ran into the same thing when I was working on this a few months ago.

QBASIC.EXE is different. Its math is written as x87 code, but the linker swaps every FPU opcode for an INT 34h down to Microsoft's software emulator which is built into the interpreter.