diff --git a/lldb/source/DataFormatters/FormatManager.cpp b/lldb/source/DataFormatters/FormatManager.cpp --- a/lldb/source/DataFormatters/FormatManager.cpp +++ b/lldb/source/DataFormatters/FormatManager.cpp @@ -596,15 +596,24 @@ return retval_sp; } +namespace { +template const char *FormatterKind; +template <> const char *FormatterKind = "format"; +template <> const char *FormatterKind = "summary"; +template <> const char *FormatterKind = "synthetic"; +} // namespace + template ImplSP FormatManager::Get(ValueObject &valobj, lldb::DynamicValueType use_dynamic) { + Log *log = GetLog(LLDBLog::DataFormatters); + LLDB_LOGF(log, "\n\n[%s] Begin %s lookup.", __FUNCTION__, + FormatterKind); + FormattersMatchData match_data(valobj, use_dynamic); if (ImplSP retval_sp = GetCached(match_data)) return retval_sp; - Log *log = GetLog(LLDBLog::DataFormatters); - LLDB_LOGF(log, "[%s] Search failed. Giving language a chance.", __FUNCTION__); for (lldb::LanguageType lang_type : match_data.GetCandidateLanguages()) { if (LanguageCategory *lang_category = GetCategoryForLanguage(lang_type)) { @@ -628,7 +637,7 @@ ImplSP retval_sp; Log *log = GetLog(LLDBLog::DataFormatters); if (match_data.GetTypeForCache()) { - LLDB_LOGF(log, "\n\n[%s] Looking into cache for type %s", __FUNCTION__, + LLDB_LOGF(log, "[%s] Looking into cache for type %s", __FUNCTION__, match_data.GetTypeForCache().AsCString("")); if (m_format_cache.Get(match_data.GetTypeForCache(), retval_sp)) { if (log) {