LLVM
8.0.1
lib
Support
MathExtras.cpp
Go to the documentation of this file.
1
//===-- MathExtras.cpp - Implement the MathExtras header --------------===//
2
//
3
// The LLVM Compiler Infrastructure
4
//
5
// This file is distributed under the University of Illinois Open Source
6
// License. See LICENSE.TXT for details.
7
//
8
//===----------------------------------------------------------------------===//
9
//
10
// This file implements the MathExtras.h header
11
//
12
//===----------------------------------------------------------------------===//
13
14
#include "
llvm/Support/MathExtras.h
"
15
16
#ifdef _MSC_VER
17
#include <limits>
18
#else
19
#include <math.h>
20
#endif
21
22
namespace
llvm
{
23
24
#if defined(_MSC_VER)
25
// Visual Studio defines the HUGE_VAL class of macros using purposeful
26
// constant arithmetic overflow, which it then warns on when encountered.
27
const
float
huge_valf
= std::numeric_limits<float>::infinity();
28
#else
29
const
float
huge_valf =
HUGE_VALF
;
30
#endif
31
32
}
llvm
This class represents lattice values for constants.
Definition:
AllocatorList.h:24
llvm::huge_valf
const float huge_valf
Use this rather than HUGE_VALF; the latter causes warnings on MSVC.
Definition:
MathExtras.cpp:29
MathExtras.h
HUGE_VALF
#define HUGE_VALF
Definition:
DataTypes.h:87
Generated on Sun Dec 20 2020 13:55:56 for LLVM by
1.8.13