diff options
author | Zahira Ammarguellat <zahira.ammarguellat@intel.com> | 2023-03-09 09:24:01 -0500 |
---|---|---|
committer | Zahira Ammarguellat <zahira.ammarguellat@intel.com> | 2023-03-10 14:44:06 -0500 |
commit | 2f1264260b37e9bd79737181e459ae20e10c5fea (patch) | |
tree | 25fb7d8dd2a632ad4d613b51d8e19da911c30f42 /clang/lib/Lex/Preprocessor.cpp | |
parent | 99b7c2bad3e5898353223c4682dce8ce31a69f30 (diff) | |
download | llvm-2f1264260b37e9bd79737181e459ae20e10c5fea.zip llvm-2f1264260b37e9bd79737181e459ae20e10c5fea.tar.gz llvm-2f1264260b37e9bd79737181e459ae20e10c5fea.tar.bz2 |
Revert "Currently the control of the eval-method is mixed with fast-math."
Setting __FLT_EVAL_METHOD__ to -1 with fast-math will set
__GLIBC_FLT_EVAL_METHOD to 2 and long double ends up being used for
float_t and double_t. This creates some ABI breakage with various C libraries.
See details here: https://github.com/llvm/llvm-project/issues/60781
This reverts commit bbf0d1932a3c1be970ed8a580e51edf571b80fd5.
Diffstat (limited to 'clang/lib/Lex/Preprocessor.cpp')
-rw-r--r-- | clang/lib/Lex/Preprocessor.cpp | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/clang/lib/Lex/Preprocessor.cpp b/clang/lib/Lex/Preprocessor.cpp index 27be7d6..8de78a1 100644 --- a/clang/lib/Lex/Preprocessor.cpp +++ b/clang/lib/Lex/Preprocessor.cpp @@ -207,11 +207,6 @@ void Preprocessor::Initialize(const TargetInfo &Target, else // Set initial value of __FLT_EVAL_METHOD__ from the command line. setCurrentFPEvalMethod(SourceLocation(), getLangOpts().getFPEvalMethod()); - // When `-ffast-math` option is enabled, it triggers several driver math - // options to be enabled. Among those, only one the following two modes - // affect the eval-method: reciprocal or reassociate. - if (getLangOpts().AllowFPReassoc || getLangOpts().AllowRecip) - setCurrentFPEvalMethod(SourceLocation(), LangOptions::FEM_Indeterminable); } void Preprocessor::InitializeForModelFile() { |