-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make --enable-imprecise-c99-float-ops the default on CPU that doesn't support FMA #12513
Comments
As I understand, the idea was to have an explicit opt-in from the user since the "imprecise" C99 emulations can give you incorrect results and so introduce bugs in your program. |
Technically, this behavior is not tied to hardware support for FMA: OCaml goes through the |
Indeed - Further reading reveals that Microsoft didn't fix the software version of
I was already working on this, and have finished off two proposals. For 4.14, I suggest #12518 which just makes the emulation automatic in VirtualBox or on older hardware. The 4.14 solution is a bit disappointing for VirtualBox, given that it's only the detection of the hardware support which fails, not the actual support itself. Therefore, for trunk, in #12519, I propose unconditionally requiring hardware support for FMA on Windows, which results in considerable simplifications of both the configuration and, more importantly, the runtime. |
FWIW (as another data point), I have also run into this bug trying to compile with Cygwin on Windows (as part of So there's at least 2 people using OCaml on Windows on pre-Haswell hardware :P. |
@cr1901 - I think what's likely to happen is that were you to use |
I can work with that. I've seen the horror stories of floating point and can deal with "please use a not-ancient CPU" for floating point. My intended use case for installing OCaml after not using it since 2020 (before a clean install) is for SAIL. That doesn't use
Once upon a time I ran MATLAB heavily on this CPU, but those days are long gone :D. |
While calling
./configure
on my desktop (Intel Core i5-750) on Windows with MSVC i get the following error:using
--enable-imprecise-c99-float-ops
works fine but given my CPU doesn't support FMA I would expect this option to be the default on such hardware as there is no way to have precise float operations on it.According to https://en.wikipedia.org/wiki/FMA_instruction_set, anything pre-Haswell (Intel) or pre-Piledriver (AMD) does not have it.
This is also a common issue encountered by people running Windows inside emulators such as VirtualBox: diskuv/dkml-installer-ocaml#23. cc @jonahbeckford
The text was updated successfully, but these errors were encountered: