1 /* Copyright 2020 The TensorFlow Authors. All Rights Reserved. 2 3 Licensed under the Apache License, Version 2.0 (the "License"); 4 you may not use this file except in compliance with the License. 5 You may obtain a copy of the License at 6 7 http://www.apache.org/licenses/LICENSE-2.0 8 9 Unless required by applicable law or agreed to in writing, software 10 distributed under the License is distributed on an "AS IS" BASIS, 11 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 See the License for the specific language governing permissions and 13 limitations under the License. 14 ==============================================================================*/ 15 #include "tensorflow/core/tpu/kernels/tpu_compilation_metrics.h" 16 17 namespace tensorflow { 18 namespace tpu { 19 20 // TODO(henrytan): remove this once `TpuCompilationCache` migration to OSS is 21 // completed. 22 #if defined(LIBTPU_ON_GCE) 23 /* static */ IncrementCacheLookupCount(bool is_cache_hit,absl::string_view session_name)24void TpuCompilationMetrics::IncrementCacheLookupCount( 25 bool is_cache_hit, absl::string_view session_name) { 26 // A placeholder for tracking metrics. 27 } 28 29 /* static */ SetCacheEntryCount(int64 count)30void TpuCompilationMetrics::SetCacheEntryCount(int64 count) { 31 // A placeholder for tracking metrics. 32 } 33 34 /* static */ IncrementCompilationCount(absl::string_view session_name)35void TpuCompilationMetrics::IncrementCompilationCount( 36 absl::string_view session_name) { 37 // A placeholder for tracking metrics. 38 } 39 #endif // LIBTPU_ON_GCE 40 41 } // namespace tpu 42 } // namespace tensorflow 43