diff --git a/tsl/platform/abi.cc b/tsl/platform/abi.cc index 889e02f19..de1fc57c3 100644 --- a/tsl/platform/abi.cc +++ b/tsl/platform/abi.cc @@ -15,8 +15,6 @@ limitations under the License. #include "tsl/platform/abi.h" -#include "xla/tsl/platform/types.h" - #if defined(_MSC_VER) #include #include @@ -45,7 +43,7 @@ std::string MaybeAbiDemangle(const char* name) { std::free, static_cast(0))}; - return string(demangled.get() != nullptr ? demangled.get() : name); + return std::string(demangled.get() != nullptr ? demangled.get() : name); #else int status = 0; std::unique_ptr res{ diff --git a/tsl/platform/cpu_info.cc b/tsl/platform/cpu_info.cc index 71f7f8f56..b5f964313 100644 --- a/tsl/platform/cpu_info.cc +++ b/tsl/platform/cpu_info.cc @@ -15,6 +15,8 @@ limitations under the License. #include "tsl/platform/cpu_info.h" +#include + // Required for cross compile with clang #ifdef PLATFORM_WINDOWS #include @@ -24,7 +26,6 @@ limitations under the License. #include "absl/base/call_once.h" #include "xla/tsl/platform/logging.h" -#include "xla/tsl/platform/types.h" #include "tsl/platform/platform.h" #if defined(PLATFORM_IS_X86) #include // NOLINT @@ -70,7 +71,7 @@ namespace { class CPUIDInfo; void InitCPUIDInfo(); -CPUIDInfo *cpuid = nullptr; +CPUIDInfo* cpuid = nullptr; #ifdef PLATFORM_WINDOWS // Visual Studio defines a builtin function, so use that if possible. @@ -144,9 +145,9 @@ class CPUIDInfo { // Get vendor string (issue CPUID with eax = 0) GETCPUID(eax, ebx, ecx, edx, 0, 0); - cpuid->vendor_str_.append(reinterpret_cast(&ebx), 4); - cpuid->vendor_str_.append(reinterpret_cast(&edx), 4); - cpuid->vendor_str_.append(reinterpret_cast(&ecx), 4); + cpuid->vendor_str_.append(reinterpret_cast(&ebx), 4); + cpuid->vendor_str_.append(reinterpret_cast(&edx), 4); + cpuid->vendor_str_.append(reinterpret_cast(&ecx), 4); // To get general information and extended features we send eax = 1 and // ecx = 0 to cpuid. The response is returned in eax, ebx, ecx and edx. @@ -385,7 +386,7 @@ class CPUIDInfo; void InitCPUIDInfo(); void InitCPUIDFeatureInfo(); -CPUIDInfo *cpuid = nullptr; +CPUIDInfo* cpuid = nullptr; // Structure for basic CPUID info. class CPUIDInfo { @@ -444,7 +445,7 @@ class CPUIDInfo { if (midr_el1_file.is_open()) { std::string line; if (static_cast(getline(midr_el1_file, line))) { - uint32 midr_el1 = std::stoul(line, nullptr, 16); + uint32_t midr_el1 = std::stoul(line, nullptr, 16); // Unpack variant and CPU ID. // Reference: diff --git a/tsl/platform/demangle.h b/tsl/platform/demangle.h index 8171be236..91a70b69a 100644 --- a/tsl/platform/demangle.h +++ b/tsl/platform/demangle.h @@ -16,7 +16,7 @@ limitations under the License. #ifndef TENSORFLOW_TSL_PLATFORM_DEMANGLE_H_ #define TENSORFLOW_TSL_PLATFORM_DEMANGLE_H_ -#include "xla/tsl/platform/types.h" +#include namespace tsl { namespace port { diff --git a/tsl/platform/human_readable_json.h b/tsl/platform/human_readable_json.h index 897a6b110..1ba279432 100644 --- a/tsl/platform/human_readable_json.h +++ b/tsl/platform/human_readable_json.h @@ -20,7 +20,6 @@ limitations under the License. #include "absl/status/status.h" #include "absl/status/statusor.h" -#include "xla/tsl/platform/types.h" #include "tsl/platform/protobuf.h" namespace tsl { diff --git a/tsl/platform/mem.h b/tsl/platform/mem.h index d2b3286f0..a018cfb02 100644 --- a/tsl/platform/mem.h +++ b/tsl/platform/mem.h @@ -23,7 +23,6 @@ limitations under the License. // TODO(cwhipkey): remove this when callers use annotations directly. #include "absl/base/macros.h" #include "xla/tsl/platform/dynamic_annotations.h" -#include "xla/tsl/platform/types.h" #include "tsl/platform/platform.h" namespace tsl { diff --git a/tsl/platform/snappy.h b/tsl/platform/snappy.h index aa292e190..8618abb21 100644 --- a/tsl/platform/snappy.h +++ b/tsl/platform/snappy.h @@ -16,7 +16,9 @@ limitations under the License. #ifndef TENSORFLOW_TSL_PLATFORM_SNAPPY_H_ #define TENSORFLOW_TSL_PLATFORM_SNAPPY_H_ -#include "xla/tsl/platform/types.h" +#include + +#include "tsl/platform/platform.h" #if !defined(PLATFORM_WINDOWS) #include diff --git a/tsl/platform/tracing.h b/tsl/platform/tracing.h index 89728d4d3..80084234f 100644 --- a/tsl/platform/tracing.h +++ b/tsl/platform/tracing.h @@ -21,7 +21,6 @@ limitations under the License. #include #include "xla/tsl/platform/macros.h" -#include "xla/tsl/platform/types.h" #include "tsl/platform/platform.h" #include "tsl/platform/stringpiece.h"