From b5500b9ca0102f1ccaf32f0e77e96d0739aded9b Mon Sep 17 00:00:00 2001 From: pascal Date: Sat, 3 Sep 2016 22:46:54 +0000 Subject: Use the space freed up by sparc and zaurus to import LLVM. ok hackroom@ --- gnu/llvm/lib/Support/MathExtras.cpp | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 gnu/llvm/lib/Support/MathExtras.cpp (limited to 'gnu/llvm/lib/Support/MathExtras.cpp') diff --git a/gnu/llvm/lib/Support/MathExtras.cpp b/gnu/llvm/lib/Support/MathExtras.cpp new file mode 100644 index 00000000000..ba0924540ce --- /dev/null +++ b/gnu/llvm/lib/Support/MathExtras.cpp @@ -0,0 +1,32 @@ +//===-- MathExtras.cpp - Implement the MathExtras header --------------===// +// +// The LLVM Compiler Infrastructure +// +// This file is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +// +//===----------------------------------------------------------------------===// +// +// This file implements the MathExtras.h header +// +//===----------------------------------------------------------------------===// + +#include "llvm/Support/MathExtras.h" + +#ifdef _MSC_VER +#include +#else +#include +#endif + +namespace llvm { + +#if defined(_MSC_VER) + // Visual Studio defines the HUGE_VAL class of macros using purposeful + // constant arithmetic overflow, which it then warns on when encountered. + const float huge_valf = std::numeric_limits::infinity(); +#else + const float huge_valf = HUGE_VALF; +#endif + +} -- cgit v1.2.3-59-g8ed1b