4 ms·
I get that. std::fmax in C++ is not llvm.maximum. The question I was trying to ask was: so what in C++ is llvm.maximum? (Or what in some other LLVM front-end la
by quietbritishjim 6y ago
I get that. std::fmax in C++ is not llvm.maximum. The question I was trying to ask was: so what in C++ is llvm.maximum? (Or what in some other LLVM front-end language instead of C++, e.g. Rust or Fortran, is llvm.maximum?)
And having answered that, when looking at that C++ code, would I expect it to be well defined even though this bug (if it is a bug) makes it undefined?
- jcranmer 6y agoSo, IEEE 754 took the very unusual step of tossing their old definition of minimum and maximum and replacing them with a new definition. This is effected by deprecating the operations under their old name and introducing new operations with new names. Here, LLVM's intrinsic names are following the IEEE 754 standard names. C and C++ only has the old definition provided in their standard library, although there is a proposal for C2x to add the new comparisons under the names "fmaximum" and "fminimum" (see http://www.open-std.org/jtc1/sc22/wg14/www/docs/n2489.pdf http://www.open-std.org/jtc1/sc22/wg14/www/docs/n2489.pdf).