[rocprof-sys] Refactor trace_cache architecture with improved type erasure and processing pipeline (#1710)

- Redesigned buffer_storage with a flush_worker pattern for better thread management and resource cleanup
- Introduced type-safe abstractions through new components: cacheable.hpp, cache_type_traits.hpp, sample_processor.hpp, and type_registry.hpp
- Optimized type erasure implementation in sample processor to reduce runtime overhead
- Renamed rocpd_post_processing to rocpd_processor and restructured the processing pipeline
- Removed storage_parser.cpp and integrated functionality into header-based template implementation
- Enhanced cache_manager with improved processing workflow and better separation of concerns
Tento commit je obsažen v:
Milan Radosavljevic
2025-11-20 20:18:13 +01:00
odevzdal GitHub
rodič 2f6fb89c51
revize 4d670099fa
27 změnil soubory, kde provedl 2876 přidání a 1854 odebrání
+3 -3
Zobrazit soubor
@@ -45,7 +45,7 @@
#include "core/rocpd/data_processor.hpp"
#include "core/timemory.hpp"
#include "core/trace_cache/cache_manager.hpp"
#include "core/trace_cache/cache_utility.hpp"
#include "core/trace_cache/cacheable.hpp"
#include "core/trace_cache/metadata_registry.hpp"
#include "core/utility.hpp"
#include "library/causal/data.hpp"
@@ -578,7 +578,7 @@ rocprofsys_init_tooling_hidden(void)
ROCPROFSYS_DEBUG_F("State: %s -> State::Active\n",
std::to_string(get_state()).c_str());
trace_cache::get_buffer_storage().start_flushing_thread(getpid());
trace_cache::get_buffer_storage().start(getpid());
set_state(State::Active); // set to active as very last operation
} };
@@ -798,7 +798,7 @@ rocprofsys_finalize_hidden(void)
const auto _agents = get_agent_manager_instance().get_agents();
_manager.shutdown();
const auto metadata_filepath =
trace_cache::get_metadata_filepath(get_root_process_id(), getpid());
trace_cache::utility::get_metadata_filepath(get_root_process_id(), getpid());
_manager.get_metadata_registry().save_to_file(metadata_filepath, _agents);
std::quick_exit(EXIT_SUCCESS);