1//===--- FPOptions.def - Floating Point Options database --------*- C++ -*-===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8
9// This file defines the Floating Point language options. Users of this file
10// must define the FP_OPTION macro to make use of this information.
11#ifndef FP_OPTION
12# error Define the FP_OPTION macro to handle floating point language options
13#endif
14
15// FP_OPTION(name, type, width, previousName)
16FP_OPTION(FPContractMode, LangOptions::FPModeKind, 2, First)
17FP_OPTION(RoundingMath, bool, 1, FPContractMode)
18FP_OPTION(ConstRoundingMode, LangOptions::RoundingMode, 3, RoundingMath)
19FP_OPTION(SpecifiedExceptionMode, LangOptions::FPExceptionModeKind, 2, ConstRoundingMode)
20FP_OPTION(AllowFEnvAccess, bool, 1, SpecifiedExceptionMode)
21FP_OPTION(AllowFPReassociate, bool, 1, AllowFEnvAccess)
22FP_OPTION(NoHonorNaNs, bool, 1, AllowFPReassociate)
23FP_OPTION(NoHonorInfs, bool, 1, NoHonorNaNs)
24FP_OPTION(NoSignedZero, bool, 1, NoHonorInfs)
25FP_OPTION(AllowReciprocal, bool, 1, NoSignedZero)
26FP_OPTION(AllowApproxFunc, bool, 1, AllowReciprocal)
27FP_OPTION(FPEvalMethod, LangOptions::FPEvalMethodKind, 2, AllowApproxFunc)
28FP_OPTION(Float16ExcessPrecision, LangOptions::ExcessPrecisionKind, 2, FPEvalMethod)
29FP_OPTION(BFloat16ExcessPrecision, LangOptions::ExcessPrecisionKind, 2, Float16ExcessPrecision)
30FP_OPTION(MathErrno, bool, 1, BFloat16ExcessPrecision)
31FP_OPTION(ComplexRange, LangOptions::ComplexRangeKind, 3, MathErrno)
32#undef FP_OPTION
33