Skip to content

Commit

Permalink
Update kp_nvtx_focused_connector.cpp
Browse files Browse the repository at this point in the history
Fixing function names to be nvtx
  • Loading branch information
vlkale authored Jul 20, 2023
1 parent 164f317 commit e102e0d
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions profiling/nvprof-focused-connector/kp_nvtx_focused_connector.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,15 @@
#include <cxxabi.h>
#include <cuda_profiler_api.h>

#include "kp_nvprof_focused_connector_domain.h"
#include "kp_nvtx_focused_connector_domain.h"

#include "kp_core.hpp"

namespace KokkosTools {
namespace NVProfFocusedConnector {
namespace NVTXFocusedConnector {

static KernelNVProfFocusedConnectorInfo* currentKernel;
static std::unordered_map<std::string, KernelNVProfFocusedConnectorInfo*>
static KernelNVTXFocusedConnectorInfo* currentKernel;
static std::unordered_map<std::string, KernelNVTXFocusedConnectorInfo*>
domain_map;
static uint64_t nextKernelID;

Expand All @@ -40,22 +40,22 @@ void kokkosp_init_library(
struct Kokkos_Profiling_KokkosPDeviceInfo* deviceInfo) {
printf("-----------------------------------------------------------\n");
printf(
"KokkosP: NVProf Analyzer Focused Connector (sequence is %d, version: "
"KokkosP: NVTX Analyzer Focused Connector (sequence is %d, version: "
"%llu)\n",
loadSeq, interfaceVer);
printf("-----------------------------------------------------------\n");

nextKernelID = 0;
}

KernelNVProfFocusedConnectorInfo* getFocusedConnectorInfo(
KernelNVTXFocusedConnectorInfo* getFocusedConnectorInfo(
const char* name, KernelExecutionType kType) {
std::string nameStr(name);
auto kDomain = domain_map.find(nameStr);
currentKernel = NULL;

if (kDomain == domain_map.end()) {
currentKernel = new KernelNVProfFocusedConnectorInfo(name, kType);
currentKernel = new KernelNVTXFocusedConnectorInfo(name, kType);
domain_map.insert(std::pair<std::string, KernelNVProfFocusedConnectorInfo*>(
nameStr, currentKernel));
} else {
Expand Down Expand Up @@ -138,7 +138,7 @@ Kokkos::Tools::Experimental::EventSet get_event_set() {

extern "C" {

namespace impl = KokkosTools::NVProfFocusedConnector;
namespace impl = KokkosTools::NVTXFocusedConnector;

EXPOSE_INIT(impl::kokkosp_init_library)
EXPOSE_FINALIZE(impl::kokkosp_finalize_library)
Expand Down

0 comments on commit e102e0d

Please sign in to comment.