message: Always check if the graph is fully delegated when a delegate is applied, and outputs the check result.
diff: @@ -622,7 +622,6 @@ TfLiteStatus BenchmarkTfLiteModel::Init() {
  TFLITE_LOG(ERROR) << "Failed to apply " << delegate.first << " delegate.";
  return kTfLiteError;
  } else {
  - if (params_.Get<bool>("require_full_delegation")) {
  bool fully_delegated = true;
  if (interpreter_->execution_plan().size() != 1) {
  fully_delegated = false;
  @@ -634,14 +633,15 @@ TfLiteStatus BenchmarkTfLiteModel::Init() {
  fully_delegated = false;
  }
  }
  -
  - if (!fully_delegated) {
  + if (params_.Get<bool>("require_full_delegation") && !fully_delegated) {
  TFLITE_LOG(ERROR) << "Disallowed CPU fallback detected.";
  return kTfLiteError;
  }
  - }
  -
  - TFLITE_LOG(INFO) << "Applied " << delegate.first << " delegate.";
  + const std::string delegate_status =
  + fully_delegated ? "completely" : "partially";
  + TFLITE_LOG(INFO) << "Applied " << delegate.first
  + << " delegate, and the model graph will be "
  + << delegate_status << " executed w/ the delegate.";
  }
  }
  