Skip to content

Commit

Permalink
removed dependency on util in metadata
Browse files Browse the repository at this point in the history
Signed-off-by: Paul Schumacher <[email protected]>
  • Loading branch information
Paul Schumacher committed Jan 14, 2025
1 parent 063b014 commit 53c5786
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
#define XDP_PLUGIN_SOURCE

#include "aie_profile_metadata.h"
#include "xdp/profile/plugin/aie_profile/util/aie_profile_util.h"

#include <boost/algorithm/string.hpp>
#include <boost/property_tree/json_parser.hpp>
Expand Down Expand Up @@ -266,7 +265,17 @@ namespace xdp {
}
return true;
}


/****************************************************************************
* Check if profile API metric set
***************************************************************************/
bool AieProfileMetadata::profileAPIMetricSet(const std::string metricSet)
{
if ((metricSet == METRIC_BYTE_COUNT) || (metricSet == METRIC_LATENCY))
return true;
return false;
}

/****************************************************************************
* Resolve metrics for AIE or Memory tiles
***************************************************************************/
Expand Down Expand Up @@ -1000,7 +1009,7 @@ namespace xdp {
uint8_t channelId1 = 1;
uint32_t bytes = defaultTransferBytes;
if (metrics[i].size() > 2) {
if (aie::profile::profileAPIMetricSet(metrics[i][1])) {
if (profileAPIMetricSet(metrics[i][1])) {
bytes = processUserSpecifiedBytes(metrics[i][2]);
}
else {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,7 @@ class AieProfileMetadata {
int getPairModuleIndex(const std::string& metricSet, module_type mod);
uint8_t getMetricSetIndex(const std::string& metricSet, module_type mod);
bool isSupported(const std::string metricSet, bool isTileBased);
bool profileAPIMetricSet(const std::string metricSet);

std::map<tile_type, std::string> getConfigMetrics(const int module){ return configMetrics[module];}
std::vector<std::pair<tile_type, std::string>> getConfigMetricsVec(const int module);
Expand Down

0 comments on commit 53c5786

Please sign in to comment.