From f0ba717142aa779a2b76f30cca2e16ac5d27b083 Mon Sep 17 00:00:00 2001 From: Vlad Ivanov Date: Wed, 25 Jan 2017 22:20:26 +0300 Subject: [PATCH] Fix a bunch of missing cmath includes ...as well as missing std:: namespace specifiers --- src/xenia/cpu/compiler/passes/constant_propagation_pass.cc | 5 +++-- src/xenia/gpu/command_processor.cc | 1 + src/xenia/gpu/texture_info.cc | 1 + third_party/llvm/include/llvm/Support/MathExtras.h | 3 ++- 4 files changed, 7 insertions(+), 3 deletions(-) diff --git a/src/xenia/cpu/compiler/passes/constant_propagation_pass.cc b/src/xenia/cpu/compiler/passes/constant_propagation_pass.cc index e1234e13d..40bac4134 100644 --- a/src/xenia/cpu/compiler/passes/constant_propagation_pass.cc +++ b/src/xenia/cpu/compiler/passes/constant_propagation_pass.cc @@ -10,6 +10,7 @@ #include "xenia/cpu/compiler/passes/constant_propagation_pass.h" #include +#include #include "xenia/base/assert.h" #include "xenia/base/profiling.h" @@ -303,10 +304,10 @@ bool ConstantPropagationPass::Run(HIRBuilder* builder) { case OPCODE_IS_NAN: if (i->src1.value->IsConstant()) { if (i->src1.value->type == FLOAT32_TYPE && - isnan(i->src1.value->constant.f32)) { + std::isnan(i->src1.value->constant.f32)) { v->set_constant(uint8_t(1)); } else if (i->src1.value->type == FLOAT64_TYPE && - isnan(i->src1.value->constant.f64)) { + std::isnan(i->src1.value->constant.f64)) { v->set_constant(uint8_t(1)); } else { v->set_constant(uint8_t(0)); diff --git a/src/xenia/gpu/command_processor.cc b/src/xenia/gpu/command_processor.cc index 2ca105c76..73f79923b 100644 --- a/src/xenia/gpu/command_processor.cc +++ b/src/xenia/gpu/command_processor.cc @@ -10,6 +10,7 @@ #include "xenia/gpu/command_processor.h" #include +#include #include "xenia/base/byte_stream.h" #include "xenia/base/logging.h" diff --git a/src/xenia/gpu/texture_info.cc b/src/xenia/gpu/texture_info.cc index 8c226f538..f7f0a5ed4 100644 --- a/src/xenia/gpu/texture_info.cc +++ b/src/xenia/gpu/texture_info.cc @@ -10,6 +10,7 @@ #include "xenia/gpu/texture_info.h" #include +#include #include #include "third_party/xxhash/xxhash.h" diff --git a/third_party/llvm/include/llvm/Support/MathExtras.h b/third_party/llvm/include/llvm/Support/MathExtras.h index 4d2ff0989..92b43bc88 100644 --- a/third_party/llvm/include/llvm/Support/MathExtras.h +++ b/third_party/llvm/include/llvm/Support/MathExtras.h @@ -18,8 +18,9 @@ #ifdef IGNORED_LLVM_XENIA #include "llvm/Support/SwapByteOrder.h" #endif // IGNORED_LLVM_XENIA -#include "llvm/Support/type_traits.h" +#include #include +#include "llvm/Support/type_traits.h" #ifdef _MSC_VER #include