diff --git a/tensorflow/lite/micro/fake_micro_context.cc b/tensorflow/lite/micro/fake_micro_context.cc index 4217b1f4d94..8874798896c 100644 --- a/tensorflow/lite/micro/fake_micro_context.cc +++ b/tensorflow/lite/micro/fake_micro_context.cc @@ -181,13 +181,4 @@ const CompressionTensorData* FakeMicroContext::GetTensorCompressionData( #endif // USE_TFLM_COMPRESSION -TfLiteStatus FakeMicroContext::SetAlternateProfiler( - MicroProfilerInterface* alt_profiler) { - return kTfLiteError; -} - -MicroProfilerInterface* FakeMicroContext::GetAlternateProfiler() const { - return nullptr; -} - } // namespace tflite diff --git a/tensorflow/lite/micro/fake_micro_context.h b/tensorflow/lite/micro/fake_micro_context.h index 19702e6b78b..7cf9c682e5c 100644 --- a/tensorflow/lite/micro/fake_micro_context.h +++ b/tensorflow/lite/micro/fake_micro_context.h @@ -73,21 +73,6 @@ class FakeMicroContext : public MicroContext { #endif // USE_TFLM_COMPRESSION - // Set the alternate MicroProfilerInterface. - // This can be used to profile subsystems simultaneously with the profiling - // of kernels during the Eval phase. See (b/379584353). - // The alternate MicroProfilerInterface is currently used by the tensor - // decompression subsystem. - TfLiteStatus SetAlternateProfiler( - MicroProfilerInterface* alt_profiler) override; - - // Get the alternate MicroProfilerInterface. - // This can be used to profile subsystems simultaneously with the profiling - // of kernels during the Eval phase. See (b/379584353). - // The alternate MicroProfilerInterface is currently used by the tensor - // decompression subsystem. - MicroProfilerInterface* GetAlternateProfiler() const override; - private: static constexpr int kNumScratchBuffers_ = 12; diff --git a/tensorflow/lite/micro/micro_context.h b/tensorflow/lite/micro/micro_context.h index 512ddf86ad3..79a34d05374 100644 --- a/tensorflow/lite/micro/micro_context.h +++ b/tensorflow/lite/micro/micro_context.h @@ -132,14 +132,18 @@ class MicroContext { // The alternate MicroProfilerInterface is currently used by the tensor // decompression subsystem. virtual TfLiteStatus SetAlternateProfiler( - MicroProfilerInterface* alt_profiler) = 0; + MicroProfilerInterface* alt_profiler) { + return kTfLiteError; + } // Get the alternate MicroProfilerInterface. // This can be used to profile subsystems simultaneously with the profiling // of kernels during the Eval phase. See (b/379584353). // The alternate MicroProfilerInterface is currently used by the tensor // decompression subsystem. - virtual MicroProfilerInterface* GetAlternateProfiler() const = 0; + virtual MicroProfilerInterface* GetAlternateProfiler() const { + return nullptr; + } private: TF_LITE_REMOVE_VIRTUAL_DELETE