From 98f522d3e982daafa9ccf136894cc83f496f5a11 Mon Sep 17 00:00:00 2001 From: "A. Unique TensorFlower" Date: Mon, 19 Mar 2018 09:28:58 -0700 Subject: [PATCH] Remove a few unused #includes PiperOrigin-RevId: 189593522 --- tensorflow/compiler/xla/array.h | 1 + tensorflow/compiler/xla/tests/test_macros.cc | 1 + tensorflow/contrib/tensor_forest/kernels/data_spec.h | 1 + tensorflow/core/BUILD | 1 + tensorflow/core/lib/bfloat16/bfloat16.h | 4 ++-- tensorflow/core/lib/io/path.cc | 4 ++-- tensorflow/core/lib/io/path.h | 1 - tensorflow/core/lib/strings/str_util.cc | 2 ++ tensorflow/core/lib/strings/str_util.h | 1 - tensorflow/core/platform/env.cc | 1 - tensorflow/core/platform/file_system.cc | 3 --- tensorflow/core/platform/file_system.h | 1 - tensorflow/core/platform/types.h | 4 ---- 13 files changed, 10 insertions(+), 15 deletions(-) diff --git a/tensorflow/compiler/xla/array.h b/tensorflow/compiler/xla/array.h index 24b58be..ea75ad3 100644 --- a/tensorflow/compiler/xla/array.h +++ b/tensorflow/compiler/xla/array.h @@ -30,6 +30,7 @@ limitations under the License. #include "tensorflow/compiler/xla/status.h" #include "tensorflow/compiler/xla/types.h" #include "tensorflow/core/lib/core/bits.h" +#include "tensorflow/core/lib/gtl/array_slice.h" #include "tensorflow/core/lib/strings/str_util.h" #include "tensorflow/core/lib/strings/strcat.h" #include "tensorflow/core/platform/logging.h" diff --git a/tensorflow/compiler/xla/tests/test_macros.cc b/tensorflow/compiler/xla/tests/test_macros.cc index 978a669..be35ec6 100644 --- a/tensorflow/compiler/xla/tests/test_macros.cc +++ b/tensorflow/compiler/xla/tests/test_macros.cc @@ -21,6 +21,7 @@ limitations under the License. #include #include "tensorflow/core/lib/strings/str_util.h" +#include "tensorflow/core/platform/logging.h" #include "tensorflow/core/platform/regexp.h" namespace xla { diff --git a/tensorflow/contrib/tensor_forest/kernels/data_spec.h b/tensorflow/contrib/tensor_forest/kernels/data_spec.h index 0a3abe5..bb33400 100644 --- a/tensorflow/contrib/tensor_forest/kernels/data_spec.h +++ b/tensorflow/contrib/tensor_forest/kernels/data_spec.h @@ -21,6 +21,7 @@ #include "tensorflow/core/lib/strings/numbers.h" #include "tensorflow/core/lib/strings/str_util.h" +#include "tensorflow/core/platform/logging.h" namespace tensorflow { namespace tensorforest { diff --git a/tensorflow/core/BUILD b/tensorflow/core/BUILD index 14769c3..df44857 100644 --- a/tensorflow/core/BUILD +++ b/tensorflow/core/BUILD @@ -594,6 +594,7 @@ cc_library( "platform/prefetch.h", "platform/thread_annotations.h", "platform/types.h", + "platform/cpu_info.h", ] + if_windows(["platform/windows/integral_types.h"]), visibility = ["//visibility:public"], deps = diff --git a/tensorflow/core/lib/bfloat16/bfloat16.h b/tensorflow/core/lib/bfloat16/bfloat16.h index 6a1cc09..075a8d1 100644 --- a/tensorflow/core/lib/bfloat16/bfloat16.h +++ b/tensorflow/core/lib/bfloat16/bfloat16.h @@ -19,8 +19,8 @@ limitations under the License. #include #include -// We need types.h here in order to pick up __BYTE_ORDER__ from cpu_info.h -#include "tensorflow/core/platform/types.h" +// We need cpu_info.h here in order to pick up __BYTE_ORDER__. +#include "tensorflow/core/platform/cpu_info.h" #ifdef __CUDACC__ // All functions callable from CUDA code must be qualified with __device__ diff --git a/tensorflow/core/lib/io/path.cc b/tensorflow/core/lib/io/path.cc index 83f15e1..996fbf6 100644 --- a/tensorflow/core/lib/io/path.cc +++ b/tensorflow/core/lib/io/path.cc @@ -27,9 +27,9 @@ limitations under the License. #include #include "tensorflow/core/lib/strings/scanner.h" -#include "tensorflow/core/lib/strings/str_util.h" #include "tensorflow/core/lib/strings/strcat.h" -#include "tensorflow/core/platform/env.h" +#include "tensorflow/core/platform/logging.h" +#include "tensorflow/core/platform/mutex.h" namespace tensorflow { namespace io { diff --git a/tensorflow/core/lib/io/path.h b/tensorflow/core/lib/io/path.h index 47bb2b9..818ba99 100644 --- a/tensorflow/core/lib/io/path.h +++ b/tensorflow/core/lib/io/path.h @@ -16,7 +16,6 @@ limitations under the License. #ifndef TENSORFLOW_LIB_IO_PATH_H_ #define TENSORFLOW_LIB_IO_PATH_H_ -#include "tensorflow/core/lib/core/status.h" #include "tensorflow/core/lib/core/stringpiece.h" namespace tensorflow { diff --git a/tensorflow/core/lib/strings/str_util.cc b/tensorflow/core/lib/strings/str_util.cc index 9dbb74f..2c9e983 100644 --- a/tensorflow/core/lib/strings/str_util.cc +++ b/tensorflow/core/lib/strings/str_util.cc @@ -16,9 +16,11 @@ limitations under the License. #include "tensorflow/core/lib/strings/str_util.h" #include +#include #include #include "tensorflow/core/lib/strings/numbers.h" #include "tensorflow/core/lib/strings/stringprintf.h" +#include "tensorflow/core/platform/logging.h" namespace tensorflow { namespace str_util { diff --git a/tensorflow/core/lib/strings/str_util.h b/tensorflow/core/lib/strings/str_util.h index f062edd..065871c 100644 --- a/tensorflow/core/lib/strings/str_util.h +++ b/tensorflow/core/lib/strings/str_util.h @@ -20,7 +20,6 @@ limitations under the License. #include #include #include "tensorflow/core/lib/core/stringpiece.h" -#include "tensorflow/core/lib/gtl/array_slice.h" #include "tensorflow/core/lib/strings/strcat.h" #include "tensorflow/core/platform/types.h" diff --git a/tensorflow/core/platform/env.cc b/tensorflow/core/platform/env.cc index 12509c2..b9a9ef8 100644 --- a/tensorflow/core/platform/env.cc +++ b/tensorflow/core/platform/env.cc @@ -33,7 +33,6 @@ limitations under the License. #endif #include "tensorflow/core/lib/core/errors.h" -#include "tensorflow/core/lib/gtl/map_util.h" #include "tensorflow/core/lib/gtl/stl_util.h" #include "tensorflow/core/lib/io/path.h" #include "tensorflow/core/lib/strings/stringprintf.h" diff --git a/tensorflow/core/platform/file_system.cc b/tensorflow/core/platform/file_system.cc index 271d73f..5bc8606 100644 --- a/tensorflow/core/platform/file_system.cc +++ b/tensorflow/core/platform/file_system.cc @@ -19,15 +19,12 @@ limitations under the License. #include "tensorflow/core/lib/core/errors.h" #include "tensorflow/core/lib/core/threadpool.h" -#include "tensorflow/core/lib/gtl/map_util.h" -#include "tensorflow/core/lib/gtl/stl_util.h" #include "tensorflow/core/lib/io/path.h" #include "tensorflow/core/lib/strings/str_util.h" #include "tensorflow/core/lib/strings/strcat.h" #include "tensorflow/core/platform/env.h" #include "tensorflow/core/platform/file_system.h" #include "tensorflow/core/platform/platform.h" -#include "tensorflow/core/platform/protobuf.h" namespace tensorflow { diff --git a/tensorflow/core/platform/file_system.h b/tensorflow/core/platform/file_system.h index 3085b69..03c0c5a 100644 --- a/tensorflow/core/platform/file_system.h +++ b/tensorflow/core/platform/file_system.h @@ -27,7 +27,6 @@ limitations under the License. #include "tensorflow/core/platform/file_statistics.h" #include "tensorflow/core/platform/macros.h" #include "tensorflow/core/platform/platform.h" -#include "tensorflow/core/platform/protobuf.h" #include "tensorflow/core/platform/types.h" #ifdef PLATFORM_WINDOWS diff --git a/tensorflow/core/platform/types.h b/tensorflow/core/platform/types.h index 38d75db..6308e588 100644 --- a/tensorflow/core/platform/types.h +++ b/tensorflow/core/platform/types.h @@ -31,10 +31,6 @@ limitations under the License. #error Define the appropriate PLATFORM_ macro for this platform #endif -#if defined(PLATFORM_WINDOWS) -#include "tensorflow/core/platform/windows/cpu_info.h" -#endif - namespace tensorflow { // Define tensorflow::string to refer to appropriate platform specific type. -- 2.7.4