From a8de26c31a8f9065ac52a44bd500b1bbe0136caa Mon Sep 17 00:00:00 2001 From: HGuillemet Date: Thu, 22 Aug 2024 16:33:33 +0200 Subject: [PATCH] * Add presets for the CUPTI module of CUDA (pull #1531) --- CHANGELOG.md | 1 + .../bytedeco/cuda/cupti/CUpti_Activity.java | 51 + .../cuda/cupti/CUpti_ActivityAPI.java | 92 + .../cupti/CUpti_ActivityAutoBoostState.java | 54 + .../cuda/cupti/CUpti_ActivityBranch2.java | 87 + .../cuda/cupti/CUpti_ActivityCdpKernel.java | 218 + .../cuda/cupti/CUpti_ActivityContext3.java | 91 + .../cuda/cupti/CUpti_ActivityCudaEvent.java | 69 + .../cuda/cupti/CUpti_ActivityDevice5.java | 245 + .../cupti/CUpti_ActivityDeviceAttribute.java | 79 + .../cuda/cupti/CUpti_ActivityEnvironment.java | 120 + .../cuda/cupti/CUpti_ActivityEvent.java | 70 + .../cupti/CUpti_ActivityEventInstance.java | 85 + .../CUpti_ActivityExternalCorrelation.java | 69 + .../cuda/cupti/CUpti_ActivityFunction.java | 79 + .../cupti/CUpti_ActivityGlobalAccess3.java | 95 + .../cuda/cupti/CUpti_ActivityGraphTrace2.java | 103 + .../CUpti_ActivityInstantaneousEvent.java | 74 + ...ti_ActivityInstantaneousEventInstance.java | 83 + .../CUpti_ActivityInstantaneousMetric.java | 79 + ...i_ActivityInstantaneousMetricInstance.java | 88 + .../CUpti_ActivityInstructionCorrelation.java | 71 + .../CUpti_ActivityInstructionExecution.java | 92 + .../cuda/cupti/CUpti_ActivityJit2.java | 116 + .../cuda/cupti/CUpti_ActivityKernel9.java | 333 + .../cuda/cupti/CUpti_ActivityMarker2.java | 91 + .../cuda/cupti/CUpti_ActivityMarkerData.java | 76 + .../cuda/cupti/CUpti_ActivityMemcpy5.java | 156 + .../cuda/cupti/CUpti_ActivityMemcpyPtoP4.java | 160 + .../cuda/cupti/CUpti_ActivityMemory.java | 120 + .../cuda/cupti/CUpti_ActivityMemory4.java | 177 + .../cuda/cupti/CUpti_ActivityMemoryPool2.java | 115 + .../cuda/cupti/CUpti_ActivityMemset4.java | 139 + .../cuda/cupti/CUpti_ActivityMetric.java | 76 + .../cupti/CUpti_ActivityMetricInstance.java | 86 + .../cuda/cupti/CUpti_ActivityModule.java | 71 + .../cuda/cupti/CUpti_ActivityName.java | 69 + .../cuda/cupti/CUpti_ActivityNvLink4.java | 141 + .../cupti/CUpti_ActivityObjectKindId.java | 56 + .../cuda/cupti/CUpti_ActivityOpenAcc.java | 184 + .../cuda/cupti/CUpti_ActivityOpenAccData.java | 203 + .../cupti/CUpti_ActivityOpenAccLaunch.java | 203 + .../cupti/CUpti_ActivityOpenAccOther.java | 178 + .../cuda/cupti/CUpti_ActivityOpenMp.java | 79 + .../cuda/cupti/CUpti_ActivityOverhead3.java | 96 + ...ActivityOverheadCommandBufferFullData.java | 52 + .../cuda/cupti/CUpti_ActivityPCSampling3.java | 90 + .../cupti/CUpti_ActivityPCSamplingConfig.java | 65 + .../CUpti_ActivityPCSamplingRecordInfo.java | 64 + .../cuda/cupti/CUpti_ActivityPcie.java | 128 + .../cuda/cupti/CUpti_ActivityPreemption.java | 80 + .../cupti/CUpti_ActivitySharedAccess.java | 99 + .../cupti/CUpti_ActivitySourceLocator.java | 67 + .../cuda/cupti/CUpti_ActivityStream.java | 68 + .../cupti/CUpti_ActivitySynchronization.java | 89 + .../CUpti_ActivityUnifiedMemoryCounter2.java | 151 + ...ti_ActivityUnifiedMemoryCounterConfig.java | 55 + .../CUpti_BuffersCallbackCompleteFunc.java | 56 + .../CUpti_BuffersCallbackRequestFunc.java | 45 + .../cuda/cupti/CUpti_CallbackData.java | 124 + .../cuda/cupti/CUpti_CallbackFunc.java | 45 + .../bytedeco/cuda/cupti/CUpti_EventGroup.java | 29 + .../cuda/cupti/CUpti_EventGroupSet.java | 52 + .../cuda/cupti/CUpti_EventGroupSets.java | 51 + .../bytedeco/cuda/cupti/CUpti_GraphData.java | 74 + .../cupti/CUpti_KernelReplayUpdateFunc.java | 34 + .../cuda/cupti/CUpti_MetricValue.java | 68 + .../cuda/cupti/CUpti_ModuleResourceData.java | 60 + .../bytedeco/cuda/cupti/CUpti_NvtxData.java | 63 + .../cuda/cupti/CUpti_ResourceData.java | 64 + .../bytedeco/cuda/cupti/CUpti_StateData.java | 56 + .../cuda/cupti/CUpti_StreamAttrData.java | 59 + .../cuda/cupti/CUpti_Subscriber_st.java | 25 + .../cuda/cupti/CUpti_SynchronizeData.java | 52 + .../cupti/CUpti_TimestampCallbackFunc.java | 36 + .../java/org/bytedeco/cuda/global/cupti.java | 8245 +++++++++++++++++ .../java/org/bytedeco/cuda/presets/cupti.java | 55 + cuda/src/main/java9/module-info.java | 1 + 78 files changed, 15322 insertions(+) create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_Activity.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityAPI.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityAutoBoostState.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityBranch2.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityCdpKernel.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityContext3.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityCudaEvent.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityDevice5.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityDeviceAttribute.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityEnvironment.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityEvent.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityEventInstance.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityExternalCorrelation.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityFunction.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityGlobalAccess3.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityGraphTrace2.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstantaneousEvent.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstantaneousEventInstance.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstantaneousMetric.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstantaneousMetricInstance.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstructionCorrelation.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstructionExecution.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityJit2.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityKernel9.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMarker2.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMarkerData.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemcpy5.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemcpyPtoP4.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemory.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemory4.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemoryPool2.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemset4.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMetric.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMetricInstance.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityModule.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityName.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityNvLink4.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityObjectKindId.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOpenAcc.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOpenAccData.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOpenAccLaunch.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOpenAccOther.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOpenMp.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOverhead3.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOverheadCommandBufferFullData.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityPCSampling3.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityPCSamplingConfig.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityPCSamplingRecordInfo.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityPcie.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityPreemption.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivitySharedAccess.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivitySourceLocator.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityStream.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivitySynchronization.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityUnifiedMemoryCounter2.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityUnifiedMemoryCounterConfig.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_BuffersCallbackCompleteFunc.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_BuffersCallbackRequestFunc.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_CallbackData.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_CallbackFunc.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_EventGroup.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_EventGroupSet.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_EventGroupSets.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_GraphData.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_KernelReplayUpdateFunc.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_MetricValue.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ModuleResourceData.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_NvtxData.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ResourceData.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_StateData.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_StreamAttrData.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_Subscriber_st.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_SynchronizeData.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_TimestampCallbackFunc.java create mode 100644 cuda/src/gen/java/org/bytedeco/cuda/global/cupti.java create mode 100644 cuda/src/main/java/org/bytedeco/cuda/presets/cupti.java diff --git a/CHANGELOG.md b/CHANGELOG.md index 7409d345be0..bf7e65d7f3d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,5 @@ + * Add presets for the CUPTI module of CUDA ([pull #1531](https://github.com/bytedeco/javacpp-presets/pull/1531)) * Add new `ClangMemoryMgmtExample` in samples for LLVM ([pull #1522](https://github.com/bytedeco/javacpp-presets/pull/1522)) * Enable `opencv_python3` module for `macosx-arm64` as well ([pull #1517](https://github.com/bytedeco/javacpp-presets/pull/1517)) * Introduce `macosx-arm64` builds for CPython ([pull #1511](https://github.com/bytedeco/javacpp-presets/pull/1511)), NumPy ([pull #1515](https://github.com/bytedeco/javacpp-presets/pull/1515)), SciPy ([pull #1516](https://github.com/bytedeco/javacpp-presets/pull/1516)) diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_Activity.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_Activity.java new file mode 100644 index 00000000000..18835ba5e7f --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_Activity.java @@ -0,0 +1,51 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The base activity record. + * + * The activity API uses a CUpti_Activity as a generic representation + * for any activity. The 'kind' field is used to determine the + * specific activity kind, and from that the CUpti_Activity object can + * be cast to the specific activity record type appropriate for that kind. + * + * Note that all activity record types are padded and aligned to + * ensure that each member of the record is naturally aligned. + * + * @see CUpti_ActivityKind + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_Activity extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_Activity() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_Activity(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_Activity(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_Activity position(long position) { + return (CUpti_Activity)super.position(position); + } + @Override public CUpti_Activity getPointer(long i) { + return new CUpti_Activity((Pointer)this).offsetAddress(i); + } + + /** + * The kind of this activity. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_Activity kind(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityAPI.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityAPI.java new file mode 100644 index 00000000000..1372e6cdc5b --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityAPI.java @@ -0,0 +1,92 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for a driver or runtime API invocation. + * + * This activity record represents an invocation of a driver or + * runtime API (CUPTI_ACTIVITY_KIND_DRIVER and + * CUPTI_ACTIVITY_KIND_RUNTIME). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityAPI extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityAPI() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityAPI(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityAPI(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityAPI position(long position) { + return (CUpti_ActivityAPI)super.position(position); + } + @Override public CUpti_ActivityAPI getPointer(long i) { + return new CUpti_ActivityAPI((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_DRIVER, + * CUPTI_ACTIVITY_KIND_RUNTIME, or CUPTI_ACTIVITY_KIND_INTERNAL_LAUNCH_API. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityAPI kind(int setter); + + /** + * The ID of the driver or runtime function. + */ + public native @Cast("CUpti_CallbackId") int cbid(); public native CUpti_ActivityAPI cbid(int setter); + + /** + * The start timestamp for the function, in ns. A value of 0 for + * both the start and end timestamps indicates that timestamp + * information could not be collected for the function. + */ + public native @Cast("uint64_t") long start(); public native CUpti_ActivityAPI start(long setter); + + /** + * The end timestamp for the function, in ns. A value of 0 for both + * the start and end timestamps indicates that timestamp information + * could not be collected for the function. + */ + public native @Cast("uint64_t") long end(); public native CUpti_ActivityAPI end(long setter); + + /** + * The ID of the process where the driver or runtime CUDA function + * is executing. + */ + public native @Cast("uint32_t") int processId(); public native CUpti_ActivityAPI processId(int setter); + + /** + * The ID of the thread where the driver or runtime CUDA function is + * executing. + */ + public native @Cast("uint32_t") int threadId(); public native CUpti_ActivityAPI threadId(int setter); + + /** + * The correlation ID of the driver or runtime CUDA function. Each + * function invocation is assigned a unique correlation ID that is + * identical to the correlation ID in the memcpy, memset, or kernel + * activity record that is associated with this function. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityAPI correlationId(int setter); + + /** + * The return value for the function. For a CUDA driver function + * with will be a CUresult value, and for a CUDA runtime function + * this will be a cudaError_t value. + */ + public native @Cast("uint32_t") int returnValue(); public native CUpti_ActivityAPI returnValue(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityAutoBoostState.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityAutoBoostState.java new file mode 100644 index 00000000000..ffdb6d36e5e --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityAutoBoostState.java @@ -0,0 +1,54 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief Device auto boost state structure + * + * This structure defines auto boost state for a device. + * See function \ref cuptiGetAutoBoostState + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityAutoBoostState extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityAutoBoostState() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityAutoBoostState(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityAutoBoostState(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityAutoBoostState position(long position) { + return (CUpti_ActivityAutoBoostState)super.position(position); + } + @Override public CUpti_ActivityAutoBoostState getPointer(long i) { + return new CUpti_ActivityAutoBoostState((Pointer)this).offsetAddress(i); + } + + /** + * Returned auto boost state. 1 is returned in case auto boost is enabled, 0 + * otherwise + */ + public native @Cast("uint32_t") int enabled(); public native CUpti_ActivityAutoBoostState enabled(int setter); + + /** + * Id of process that has set the current boost state. The value will be + * CUPTI_AUTO_BOOST_INVALID_CLIENT_PID if the user does not have the + * permission to query process ids or there is an error in querying the + * process id. + */ + public native @Cast("uint32_t") int pid(); public native CUpti_ActivityAutoBoostState pid(int setter); + +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityBranch2.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityBranch2.java new file mode 100644 index 00000000000..4608e19d9dd --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityBranch2.java @@ -0,0 +1,87 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for source level result + * branch. + * + * This activity record the locations of the branches in the + * source (CUPTI_ACTIVITY_KIND_BRANCH). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityBranch2 extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityBranch2() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityBranch2(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityBranch2(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityBranch2 position(long position) { + return (CUpti_ActivityBranch2)super.position(position); + } + @Override public CUpti_ActivityBranch2 getPointer(long i) { + return new CUpti_ActivityBranch2((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_BRANCH. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityBranch2 kind(int setter); + + /** + * The ID for source locator. + */ + public native @Cast("uint32_t") int sourceLocatorId(); public native CUpti_ActivityBranch2 sourceLocatorId(int setter); + + /** + * The correlation ID of the kernel to which this result is associated. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityBranch2 correlationId(int setter); + + /** + * Correlation ID with global/device function name + */ + public native @Cast("uint32_t") int functionId(); public native CUpti_ActivityBranch2 functionId(int setter); + + /** + * The pc offset for the branch. + */ + public native @Cast("uint32_t") int pcOffset(); public native CUpti_ActivityBranch2 pcOffset(int setter); + + /** + * Number of times this branch diverged + */ + public native @Cast("uint32_t") int diverged(); public native CUpti_ActivityBranch2 diverged(int setter); + + /** + * This increments each time when this instruction is executed by number + * of threads that executed this instruction + */ + public native @Cast("uint64_t") long threadsExecuted(); public native CUpti_ActivityBranch2 threadsExecuted(long setter); + + /** + * The number of times this instruction was executed per warp. It will be incremented + * regardless of predicate or condition code. + */ + public native @Cast("uint32_t") int executed(); public native CUpti_ActivityBranch2 executed(int setter); + + /** + * Undefined. Reserved for internal use. + */ + public native @Cast("uint32_t") int pad(); public native CUpti_ActivityBranch2 pad(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityCdpKernel.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityCdpKernel.java new file mode 100644 index 00000000000..560e5fe6359 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityCdpKernel.java @@ -0,0 +1,218 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for CDP (CUDA Dynamic Parallelism) + * kernel. + * + * This activity record represents a CDP kernel execution. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityCdpKernel extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityCdpKernel() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityCdpKernel(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityCdpKernel(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityCdpKernel position(long position) { + return (CUpti_ActivityCdpKernel)super.position(position); + } + @Override public CUpti_ActivityCdpKernel getPointer(long i) { + return new CUpti_ActivityCdpKernel((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_CDP_KERNEL + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityCdpKernel kind(int setter); + + @Name("cacheConfig.both") public native @Cast("uint8_t") byte cacheConfig_both(); public native CUpti_ActivityCdpKernel cacheConfig_both(byte setter); + /** + * The cache configuration requested by the kernel. The value is one + * of the CUfunc_cache enumeration values from cuda.h. + */ + @Name("cacheConfig.config.requested") public native @Cast("uint8_t") @NoOffset byte cacheConfig_config_requested(); public native CUpti_ActivityCdpKernel cacheConfig_config_requested(byte setter); + + /** + * The cache configuration used for the kernel. The value is one of + * the CUfunc_cache enumeration values from cuda.h. + */ + @Name("cacheConfig.config.executed") public native @Cast("uint8_t") @NoOffset byte cacheConfig_config_executed(); public native CUpti_ActivityCdpKernel cacheConfig_config_executed(byte setter); + + /** + * The shared memory configuration used for the kernel. The value is one of + * the CUsharedconfig enumeration values from cuda.h. + */ + public native @Cast("uint8_t") byte sharedMemoryConfig(); public native CUpti_ActivityCdpKernel sharedMemoryConfig(byte setter); + + /** + * The number of registers required for each thread executing the + * kernel. + */ + public native @Cast("uint16_t") short registersPerThread(); public native CUpti_ActivityCdpKernel registersPerThread(short setter); + + /** + * The start timestamp for the kernel execution, in ns. A value of 0 + * for both the start and end timestamps indicates that timestamp + * information could not be collected for the kernel. + */ + public native @Cast("uint64_t") long start(); public native CUpti_ActivityCdpKernel start(long setter); + + /** + * The end timestamp for the kernel execution, in ns. A value of 0 + * for both the start and end timestamps indicates that timestamp + * information could not be collected for the kernel. + */ + public native @Cast("uint64_t") long end(); public native CUpti_ActivityCdpKernel end(long setter); + + /** + * The ID of the device where the kernel is executing. + */ + public native @Cast("uint32_t") int deviceId(); public native CUpti_ActivityCdpKernel deviceId(int setter); + + /** + * The ID of the context where the kernel is executing. + */ + public native @Cast("uint32_t") int contextId(); public native CUpti_ActivityCdpKernel contextId(int setter); + + /** + * The ID of the stream where the kernel is executing. + */ + public native @Cast("uint32_t") int streamId(); public native CUpti_ActivityCdpKernel streamId(int setter); + + /** + * The X-dimension grid size for the kernel. + */ + public native int gridX(); public native CUpti_ActivityCdpKernel gridX(int setter); + + /** + * The Y-dimension grid size for the kernel. + */ + public native int gridY(); public native CUpti_ActivityCdpKernel gridY(int setter); + + /** + * The Z-dimension grid size for the kernel. + */ + public native int gridZ(); public native CUpti_ActivityCdpKernel gridZ(int setter); + + /** + * The X-dimension block size for the kernel. + */ + public native int blockX(); public native CUpti_ActivityCdpKernel blockX(int setter); + + /** + * The Y-dimension block size for the kernel. + */ + public native int blockY(); public native CUpti_ActivityCdpKernel blockY(int setter); + + /** + * The Z-dimension grid size for the kernel. + */ + public native int blockZ(); public native CUpti_ActivityCdpKernel blockZ(int setter); + + /** + * The static shared memory allocated for the kernel, in bytes. + */ + public native int staticSharedMemory(); public native CUpti_ActivityCdpKernel staticSharedMemory(int setter); + + /** + * The dynamic shared memory reserved for the kernel, in bytes. + */ + public native int dynamicSharedMemory(); public native CUpti_ActivityCdpKernel dynamicSharedMemory(int setter); + + /** + * The amount of local memory reserved for each thread, in bytes. + */ + public native @Cast("uint32_t") int localMemoryPerThread(); public native CUpti_ActivityCdpKernel localMemoryPerThread(int setter); + + /** + * The total amount of local memory reserved for the kernel, in + * bytes. + */ + public native @Cast("uint32_t") int localMemoryTotal(); public native CUpti_ActivityCdpKernel localMemoryTotal(int setter); + + /** + * The correlation ID of the kernel. Each kernel execution is + * assigned a unique correlation ID that is identical to the + * correlation ID in the driver API activity record that launched + * the kernel. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityCdpKernel correlationId(int setter); + + /** + * The grid ID of the kernel. Each kernel execution + * is assigned a unique grid ID. + */ + public native @Cast("int64_t") long gridId(); public native CUpti_ActivityCdpKernel gridId(long setter); + + /** + * The grid ID of the parent kernel. + */ + public native @Cast("int64_t") long parentGridId(); public native CUpti_ActivityCdpKernel parentGridId(long setter); + + /** + * The timestamp when kernel is queued up, in ns. A value of + * CUPTI_TIMESTAMP_UNKNOWN indicates that the queued time is + * unknown. + */ + public native @Cast("uint64_t") long queued(); public native CUpti_ActivityCdpKernel queued(long setter); + + /** + * The timestamp when kernel is submitted to the gpu, in ns. A value + * of CUPTI_TIMESTAMP_UNKNOWN indicates that the submission time is + * unknown. + */ + public native @Cast("uint64_t") long submitted(); public native CUpti_ActivityCdpKernel submitted(long setter); + + /** + * The timestamp when kernel is marked as completed, in ns. A value + * of CUPTI_TIMESTAMP_UNKNOWN indicates that the completion time is + * unknown. + */ + public native @Cast("uint64_t") long completed(); public native CUpti_ActivityCdpKernel completed(long setter); + + /** + * The X-dimension of the parent block. + */ + public native @Cast("uint32_t") int parentBlockX(); public native CUpti_ActivityCdpKernel parentBlockX(int setter); + + /** + * The Y-dimension of the parent block. + */ + public native @Cast("uint32_t") int parentBlockY(); public native CUpti_ActivityCdpKernel parentBlockY(int setter); + + /** + * The Z-dimension of the parent block. + */ + public native @Cast("uint32_t") int parentBlockZ(); public native CUpti_ActivityCdpKernel parentBlockZ(int setter); + +// #ifdef CUPTILP64 + /** + * Undefined. Reserved for internal use. + */ + public native @Cast("uint32_t") int pad(); public native CUpti_ActivityCdpKernel pad(int setter); +// #endif + + /** + * The name of the kernel. This name is shared across all activity + * records representing the same kernel, and so should not be + * modified. + */ + public native @Cast("const char*") BytePointer name(); public native CUpti_ActivityCdpKernel name(BytePointer setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityContext3.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityContext3.java new file mode 100644 index 00000000000..7fa9ad8db34 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityContext3.java @@ -0,0 +1,91 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for a context. + * + * This activity record represents information about a context + * (CUPTI_ACTIVITY_KIND_CONTEXT). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityContext3 extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityContext3() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityContext3(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityContext3(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityContext3 position(long position) { + return (CUpti_ActivityContext3)super.position(position); + } + @Override public CUpti_ActivityContext3 getPointer(long i) { + return new CUpti_ActivityContext3((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_CONTEXT. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityContext3 kind(int setter); + + /** + * The context ID. + */ + public native @Cast("uint32_t") int contextId(); public native CUpti_ActivityContext3 contextId(int setter); + + /** + * The device ID. + */ + public native @Cast("uint32_t") int deviceId(); public native CUpti_ActivityContext3 deviceId(int setter); + + /** + * The compute API kind. @see CUpti_ActivityComputeApiKind + */ + public native @Cast("uint16_t") short computeApiKind(); public native CUpti_ActivityContext3 computeApiKind(short setter); + + /** + * The ID for the NULL stream in this context + */ + public native @Cast("uint16_t") short nullStreamId(); public native CUpti_ActivityContext3 nullStreamId(short setter); + + /** + * The ID of the parent context. It would be 0 if + * context does not have parent + */ + public native @Cast("uint32_t") int parentContextId(); public native CUpti_ActivityContext3 parentContextId(int setter); + + /** + * This field indicates whether the context is a green context + */ + public native @Cast("uint8_t") byte isGreenContext(); public native CUpti_ActivityContext3 isGreenContext(byte setter); + + public native @Cast("uint8_t") byte padding(); public native CUpti_ActivityContext3 padding(byte setter); + + /** + * Number of multiprocessors assigned to the green context + * Invalid if the field 'isGreenContext' is 0 + */ + public native @Cast("uint16_t") short numMultiprocessors(); public native CUpti_ActivityContext3 numMultiprocessors(short setter); + + /** + * This field indicates the CIG mode + */ + public native @Cast("CUpti_ContextCigMode") int cigMode(); public native CUpti_ActivityContext3 cigMode(int setter); + + public native @Cast("uint32_t") int padding2(); public native CUpti_ActivityContext3 padding2(int setter); + +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityCudaEvent.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityCudaEvent.java new file mode 100644 index 00000000000..9ab28de72de --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityCudaEvent.java @@ -0,0 +1,69 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for CUDA event. + * + * This activity is used to track recorded events. + * (CUPTI_ACTIVITY_KIND_CUDA_EVENT). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityCudaEvent extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityCudaEvent() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityCudaEvent(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityCudaEvent(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityCudaEvent position(long position) { + return (CUpti_ActivityCudaEvent)super.position(position); + } + @Override public CUpti_ActivityCudaEvent getPointer(long i) { + return new CUpti_ActivityCudaEvent((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_CUDA_EVENT. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityCudaEvent kind(int setter); + + /** + * The correlation ID of the API to which this result is associated. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityCudaEvent correlationId(int setter); + + /** + * The ID of the context where the event was recorded. + */ + public native @Cast("uint32_t") int contextId(); public native CUpti_ActivityCudaEvent contextId(int setter); + + /** + * The compute stream where the event was recorded. + */ + public native @Cast("uint32_t") int streamId(); public native CUpti_ActivityCudaEvent streamId(int setter); + + /** + * A unique event ID to identify the event record. + */ + public native @Cast("uint32_t") int eventId(); public native CUpti_ActivityCudaEvent eventId(int setter); + + /** + * Undefined. Reserved for internal use. + */ + public native @Cast("uint32_t") int pad(); public native CUpti_ActivityCudaEvent pad(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityDevice5.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityDevice5.java new file mode 100644 index 00000000000..00f6634161a --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityDevice5.java @@ -0,0 +1,245 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for a device. (CUDA 11.6 onwards) + * + * This activity record represents information about a GPU device + * (CUPTI_ACTIVITY_KIND_DEVICE). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityDevice5 extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityDevice5() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityDevice5(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityDevice5(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityDevice5 position(long position) { + return (CUpti_ActivityDevice5)super.position(position); + } + @Override public CUpti_ActivityDevice5 getPointer(long i) { + return new CUpti_ActivityDevice5((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_DEVICE. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityDevice5 kind(int setter); + + /** + * The flags associated with the device. @see CUpti_ActivityFlag + */ + public native @Cast("CUpti_ActivityFlag") int flags(); public native CUpti_ActivityDevice5 flags(int setter); + + /** + * The global memory bandwidth available on the device, in + * kBytes/sec. + */ + public native @Cast("uint64_t") long globalMemoryBandwidth(); public native CUpti_ActivityDevice5 globalMemoryBandwidth(long setter); + + /** + * The amount of global memory on the device, in bytes. + */ + public native @Cast("uint64_t") long globalMemorySize(); public native CUpti_ActivityDevice5 globalMemorySize(long setter); + + /** + * The amount of constant memory on the device, in bytes. + */ + public native @Cast("uint32_t") int constantMemorySize(); public native CUpti_ActivityDevice5 constantMemorySize(int setter); + + /** + * The size of the L2 cache on the device, in bytes. + */ + public native @Cast("uint32_t") int l2CacheSize(); public native CUpti_ActivityDevice5 l2CacheSize(int setter); + + /** + * The number of threads per warp on the device. + */ + public native @Cast("uint32_t") int numThreadsPerWarp(); public native CUpti_ActivityDevice5 numThreadsPerWarp(int setter); + + /** + * The core clock rate of the device, in kHz. + */ + public native @Cast("uint32_t") int coreClockRate(); public native CUpti_ActivityDevice5 coreClockRate(int setter); + + /** + * Number of memory copy engines on the device. + */ + public native @Cast("uint32_t") int numMemcpyEngines(); public native CUpti_ActivityDevice5 numMemcpyEngines(int setter); + + /** + * Number of multiprocessors on the device. + */ + public native @Cast("uint32_t") int numMultiprocessors(); public native CUpti_ActivityDevice5 numMultiprocessors(int setter); + + /** + * The maximum "instructions per cycle" possible on each device + * multiprocessor. + */ + public native @Cast("uint32_t") int maxIPC(); public native CUpti_ActivityDevice5 maxIPC(int setter); + + /** + * Maximum number of warps that can be present on a multiprocessor + * at any given time. + */ + public native @Cast("uint32_t") int maxWarpsPerMultiprocessor(); public native CUpti_ActivityDevice5 maxWarpsPerMultiprocessor(int setter); + + /** + * Maximum number of blocks that can be present on a multiprocessor + * at any given time. + */ + public native @Cast("uint32_t") int maxBlocksPerMultiprocessor(); public native CUpti_ActivityDevice5 maxBlocksPerMultiprocessor(int setter); + + /** + * Maximum amount of shared memory available per multiprocessor, in bytes. + */ + public native @Cast("uint32_t") int maxSharedMemoryPerMultiprocessor(); public native CUpti_ActivityDevice5 maxSharedMemoryPerMultiprocessor(int setter); + + /** + * Maximum number of 32-bit registers available per multiprocessor. + */ + public native @Cast("uint32_t") int maxRegistersPerMultiprocessor(); public native CUpti_ActivityDevice5 maxRegistersPerMultiprocessor(int setter); + + /** + * Maximum number of registers that can be allocated to a block. + */ + public native @Cast("uint32_t") int maxRegistersPerBlock(); public native CUpti_ActivityDevice5 maxRegistersPerBlock(int setter); + + /** + * Maximum amount of shared memory that can be assigned to a block, + * in bytes. + */ + public native @Cast("uint32_t") int maxSharedMemoryPerBlock(); public native CUpti_ActivityDevice5 maxSharedMemoryPerBlock(int setter); + + /** + * Maximum number of threads allowed in a block. + */ + public native @Cast("uint32_t") int maxThreadsPerBlock(); public native CUpti_ActivityDevice5 maxThreadsPerBlock(int setter); + + /** + * Maximum allowed X dimension for a block. + */ + public native @Cast("uint32_t") int maxBlockDimX(); public native CUpti_ActivityDevice5 maxBlockDimX(int setter); + + /** + * Maximum allowed Y dimension for a block. + */ + public native @Cast("uint32_t") int maxBlockDimY(); public native CUpti_ActivityDevice5 maxBlockDimY(int setter); + + /** + * Maximum allowed Z dimension for a block. + */ + public native @Cast("uint32_t") int maxBlockDimZ(); public native CUpti_ActivityDevice5 maxBlockDimZ(int setter); + + /** + * Maximum allowed X dimension for a grid. + */ + public native @Cast("uint32_t") int maxGridDimX(); public native CUpti_ActivityDevice5 maxGridDimX(int setter); + + /** + * Maximum allowed Y dimension for a grid. + */ + public native @Cast("uint32_t") int maxGridDimY(); public native CUpti_ActivityDevice5 maxGridDimY(int setter); + + /** + * Maximum allowed Z dimension for a grid. + */ + public native @Cast("uint32_t") int maxGridDimZ(); public native CUpti_ActivityDevice5 maxGridDimZ(int setter); + + /** + * Compute capability for the device, major number. + */ + public native @Cast("uint32_t") int computeCapabilityMajor(); public native CUpti_ActivityDevice5 computeCapabilityMajor(int setter); + + /** + * Compute capability for the device, minor number. + */ + public native @Cast("uint32_t") int computeCapabilityMinor(); public native CUpti_ActivityDevice5 computeCapabilityMinor(int setter); + + /** + * The device ID. + */ + public native @Cast("uint32_t") int id(); public native CUpti_ActivityDevice5 id(int setter); + + /** + * ECC enabled flag for device + */ + public native @Cast("uint32_t") int eccEnabled(); public native CUpti_ActivityDevice5 eccEnabled(int setter); + + /** + * The device UUID. This value is the globally unique immutable + * alphanumeric identifier of the device. + */ + public native @ByRef CUuuid uuid(); public native CUpti_ActivityDevice5 uuid(CUuuid setter); + +// #ifndef CUPTILP64 +// #endif + + /** + * The device name. This name is shared across all activity records + * representing instances of the device, and so should not be + * modified. + */ + public native @Cast("const char*") BytePointer name(); public native CUpti_ActivityDevice5 name(BytePointer setter); + + /** + * Flag to indicate whether the device is visible to CUDA. Users can + * set the device visibility using CUDA_VISIBLE_DEVICES environment + */ + public native @Cast("uint8_t") byte isCudaVisible(); public native CUpti_ActivityDevice5 isCudaVisible(byte setter); + + /** + * MIG enabled flag for device + */ + public native @Cast("uint8_t") byte isMigEnabled(); public native CUpti_ActivityDevice5 isMigEnabled(byte setter); + + public native @Cast("uint8_t") byte reserved(int i); public native CUpti_ActivityDevice5 reserved(int i, byte setter); + @MemberGetter public native @Cast("uint8_t*") BytePointer reserved(); + + /** + * GPU Instance id for MIG enabled devices. + * If mig mode is disabled value is set to UINT32_MAX + */ + public native @Cast("uint32_t") int gpuInstanceId(); public native CUpti_ActivityDevice5 gpuInstanceId(int setter); + + /** + * Compute Instance id for MIG enabled devices. + * If mig mode is disabled value is set to UINT32_MAX + */ + public native @Cast("uint32_t") int computeInstanceId(); public native CUpti_ActivityDevice5 computeInstanceId(int setter); + + /** + * The MIG UUID. This value is the globally unique immutable + * alphanumeric identifier of the device. + */ + public native @ByRef CUuuid migUuid(); public native CUpti_ActivityDevice5 migUuid(CUuuid setter); + + /** + * Numa (Non-uniform memory access) information for device + * GPU is a NUMA node or not + */ + public native @Cast("uint32_t") int isNumaNode(); public native CUpti_ActivityDevice5 isNumaNode(int setter); + + /** + * Numa (Non-uniform memory access) information for device + * NUMA node ID of the GPU memory + * if GPU is not a NUMA node, it returns invalidNumaId + */ + public native @Cast("uint32_t") int numaId(); public native CUpti_ActivityDevice5 numaId(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityDeviceAttribute.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityDeviceAttribute.java new file mode 100644 index 00000000000..e98cd57fb18 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityDeviceAttribute.java @@ -0,0 +1,79 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for a device attribute. + * + * This activity record represents information about a GPU device: + * either a CUpti_DeviceAttribute or CUdevice_attribute value + * (CUPTI_ACTIVITY_KIND_DEVICE_ATTRIBUTE). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityDeviceAttribute extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityDeviceAttribute() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityDeviceAttribute(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityDeviceAttribute(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityDeviceAttribute position(long position) { + return (CUpti_ActivityDeviceAttribute)super.position(position); + } + @Override public CUpti_ActivityDeviceAttribute getPointer(long i) { + return new CUpti_ActivityDeviceAttribute((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be + * CUPTI_ACTIVITY_KIND_DEVICE_ATTRIBUTE. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityDeviceAttribute kind(int setter); + + /** + * The flags associated with the device. @see CUpti_ActivityFlag + */ + public native @Cast("CUpti_ActivityFlag") int flags(); public native CUpti_ActivityDeviceAttribute flags(int setter); + + /** + * The ID of the device that this attribute applies to. + */ + public native @Cast("uint32_t") int deviceId(); public native CUpti_ActivityDeviceAttribute deviceId(int setter); + + /** + * The attribute, either a CUpti_DeviceAttribute or + * CUdevice_attribute. Flag + * CUPTI_ACTIVITY_FLAG_DEVICE_ATTRIBUTE_CUDEVICE is used to indicate + * what kind of attribute this is. If + * CUPTI_ACTIVITY_FLAG_DEVICE_ATTRIBUTE_CUDEVICE is 1 then + * CUdevice_attribute field is value, otherwise + * CUpti_DeviceAttribute field is valid. + */ + @Name("attribute.cu") public native @Cast("CUdevice_attribute") int attribute_cu(); public native CUpti_ActivityDeviceAttribute attribute_cu(int setter); + @Name("attribute.cupti") public native @Cast("CUpti_DeviceAttribute") int attribute_cupti(); public native CUpti_ActivityDeviceAttribute attribute_cupti(int setter); + + /** + * The value for the attribute. See CUpti_DeviceAttribute and + * CUdevice_attribute for the type of the value for a given + * attribute. + */ + @Name("value.vDouble") public native double value_vDouble(); public native CUpti_ActivityDeviceAttribute value_vDouble(double setter); + @Name("value.vUint32") public native @Cast("uint32_t") int value_vUint32(); public native CUpti_ActivityDeviceAttribute value_vUint32(int setter); + @Name("value.vUint64") public native @Cast("uint64_t") long value_vUint64(); public native CUpti_ActivityDeviceAttribute value_vUint64(long setter); + @Name("value.vInt32") public native int value_vInt32(); public native CUpti_ActivityDeviceAttribute value_vInt32(int setter); + @Name("value.vInt64") public native @Cast("int64_t") long value_vInt64(); public native CUpti_ActivityDeviceAttribute value_vInt64(long setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityEnvironment.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityEnvironment.java new file mode 100644 index 00000000000..e8abea69744 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityEnvironment.java @@ -0,0 +1,120 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for CUPTI environmental data. + * + * This activity record provides CUPTI environmental data, include + * power, clocks, and thermals. This information is sampled at + * various rates and returned in this activity record. The consumer + * of the record needs to check the environmentKind field to figure + * out what kind of environmental record this is. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityEnvironment extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityEnvironment() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityEnvironment(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityEnvironment(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityEnvironment position(long position) { + return (CUpti_ActivityEnvironment)super.position(position); + } + @Override public CUpti_ActivityEnvironment getPointer(long i) { + return new CUpti_ActivityEnvironment((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_ENVIRONMENT. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityEnvironment kind(int setter); + + /** + * The ID of the device + */ + public native @Cast("uint32_t") int deviceId(); public native CUpti_ActivityEnvironment deviceId(int setter); + + /** + * The timestamp when this sample was retrieved, in ns. A value of 0 + * indicates that timestamp information could not be collected for + * the marker. + */ + public native @Cast("uint64_t") long timestamp(); public native CUpti_ActivityEnvironment timestamp(long setter); + + /** + * The kind of data reported in this record. + */ + public native @Cast("CUpti_ActivityEnvironmentKind") int environmentKind(); public native CUpti_ActivityEnvironment environmentKind(int setter); + + /** + * Data returned for CUPTI_ACTIVITY_ENVIRONMENT_SPEED environment + * kind. + */ + /** + * The SM frequency in MHz + */ + @Name("data.speed.smClock") public native @Cast("uint32_t") int data_speed_smClock(); public native CUpti_ActivityEnvironment data_speed_smClock(int setter); + + /** + * The memory frequency in MHz + */ + @Name("data.speed.memoryClock") public native @Cast("uint32_t") int data_speed_memoryClock(); public native CUpti_ActivityEnvironment data_speed_memoryClock(int setter); + + /** + * The PCIe link generation. + */ + @Name("data.speed.pcieLinkGen") public native @Cast("uint32_t") int data_speed_pcieLinkGen(); public native CUpti_ActivityEnvironment data_speed_pcieLinkGen(int setter); + + /** + * The PCIe link width. + */ + @Name("data.speed.pcieLinkWidth") public native @Cast("uint32_t") int data_speed_pcieLinkWidth(); public native CUpti_ActivityEnvironment data_speed_pcieLinkWidth(int setter); + + /** + * The clocks throttle reasons. + */ + @Name("data.speed.clocksThrottleReasons") public native @Cast("CUpti_EnvironmentClocksThrottleReason") int data_speed_clocksThrottleReasons(); public native CUpti_ActivityEnvironment data_speed_clocksThrottleReasons(int setter); + + /** + * Data returned for CUPTI_ACTIVITY_ENVIRONMENT_TEMPERATURE + * environment kind. + */ + /** + * The GPU temperature in degrees C. + */ + @Name("data.temperature.gpuTemperature") public native @Cast("uint32_t") int data_temperature_gpuTemperature(); public native CUpti_ActivityEnvironment data_temperature_gpuTemperature(int setter); + + /** + * Data returned for CUPTI_ACTIVITY_ENVIRONMENT_POWER environment kind. + * The power in milliwatts consumed by GPU and associated circuitry. + * The power in milliwatts that will trigger power management algorithm. + */ + + @Name("data.power.power") public native @Cast("uint32_t") int data_power_power(); public native CUpti_ActivityEnvironment data_power_power(int setter); + @Name("data.power.powerLimit") public native @Cast("uint32_t") int data_power_powerLimit(); public native CUpti_ActivityEnvironment data_power_powerLimit(int setter); + + /** + * Data returned for CUPTI_ACTIVITY_ENVIRONMENT_COOLING + * environment kind. + */ + /** + * The fan speed as percentage of maximum. + */ + @Name("data.cooling.fanSpeed") public native @Cast("uint32_t") int data_cooling_fanSpeed(); public native CUpti_ActivityEnvironment data_cooling_fanSpeed(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityEvent.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityEvent.java new file mode 100644 index 00000000000..24af0ef85ca --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityEvent.java @@ -0,0 +1,70 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for a CUPTI event. + * + * This activity record represents a CUPTI event value + * (CUPTI_ACTIVITY_KIND_EVENT). This activity record kind is not + * produced by the activity API but is included for completeness and + * ease-of-use. Profile frameworks built on top of CUPTI that collect + * event data may choose to use this type to store the collected event + * data. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityEvent extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityEvent() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityEvent(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityEvent(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityEvent position(long position) { + return (CUpti_ActivityEvent)super.position(position); + } + @Override public CUpti_ActivityEvent getPointer(long i) { + return new CUpti_ActivityEvent((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_EVENT. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityEvent kind(int setter); + + /** + * The event ID. + */ + public native @Cast("CUpti_EventID") int id(); public native CUpti_ActivityEvent id(int setter); + + /** + * The event value. + */ + public native @Cast("uint64_t") long value(); public native CUpti_ActivityEvent value(long setter); + + /** + * The event domain ID. + */ + public native @Cast("CUpti_EventDomainID") int domain(); public native CUpti_ActivityEvent domain(int setter); + + /** + * The correlation ID of the event. Use of this ID is user-defined, + * but typically this ID value will equal the correlation ID of the + * kernel for which the event was gathered. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityEvent correlationId(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityEventInstance.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityEventInstance.java new file mode 100644 index 00000000000..e56dc2eb3e1 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityEventInstance.java @@ -0,0 +1,85 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for a CUPTI event with instance + * information. + * + * This activity record represents the a CUPTI event value for a + * specific event domain instance + * (CUPTI_ACTIVITY_KIND_EVENT_INSTANCE). This activity record kind is + * not produced by the activity API but is included for completeness + * and ease-of-use. Profile frameworks built on top of CUPTI that + * collect event data may choose to use this type to store the + * collected event data. This activity record should be used when + * event domain instance information needs to be associated with the + * event. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityEventInstance extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityEventInstance() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityEventInstance(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityEventInstance(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityEventInstance position(long position) { + return (CUpti_ActivityEventInstance)super.position(position); + } + @Override public CUpti_ActivityEventInstance getPointer(long i) { + return new CUpti_ActivityEventInstance((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be + * CUPTI_ACTIVITY_KIND_EVENT_INSTANCE. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityEventInstance kind(int setter); + + /** + * The event ID. + */ + public native @Cast("CUpti_EventID") int id(); public native CUpti_ActivityEventInstance id(int setter); + + /** + * The event domain ID. + */ + public native @Cast("CUpti_EventDomainID") int domain(); public native CUpti_ActivityEventInstance domain(int setter); + + /** + * The event domain instance. + */ + public native @Cast("uint32_t") int instance(); public native CUpti_ActivityEventInstance instance(int setter); + + /** + * The event value. + */ + public native @Cast("uint64_t") long value(); public native CUpti_ActivityEventInstance value(long setter); + + /** + * The correlation ID of the event. Use of this ID is user-defined, + * but typically this ID value will equal the correlation ID of the + * kernel for which the event was gathered. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityEventInstance correlationId(int setter); + + /** + * Undefined. Reserved for internal use. + */ + public native @Cast("uint32_t") int pad(); public native CUpti_ActivityEventInstance pad(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityExternalCorrelation.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityExternalCorrelation.java new file mode 100644 index 00000000000..50aa3e329fa --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityExternalCorrelation.java @@ -0,0 +1,69 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for correlation with external records + * + * This activity record correlates native CUDA records (e.g. CUDA Driver API, + * kernels, memcpys, ...) with records from external APIs such as OpenACC. + * (CUPTI_ACTIVITY_KIND_EXTERNAL_CORRELATION). + * + * @see CUpti_ActivityKind + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityExternalCorrelation extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityExternalCorrelation() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityExternalCorrelation(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityExternalCorrelation(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityExternalCorrelation position(long position) { + return (CUpti_ActivityExternalCorrelation)super.position(position); + } + @Override public CUpti_ActivityExternalCorrelation getPointer(long i) { + return new CUpti_ActivityExternalCorrelation((Pointer)this).offsetAddress(i); + } + + /** + * The kind of this activity. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityExternalCorrelation kind(int setter); + + /** + * The kind of external API this record correlated to. + */ + public native @Cast("CUpti_ExternalCorrelationKind") int externalKind(); public native CUpti_ActivityExternalCorrelation externalKind(int setter); + + /** + * The correlation ID of the associated non-CUDA API record. + * The exact field in the associated external record depends + * on that record's activity kind (@see externalKind). + */ + public native @Cast("uint64_t") long externalId(); public native CUpti_ActivityExternalCorrelation externalId(long setter); + + /** + * The correlation ID of the associated CUDA driver or runtime API record. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityExternalCorrelation correlationId(int setter); + + /** + * Undefined. Reserved for internal use. + */ + public native @Cast("uint32_t") int reserved(); public native CUpti_ActivityExternalCorrelation reserved(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityFunction.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityFunction.java new file mode 100644 index 00000000000..91e284f312b --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityFunction.java @@ -0,0 +1,79 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for global/device functions. + * + * This activity records function name and corresponding module + * information. + * (CUPTI_ACTIVITY_KIND_FUNCTION). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityFunction extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityFunction() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityFunction(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityFunction(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityFunction position(long position) { + return (CUpti_ActivityFunction)super.position(position); + } + @Override public CUpti_ActivityFunction getPointer(long i) { + return new CUpti_ActivityFunction((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_FUNCTION. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityFunction kind(int setter); + + /** + * ID to uniquely identify the record + */ + public native @Cast("uint32_t") int id(); public native CUpti_ActivityFunction id(int setter); + + /** + * The ID of the context where the function is launched. + */ + public native @Cast("uint32_t") int contextId(); public native CUpti_ActivityFunction contextId(int setter); + + /** + * The module ID in which this global/device function is present. + */ + public native @Cast("uint32_t") int moduleId(); public native CUpti_ActivityFunction moduleId(int setter); + + /** + * The function's unique symbol index in the module. + */ + public native @Cast("uint32_t") int functionIndex(); public native CUpti_ActivityFunction functionIndex(int setter); + +// #ifdef CUPTILP64 + /** + * Undefined. Reserved for internal use. + */ + public native @Cast("uint32_t") int pad(); public native CUpti_ActivityFunction pad(int setter); +// #endif + + /** + * The name of the function. This name is shared across all activity + * records representing the same kernel, and so should not be + * modified. + */ + public native @Cast("const char*") BytePointer name(); public native CUpti_ActivityFunction name(BytePointer setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityGlobalAccess3.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityGlobalAccess3.java new file mode 100644 index 00000000000..92ce95a6070 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityGlobalAccess3.java @@ -0,0 +1,95 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for source-level global + * access. + * + * This activity records the locations of the global + * accesses in the source (CUPTI_ACTIVITY_KIND_GLOBAL_ACCESS). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityGlobalAccess3 extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityGlobalAccess3() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityGlobalAccess3(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityGlobalAccess3(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityGlobalAccess3 position(long position) { + return (CUpti_ActivityGlobalAccess3)super.position(position); + } + @Override public CUpti_ActivityGlobalAccess3 getPointer(long i) { + return new CUpti_ActivityGlobalAccess3((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_GLOBAL_ACCESS. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityGlobalAccess3 kind(int setter); + + /** + * The properties of this global access. + */ + public native @Cast("CUpti_ActivityFlag") int flags(); public native CUpti_ActivityGlobalAccess3 flags(int setter); + + /** + * The ID for source locator. + */ + public native @Cast("uint32_t") int sourceLocatorId(); public native CUpti_ActivityGlobalAccess3 sourceLocatorId(int setter); + + /** + * The correlation ID of the kernel to which this result is associated. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityGlobalAccess3 correlationId(int setter); + + /** + * Correlation ID with global/device function name + */ + public native @Cast("uint32_t") int functionId(); public native CUpti_ActivityGlobalAccess3 functionId(int setter); + + /** + * The number of times this instruction was executed per warp. It will be incremented + * when at least one of thread among warp is active with predicate and condition code + * evaluating to true. + */ + public native @Cast("uint32_t") int executed(); public native CUpti_ActivityGlobalAccess3 executed(int setter); + + /** + * The pc offset for the access. + */ + public native @Cast("uint64_t") long pcOffset(); public native CUpti_ActivityGlobalAccess3 pcOffset(long setter); + + /** + * This increments each time when this instruction is executed by number of + * threads that executed this instruction with predicate and condition code + * evaluating to true. + */ + public native @Cast("uint64_t") long threadsExecuted(); public native CUpti_ActivityGlobalAccess3 threadsExecuted(long setter); + + /** + * The total number of 32 bytes transactions to L2 cache generated by this + access + */ + public native @Cast("uint64_t") long l2_transactions(); public native CUpti_ActivityGlobalAccess3 l2_transactions(long setter); + + /** + * The minimum number of L2 transactions possible based on the access pattern. + */ + public native @Cast("uint64_t") long theoreticalL2Transactions(); public native CUpti_ActivityGlobalAccess3 theoreticalL2Transactions(long setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityGraphTrace2.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityGraphTrace2.java new file mode 100644 index 00000000000..760cf598d20 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityGraphTrace2.java @@ -0,0 +1,103 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + + +/** + * \brief The activity record for trace of graph execution. + * + * This activity record represents execution for a graph without giving visibility + * about the execution of its nodes. This is intended to reduce overheads in tracing + * each node. The activity kind is CUPTI_ACTIVITY_KIND_GRAPH_TRACE + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityGraphTrace2 extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityGraphTrace2() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityGraphTrace2(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityGraphTrace2(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityGraphTrace2 position(long position) { + return (CUpti_ActivityGraphTrace2)super.position(position); + } + @Override public CUpti_ActivityGraphTrace2 getPointer(long i) { + return new CUpti_ActivityGraphTrace2((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_GRAPH_TRACE + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityGraphTrace2 kind(int setter); + + /** + * The correlation ID of the graph launch. Each graph launch is + * assigned a unique correlation ID that is identical to the + * correlation ID in the driver API activity record that launched + * the graph. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityGraphTrace2 correlationId(int setter); + + /** + * The start timestamp for the graph execution, in ns. A value of 0 + * for both the start and end timestamps indicates that timestamp + * information could not be collected for the graph. + */ + public native @Cast("uint64_t") long start(); public native CUpti_ActivityGraphTrace2 start(long setter); + + /** + * The end timestamp for the graph execution, in ns. A value of 0 + * for both the start and end timestamps indicates that timestamp + * information could not be collected for the graph. + */ + public native @Cast("uint64_t") long end(); public native CUpti_ActivityGraphTrace2 end(long setter); + + /** + * The ID of the device where the first node of the graph is executed. + */ + public native @Cast("uint32_t") int deviceId(); public native CUpti_ActivityGraphTrace2 deviceId(int setter); + + /** + * The unique ID of the graph that is launched. + */ + public native @Cast("uint32_t") int graphId(); public native CUpti_ActivityGraphTrace2 graphId(int setter); + + /** + * The ID of the context where the first node of the graph is executed. + */ + public native @Cast("uint32_t") int contextId(); public native CUpti_ActivityGraphTrace2 contextId(int setter); + + /** + * The ID of the stream where the graph is being launched. + */ + public native @Cast("uint32_t") int streamId(); public native CUpti_ActivityGraphTrace2 streamId(int setter); + + /** + * This field is reserved for internal use + */ + public native Pointer reserved(); public native CUpti_ActivityGraphTrace2 reserved(Pointer setter); + + /** + * The ID of the device where last node of the graph is executed + */ + public native @Cast("uint32_t") int endDeviceId(); public native CUpti_ActivityGraphTrace2 endDeviceId(int setter); + + /** + * The ID of the context where the last node of the graph is executed. + */ + public native @Cast("uint32_t") int endContextId(); public native CUpti_ActivityGraphTrace2 endContextId(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstantaneousEvent.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstantaneousEvent.java new file mode 100644 index 00000000000..30339f0c6ed --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstantaneousEvent.java @@ -0,0 +1,74 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + + +/** + * \brief The activity record for an instantaneous CUPTI event. + * + * This activity record represents a CUPTI event value + * (CUPTI_ACTIVITY_KIND_EVENT) sampled at a particular instant. + * This activity record kind is not produced by the activity API but is + * included for completeness and ease-of-use. Profiler frameworks built on + * top of CUPTI that collect event data at a particular time may choose to + * use this type to store the collected event data. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityInstantaneousEvent extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityInstantaneousEvent() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityInstantaneousEvent(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityInstantaneousEvent(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityInstantaneousEvent position(long position) { + return (CUpti_ActivityInstantaneousEvent)super.position(position); + } + @Override public CUpti_ActivityInstantaneousEvent getPointer(long i) { + return new CUpti_ActivityInstantaneousEvent((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_INSTANTANEOUS_EVENT. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityInstantaneousEvent kind(int setter); + + /** + * The event ID. + */ + public native @Cast("CUpti_EventID") int id(); public native CUpti_ActivityInstantaneousEvent id(int setter); + + /** + * The event value. + */ + public native @Cast("uint64_t") long value(); public native CUpti_ActivityInstantaneousEvent value(long setter); + + /** + * The timestamp at which event is sampled + */ + public native @Cast("uint64_t") long timestamp(); public native CUpti_ActivityInstantaneousEvent timestamp(long setter); + + /** + * The device id + */ + public native @Cast("uint32_t") int deviceId(); public native CUpti_ActivityInstantaneousEvent deviceId(int setter); + + /** + * Undefined. reserved for internal use + */ + public native @Cast("uint32_t") int reserved(); public native CUpti_ActivityInstantaneousEvent reserved(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstantaneousEventInstance.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstantaneousEventInstance.java new file mode 100644 index 00000000000..c9204e872b9 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstantaneousEventInstance.java @@ -0,0 +1,83 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for an instantaneous CUPTI event + * with event domain instance information. + * + * This activity record represents the a CUPTI event value for a + * specific event domain instance + * (CUPTI_ACTIVITY_KIND_EVENT_INSTANCE) sampled at a particular instant. + * This activity record kind is not produced by the activity API but is + * included for completeness and ease-of-use. Profiler frameworks built on + * top of CUPTI that collect event data may choose to use this type to store the + * collected event data. This activity record should be used when + * event domain instance information needs to be associated with the + * event. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityInstantaneousEventInstance extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityInstantaneousEventInstance() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityInstantaneousEventInstance(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityInstantaneousEventInstance(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityInstantaneousEventInstance position(long position) { + return (CUpti_ActivityInstantaneousEventInstance)super.position(position); + } + @Override public CUpti_ActivityInstantaneousEventInstance getPointer(long i) { + return new CUpti_ActivityInstantaneousEventInstance((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_INSTANTANEOUS_EVENT_INSTANCE. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityInstantaneousEventInstance kind(int setter); + + /** + * The event ID. + */ + public native @Cast("CUpti_EventID") int id(); public native CUpti_ActivityInstantaneousEventInstance id(int setter); + + /** + * The event value. + */ + public native @Cast("uint64_t") long value(); public native CUpti_ActivityInstantaneousEventInstance value(long setter); + + /** + * The timestamp at which event is sampled + */ + public native @Cast("uint64_t") long timestamp(); public native CUpti_ActivityInstantaneousEventInstance timestamp(long setter); + + /** + * The device id + */ + public native @Cast("uint32_t") int deviceId(); public native CUpti_ActivityInstantaneousEventInstance deviceId(int setter); + + /** + * The event domain instance + */ + public native @Cast("uint8_t") byte instance(); public native CUpti_ActivityInstantaneousEventInstance instance(byte setter); + + /** + * Undefined. reserved for internal use + */ + public native @Cast("uint8_t") byte pad(int i); public native CUpti_ActivityInstantaneousEventInstance pad(int i, byte setter); + @MemberGetter public native @Cast("uint8_t*") BytePointer pad(); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstantaneousMetric.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstantaneousMetric.java new file mode 100644 index 00000000000..a31156f3d3e --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstantaneousMetric.java @@ -0,0 +1,79 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for an instantaneous CUPTI metric. + * + * This activity record represents the collection of a CUPTI metric + * value (CUPTI_ACTIVITY_KIND_METRIC) at a particular instance. + * This activity record kind is not produced by the activity API but + * is included for completeness and ease-of-use. Profiler frameworks built + * on top of CUPTI that collect metric data may choose to use this type to + * store the collected metric data. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityInstantaneousMetric extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityInstantaneousMetric() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityInstantaneousMetric(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityInstantaneousMetric(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityInstantaneousMetric position(long position) { + return (CUpti_ActivityInstantaneousMetric)super.position(position); + } + @Override public CUpti_ActivityInstantaneousMetric getPointer(long i) { + return new CUpti_ActivityInstantaneousMetric((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_INSTANTANEOUS_METRIC. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityInstantaneousMetric kind(int setter); + + /** + * The metric ID. + */ + public native @Cast("CUpti_MetricID") int id(); public native CUpti_ActivityInstantaneousMetric id(int setter); + + /** + * The metric value. + */ + public native @ByRef CUpti_MetricValue value(); public native CUpti_ActivityInstantaneousMetric value(CUpti_MetricValue setter); + + /** + * The timestamp at which metric is sampled + */ + public native @Cast("uint64_t") long timestamp(); public native CUpti_ActivityInstantaneousMetric timestamp(long setter); + + /** + * The device id + */ + public native @Cast("uint32_t") int deviceId(); public native CUpti_ActivityInstantaneousMetric deviceId(int setter); + + /** + * The properties of this metric. @see CUpti_ActivityFlag + */ + public native @Cast("uint8_t") byte flags(); public native CUpti_ActivityInstantaneousMetric flags(byte setter); + + /** + * Undefined. reserved for internal use + */ + public native @Cast("uint8_t") byte pad(int i); public native CUpti_ActivityInstantaneousMetric pad(int i, byte setter); + @MemberGetter public native @Cast("uint8_t*") BytePointer pad(); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstantaneousMetricInstance.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstantaneousMetricInstance.java new file mode 100644 index 00000000000..a934221b476 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstantaneousMetricInstance.java @@ -0,0 +1,88 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The instantaneous activity record for a CUPTI metric with instance + * information. +

+ * This activity record represents a CUPTI metric value + * for a specific metric domain instance + * (CUPTI_ACTIVITY_KIND_METRIC_INSTANCE) sampled at a particular time. This + * activity record kind is not produced by the activity API but is included for + * completeness and ease-of-use. Profiler frameworks built on top of + * CUPTI that collect metric data may choose to use this type to store + * the collected metric data. This activity record should be used when + * metric domain instance information needs to be associated with the + * metric. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityInstantaneousMetricInstance extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityInstantaneousMetricInstance() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityInstantaneousMetricInstance(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityInstantaneousMetricInstance(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityInstantaneousMetricInstance position(long position) { + return (CUpti_ActivityInstantaneousMetricInstance)super.position(position); + } + @Override public CUpti_ActivityInstantaneousMetricInstance getPointer(long i) { + return new CUpti_ActivityInstantaneousMetricInstance((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_INSTANTANEOUS_METRIC_INSTANCE. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityInstantaneousMetricInstance kind(int setter); + + /** + * The metric ID. + */ + public native @Cast("CUpti_MetricID") int id(); public native CUpti_ActivityInstantaneousMetricInstance id(int setter); + + /** + * The metric value. + */ + public native @ByRef CUpti_MetricValue value(); public native CUpti_ActivityInstantaneousMetricInstance value(CUpti_MetricValue setter); + + /** + * The timestamp at which metric is sampled + */ + public native @Cast("uint64_t") long timestamp(); public native CUpti_ActivityInstantaneousMetricInstance timestamp(long setter); + + /** + * The device id + */ + public native @Cast("uint32_t") int deviceId(); public native CUpti_ActivityInstantaneousMetricInstance deviceId(int setter); + + /** + * The properties of this metric. @see CUpti_ActivityFlag + */ + public native @Cast("uint8_t") byte flags(); public native CUpti_ActivityInstantaneousMetricInstance flags(byte setter); + + /** + * The metric domain instance + */ + public native @Cast("uint8_t") byte instance(); public native CUpti_ActivityInstantaneousMetricInstance instance(byte setter); + + /** + * Undefined. reserved for internal use + */ + public native @Cast("uint8_t") byte pad(int i); public native CUpti_ActivityInstantaneousMetricInstance pad(int i, byte setter); + @MemberGetter public native @Cast("uint8_t*") BytePointer pad(); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstructionCorrelation.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstructionCorrelation.java new file mode 100644 index 00000000000..4d8bffe6003 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstructionCorrelation.java @@ -0,0 +1,71 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for source-level sass/source + * line-by-line correlation. + * + * This activity records source level sass/source correlation + * information. + * (CUPTI_ACTIVITY_KIND_INSTRUCTION_CORRELATION). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityInstructionCorrelation extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityInstructionCorrelation() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityInstructionCorrelation(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityInstructionCorrelation(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityInstructionCorrelation position(long position) { + return (CUpti_ActivityInstructionCorrelation)super.position(position); + } + @Override public CUpti_ActivityInstructionCorrelation getPointer(long i) { + return new CUpti_ActivityInstructionCorrelation((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_INSTRUCTION_CORRELATION. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityInstructionCorrelation kind(int setter); + + /** + * The properties of this instruction. + */ + public native @Cast("CUpti_ActivityFlag") int flags(); public native CUpti_ActivityInstructionCorrelation flags(int setter); + + /** + * The ID for source locator. + */ + public native @Cast("uint32_t") int sourceLocatorId(); public native CUpti_ActivityInstructionCorrelation sourceLocatorId(int setter); + + /** + * Correlation ID with global/device function name + */ + public native @Cast("uint32_t") int functionId(); public native CUpti_ActivityInstructionCorrelation functionId(int setter); + + /** + * The pc offset for the instruction. + */ + public native @Cast("uint32_t") int pcOffset(); public native CUpti_ActivityInstructionCorrelation pcOffset(int setter); + + /** + * Undefined. Reserved for internal use. + */ + public native @Cast("uint32_t") int pad(); public native CUpti_ActivityInstructionCorrelation pad(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstructionExecution.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstructionExecution.java new file mode 100644 index 00000000000..7f5487c6b0f --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityInstructionExecution.java @@ -0,0 +1,92 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for source-level instruction execution. + * + * This activity records result for source level instruction execution. + * (CUPTI_ACTIVITY_KIND_INSTRUCTION_EXECUTION). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityInstructionExecution extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityInstructionExecution() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityInstructionExecution(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityInstructionExecution(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityInstructionExecution position(long position) { + return (CUpti_ActivityInstructionExecution)super.position(position); + } + @Override public CUpti_ActivityInstructionExecution getPointer(long i) { + return new CUpti_ActivityInstructionExecution((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_INSTRUCTION_EXECUTION. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityInstructionExecution kind(int setter); + + /** + * The properties of this instruction execution. + */ + public native @Cast("CUpti_ActivityFlag") int flags(); public native CUpti_ActivityInstructionExecution flags(int setter); + + /** + * The ID for source locator. + */ + public native @Cast("uint32_t") int sourceLocatorId(); public native CUpti_ActivityInstructionExecution sourceLocatorId(int setter); + + /** + * The correlation ID of the kernel to which this result is associated. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityInstructionExecution correlationId(int setter); + + /** + * Correlation ID with global/device function name + */ + public native @Cast("uint32_t") int functionId(); public native CUpti_ActivityInstructionExecution functionId(int setter); + + /** + * The pc offset for the instruction. + */ + public native @Cast("uint32_t") int pcOffset(); public native CUpti_ActivityInstructionExecution pcOffset(int setter); + + /** + * This increments each time when this instruction is executed by number + * of threads that executed this instruction, regardless of predicate or condition code. + */ + public native @Cast("uint64_t") long threadsExecuted(); public native CUpti_ActivityInstructionExecution threadsExecuted(long setter); + + /** + * This increments each time when this instruction is executed by number + * of threads that executed this instruction with predicate and condition code evaluating to true. + */ + public native @Cast("uint64_t") long notPredOffThreadsExecuted(); public native CUpti_ActivityInstructionExecution notPredOffThreadsExecuted(long setter); + + /** + * The number of times this instruction was executed per warp. It will be incremented + * regardless of predicate or condition code. + */ + public native @Cast("uint32_t") int executed(); public native CUpti_ActivityInstructionExecution executed(int setter); + + /** + * Undefined. Reserved for internal use. + */ + public native @Cast("uint32_t") int pad(); public native CUpti_ActivityInstructionExecution pad(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityJit2.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityJit2.java new file mode 100644 index 00000000000..45a96e25bdc --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityJit2.java @@ -0,0 +1,116 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for JIT operations. + * This activity represents the JIT operations (compile, load, store) of a CUmodule + * from the Compute Cache. + * Gives the exact hashed path of where the cached module is loaded from, + * or where the module will be stored after Just-In-Time (JIT) compilation. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityJit2 extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityJit2() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityJit2(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityJit2(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityJit2 position(long position) { + return (CUpti_ActivityJit2)super.position(position); + } + @Override public CUpti_ActivityJit2 getPointer(long i) { + return new CUpti_ActivityJit2((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind must be CUPTI_ACTIVITY_KIND_JIT. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityJit2 kind(int setter); + + /** + * The JIT entry type. + */ + public native @Cast("CUpti_ActivityJitEntryType") int jitEntryType(); public native CUpti_ActivityJit2 jitEntryType(int setter); + + /** + * The JIT operation type. + */ + public native @Cast("CUpti_ActivityJitOperationType") int jitOperationType(); public native CUpti_ActivityJit2 jitOperationType(int setter); + + /** + * The device ID. + */ + public native @Cast("uint32_t") int deviceId(); public native CUpti_ActivityJit2 deviceId(int setter); + + /** + * The start timestamp for the JIT operation, in ns. A value of 0 for + * both the start and end timestamps indicates that timestamp + * information could not be collected for the JIT operation. + */ + public native @Cast("uint64_t") long start(); public native CUpti_ActivityJit2 start(long setter); + + /** + * The end timestamp for the JIT operation, in ns. A value of 0 for both + * the start and end timestamps indicates that timestamp information + * could not be collected for the JIT operation. + */ + public native @Cast("uint64_t") long end(); public native CUpti_ActivityJit2 end(long setter); + + /** + * The correlation ID of the JIT operation to which + * records belong to. Each JIT operation is + * assigned a unique correlation ID that is identical to the + * correlation ID in the driver or runtime API activity record that + * launched the JIT operation. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityJit2 correlationId(int setter); + + /** + * Internal use. + */ + public native @Cast("uint32_t") int padding(); public native CUpti_ActivityJit2 padding(int setter); + + /** + * The correlation ID to correlate JIT compilation, load and store operations. + * Each JIT compilation unit is assigned a unique correlation ID + * at the time of the JIT compilation. This correlation id can be used + * to find the matching JIT cache load/store records. + */ + public native @Cast("uint64_t") long jitOperationCorrelationId(); public native CUpti_ActivityJit2 jitOperationCorrelationId(long setter); + + /** + * The size of compute cache. + */ + public native @Cast("uint64_t") long cacheSize(); public native CUpti_ActivityJit2 cacheSize(long setter); + + /** + * The path where the fat binary is cached. + */ + public native @Cast("const char*") BytePointer cachePath(); public native CUpti_ActivityJit2 cachePath(BytePointer setter); + + /** + * The ID of the process where the JIT operation is executing. + */ + public native @Cast("uint32_t") int processId(); public native CUpti_ActivityJit2 processId(int setter); + + /** + * The ID of the thread where the JIT operation is executing. + */ + public native @Cast("uint32_t") int threadId(); public native CUpti_ActivityJit2 threadId(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityKernel9.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityKernel9.java new file mode 100644 index 00000000000..f0437a17317 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityKernel9.java @@ -0,0 +1,333 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for kernel. + * + * This activity record represents a kernel execution + * (CUPTI_ACTIVITY_KIND_KERNEL and + * CUPTI_ACTIVITY_KIND_CONCURRENT_KERNEL) + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityKernel9 extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityKernel9() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityKernel9(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityKernel9(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityKernel9 position(long position) { + return (CUpti_ActivityKernel9)super.position(position); + } + @Override public CUpti_ActivityKernel9 getPointer(long i) { + return new CUpti_ActivityKernel9((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_KERNEL or + * CUPTI_ACTIVITY_KIND_CONCURRENT_KERNEL. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityKernel9 kind(int setter); + + /** + * For devices with compute capability 7.0+ cacheConfig values are not updated + * in case field isSharedMemoryCarveoutRequested is set + */ + @Name("cacheConfig.both") public native @Cast("uint8_t") byte cacheConfig_both(); public native CUpti_ActivityKernel9 cacheConfig_both(byte setter); + /** + * The cache configuration requested by the kernel. The value is one + * of the CUfunc_cache enumeration values from cuda.h. + */ + @Name("cacheConfig.config.requested") public native @Cast("uint8_t") @NoOffset byte cacheConfig_config_requested(); public native CUpti_ActivityKernel9 cacheConfig_config_requested(byte setter); + + /** + * The cache configuration used for the kernel. The value is one of + * the CUfunc_cache enumeration values from cuda.h. + */ + @Name("cacheConfig.config.executed") public native @Cast("uint8_t") @NoOffset byte cacheConfig_config_executed(); public native CUpti_ActivityKernel9 cacheConfig_config_executed(byte setter); + + /** + * The shared memory configuration used for the kernel. The value is one of + * the CUsharedconfig enumeration values from cuda.h. + */ + public native @Cast("uint8_t") byte sharedMemoryConfig(); public native CUpti_ActivityKernel9 sharedMemoryConfig(byte setter); + + /** + * The number of registers required for each thread executing the + * kernel. + */ + public native @Cast("uint16_t") short registersPerThread(); public native CUpti_ActivityKernel9 registersPerThread(short setter); + + /** + * The partitioned global caching requested for the kernel. Partitioned + * global caching is required to enable caching on certain chips, such as + * devices with compute capability 5.2. + */ + public native @Cast("CUpti_ActivityPartitionedGlobalCacheConfig") int partitionedGlobalCacheRequested(); public native CUpti_ActivityKernel9 partitionedGlobalCacheRequested(int setter); + + /** + * The partitioned global caching executed for the kernel. Partitioned + * global caching is required to enable caching on certain chips, such as + * devices with compute capability 5.2. Partitioned global caching can be + * automatically disabled if the occupancy requirement of the launch cannot + * support caching. + */ + public native @Cast("CUpti_ActivityPartitionedGlobalCacheConfig") int partitionedGlobalCacheExecuted(); public native CUpti_ActivityKernel9 partitionedGlobalCacheExecuted(int setter); + + /** + * The start timestamp for the kernel execution, in ns. A value of 0 + * for both the start and end timestamps indicates that timestamp + * information could not be collected for the kernel. + */ + public native @Cast("uint64_t") long start(); public native CUpti_ActivityKernel9 start(long setter); + + /** + * The end timestamp for the kernel execution, in ns. A value of 0 + * for both the start and end timestamps indicates that timestamp + * information could not be collected for the kernel. + */ + public native @Cast("uint64_t") long end(); public native CUpti_ActivityKernel9 end(long setter); + + /** + * The completed timestamp for the kernel execution, in ns. It + * represents the completion of all it's child kernels and the + * kernel itself. A value of CUPTI_TIMESTAMP_UNKNOWN indicates that + * the completion time is unknown. + */ + public native @Cast("uint64_t") long completed(); public native CUpti_ActivityKernel9 completed(long setter); + + /** + * The ID of the device where the kernel is executing. + */ + public native @Cast("uint32_t") int deviceId(); public native CUpti_ActivityKernel9 deviceId(int setter); + + /** + * The ID of the context where the kernel is executing. + */ + public native @Cast("uint32_t") int contextId(); public native CUpti_ActivityKernel9 contextId(int setter); + + /** + * The ID of the stream where the kernel is executing. + */ + public native @Cast("uint32_t") int streamId(); public native CUpti_ActivityKernel9 streamId(int setter); + + /** + * The X-dimension grid size for the kernel. + */ + public native int gridX(); public native CUpti_ActivityKernel9 gridX(int setter); + + /** + * The Y-dimension grid size for the kernel. + */ + public native int gridY(); public native CUpti_ActivityKernel9 gridY(int setter); + + /** + * The Z-dimension grid size for the kernel. + */ + public native int gridZ(); public native CUpti_ActivityKernel9 gridZ(int setter); + + /** + * The X-dimension block size for the kernel. + */ + public native int blockX(); public native CUpti_ActivityKernel9 blockX(int setter); + + /** + * The Y-dimension block size for the kernel. + */ + public native int blockY(); public native CUpti_ActivityKernel9 blockY(int setter); + + /** + * The Z-dimension grid size for the kernel. + */ + public native int blockZ(); public native CUpti_ActivityKernel9 blockZ(int setter); + + /** + * The static shared memory allocated for the kernel, in bytes. + */ + public native int staticSharedMemory(); public native CUpti_ActivityKernel9 staticSharedMemory(int setter); + + /** + * The dynamic shared memory reserved for the kernel, in bytes. + */ + public native int dynamicSharedMemory(); public native CUpti_ActivityKernel9 dynamicSharedMemory(int setter); + + /** + * The amount of local memory reserved for each thread, in bytes. + */ + public native @Cast("uint32_t") int localMemoryPerThread(); public native CUpti_ActivityKernel9 localMemoryPerThread(int setter); + + /** + * The total amount of local memory reserved for the kernel, in + * bytes (deprecated in CUDA 11.8). + * Refer field localMemoryTotal_v2 + */ + public native @Cast("uint32_t") int localMemoryTotal(); public native CUpti_ActivityKernel9 localMemoryTotal(int setter); + + /** + * The correlation ID of the kernel. Each kernel execution is + * assigned a unique correlation ID that is identical to the + * correlation ID in the driver or runtime API activity record that + * launched the kernel. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityKernel9 correlationId(int setter); + + /** + * The grid ID of the kernel. Each kernel is assigned a unique + * grid ID at runtime. + */ + public native @Cast("int64_t") long gridId(); public native CUpti_ActivityKernel9 gridId(long setter); + + /** + * The name of the kernel. This name is shared across all activity + * records representing the same kernel, and so should not be + * modified. + */ + public native @Cast("const char*") BytePointer name(); public native CUpti_ActivityKernel9 name(BytePointer setter); + + /** + * Undefined. Reserved for internal use. + */ + public native Pointer reserved0(); public native CUpti_ActivityKernel9 reserved0(Pointer setter); + + /** + * The timestamp when the kernel is queued up in the command buffer, in ns. + * A value of CUPTI_TIMESTAMP_UNKNOWN indicates that the queued time + * could not be collected for the kernel. This timestamp is not collected + * by default. Use API \ref cuptiActivityEnableLatencyTimestamps() to + * enable collection. + * + * Command buffer is a buffer written by CUDA driver to send commands + * like kernel launch, memory copy etc to the GPU. All launches of CUDA + * kernels are asynchronous with respect to the host, the host requests + * the launch by writing commands into the command buffer, then returns + * without checking the GPU's progress. + */ + public native @Cast("uint64_t") long queued(); public native CUpti_ActivityKernel9 queued(long setter); + + /** + * The timestamp when the command buffer containing the kernel launch + * is submitted to the GPU, in ns. A value of CUPTI_TIMESTAMP_UNKNOWN + * indicates that the submitted time could not be collected for the kernel. + * This timestamp is not collected by default. Use API \ref + * cuptiActivityEnableLatencyTimestamps() to enable collection. + */ + public native @Cast("uint64_t") long submitted(); public native CUpti_ActivityKernel9 submitted(long setter); + + /** + * The indicates if the kernel was executed via a regular launch or via a + * single/multi device cooperative launch. @see CUpti_ActivityLaunchType + */ + public native @Cast("uint8_t") byte launchType(); public native CUpti_ActivityKernel9 launchType(byte setter); + + /** + * This indicates if CU_FUNC_ATTRIBUTE_PREFERRED_SHARED_MEMORY_CARVEOUT was + * updated for the kernel launch + */ + public native @Cast("uint8_t") byte isSharedMemoryCarveoutRequested(); public native CUpti_ActivityKernel9 isSharedMemoryCarveoutRequested(byte setter); + + /** + * Shared memory carveout value requested for the function in percentage of + * the total resource. The value will be updated only if field + * isSharedMemoryCarveoutRequested is set. + */ + public native @Cast("uint8_t") byte sharedMemoryCarveoutRequested(); public native CUpti_ActivityKernel9 sharedMemoryCarveoutRequested(byte setter); + + /** + * Undefined. Reserved for internal use. + */ + public native @Cast("uint8_t") byte padding(); public native CUpti_ActivityKernel9 padding(byte setter); + + /** + * Shared memory size set by the driver. + */ + public native @Cast("uint32_t") int sharedMemoryExecuted(); public native CUpti_ActivityKernel9 sharedMemoryExecuted(int setter); + + /** + * The unique ID of the graph node that launched this kernel through graph launch APIs. + * This field will be 0 if the kernel is not launched through graph launch APIs. + */ + public native @Cast("uint64_t") long graphNodeId(); public native CUpti_ActivityKernel9 graphNodeId(long setter); + + /** + * The shared memory limit config for the kernel. This field shows whether user has opted for a + * higher per block limit of dynamic shared memory. + */ + public native @Cast("CUpti_FuncShmemLimitConfig") int shmemLimitConfig(); public native CUpti_ActivityKernel9 shmemLimitConfig(int setter); + + /** + * The unique ID of the graph that launched this kernel through graph launch APIs. + * This field will be 0 if the kernel is not launched through graph launch APIs. + */ + public native @Cast("uint32_t") int graphId(); public native CUpti_ActivityKernel9 graphId(int setter); + + /** + * The pointer to the access policy window. The structure CUaccessPolicyWindow is + * defined in cuda.h. + */ + public native @Cast("CUaccessPolicyWindow*") CUaccessPolicyWindow_v1 pAccessPolicyWindow(); public native CUpti_ActivityKernel9 pAccessPolicyWindow(CUaccessPolicyWindow_v1 setter); + + /** + * The ID of the HW channel on which the kernel is launched. + */ + public native @Cast("uint32_t") int channelID(); public native CUpti_ActivityKernel9 channelID(int setter); + + /** + * The type of the channel + */ + public native @Cast("CUpti_ChannelType") int channelType(); public native CUpti_ActivityKernel9 channelType(int setter); + + /** + * The X-dimension cluster size for the kernel. + * Field is valid for devices with compute capability 9.0 and higher + */ + public native @Cast("uint32_t") int clusterX(); public native CUpti_ActivityKernel9 clusterX(int setter); + + /** + * The Y-dimension cluster size for the kernel. + * Field is valid for devices with compute capability 9.0 and higher + */ + public native @Cast("uint32_t") int clusterY(); public native CUpti_ActivityKernel9 clusterY(int setter); + + /** + * The Z-dimension cluster size for the kernel. + * Field is valid for devices with compute capability 9.0 and higher + */ + public native @Cast("uint32_t") int clusterZ(); public native CUpti_ActivityKernel9 clusterZ(int setter); + + /** + * The cluster scheduling policy for the kernel. Refer CUclusterSchedulingPolicy + * Field is valid for devices with compute capability 9.0 and higher + */ + public native @Cast("uint32_t") int clusterSchedulingPolicy(); public native CUpti_ActivityKernel9 clusterSchedulingPolicy(int setter); + + /** + * The total amount of local memory reserved for the kernel, in + * bytes. + */ + public native @Cast("uint64_t") long localMemoryTotal_v2(); public native CUpti_ActivityKernel9 localMemoryTotal_v2(long setter); + + /** + * The maximum cluster size for the kernel + */ + public native @Cast("uint32_t") int maxPotentialClusterSize(); public native CUpti_ActivityKernel9 maxPotentialClusterSize(int setter); + + /** + * The maximum clusters that could co-exist on the target device for the kernel + */ + public native @Cast("uint32_t") int maxActiveClusters(); public native CUpti_ActivityKernel9 maxActiveClusters(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMarker2.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMarker2.java new file mode 100644 index 00000000000..e3b84128d1b --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMarker2.java @@ -0,0 +1,91 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record providing a marker which is an + * instantaneous point in time. + * + * The marker is specified with a descriptive name and unique id + * (CUPTI_ACTIVITY_KIND_MARKER). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityMarker2 extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityMarker2() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityMarker2(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityMarker2(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityMarker2 position(long position) { + return (CUpti_ActivityMarker2)super.position(position); + } + @Override public CUpti_ActivityMarker2 getPointer(long i) { + return new CUpti_ActivityMarker2((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_MARKER. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityMarker2 kind(int setter); + + /** + * The flags associated with the marker. @see CUpti_ActivityFlag + */ + public native @Cast("CUpti_ActivityFlag") int flags(); public native CUpti_ActivityMarker2 flags(int setter); + + /** + * The timestamp for the marker, in ns. A value of 0 indicates that + * timestamp information could not be collected for the marker. + */ + public native @Cast("uint64_t") long timestamp(); public native CUpti_ActivityMarker2 timestamp(long setter); + + /** + * The marker ID. + */ + public native @Cast("uint32_t") int id(); public native CUpti_ActivityMarker2 id(int setter); + + /** + * The kind of activity object associated with this marker. + */ + public native @Cast("CUpti_ActivityObjectKind") int objectKind(); public native CUpti_ActivityMarker2 objectKind(int setter); + + /** + * The identifier for the activity object associated with this + * marker. 'objectKind' indicates which ID is valid for this record. + */ + public native @ByRef CUpti_ActivityObjectKindId objectId(); public native CUpti_ActivityMarker2 objectId(CUpti_ActivityObjectKindId setter); + + /** + * Undefined. Reserved for internal use. + */ + public native @Cast("uint32_t") int pad(); public native CUpti_ActivityMarker2 pad(int setter); + + + /** + * The marker name for an instantaneous or start marker. This will + * be NULL for an end marker. + */ + public native @Cast("const char*") BytePointer name(); public native CUpti_ActivityMarker2 name(BytePointer setter); + + /** + * The name of the domain to which this marker belongs to. + * This will be NULL for default domain. + */ + public native @Cast("const char*") BytePointer domain(); public native CUpti_ActivityMarker2 domain(BytePointer setter); + +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMarkerData.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMarkerData.java new file mode 100644 index 00000000000..7531cf23df5 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMarkerData.java @@ -0,0 +1,76 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record providing detailed information for a marker. + * + * The marker data contains color, payload, and category. + * (CUPTI_ACTIVITY_KIND_MARKER_DATA). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityMarkerData extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityMarkerData() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityMarkerData(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityMarkerData(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityMarkerData position(long position) { + return (CUpti_ActivityMarkerData)super.position(position); + } + @Override public CUpti_ActivityMarkerData getPointer(long i) { + return new CUpti_ActivityMarkerData((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be + * CUPTI_ACTIVITY_KIND_MARKER_DATA. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityMarkerData kind(int setter); + + /** + * The flags associated with the marker. @see CUpti_ActivityFlag + */ + public native @Cast("CUpti_ActivityFlag") int flags(); public native CUpti_ActivityMarkerData flags(int setter); + + /** + * The marker ID. + */ + public native @Cast("uint32_t") int id(); public native CUpti_ActivityMarkerData id(int setter); + + /** + * Defines the payload format for the value associated with the marker. + */ + public native @Cast("CUpti_MetricValueKind") int payloadKind(); public native CUpti_ActivityMarkerData payloadKind(int setter); + + /** + * The payload value. + */ + public native @ByRef CUpti_MetricValue payload(); public native CUpti_ActivityMarkerData payload(CUpti_MetricValue setter); + + /** + * The color for the marker. + */ + public native @Cast("uint32_t") int color(); public native CUpti_ActivityMarkerData color(int setter); + + /** + * The category for the marker. + */ + public native @Cast("uint32_t") int category(); public native CUpti_ActivityMarkerData category(int setter); + +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemcpy5.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemcpy5.java new file mode 100644 index 00000000000..2711cf1cfa2 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemcpy5.java @@ -0,0 +1,156 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for memory copies. + * + * This activity record represents a memory copy + * (CUPTI_ACTIVITY_KIND_MEMCPY). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityMemcpy5 extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityMemcpy5() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityMemcpy5(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityMemcpy5(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityMemcpy5 position(long position) { + return (CUpti_ActivityMemcpy5)super.position(position); + } + @Override public CUpti_ActivityMemcpy5 getPointer(long i) { + return new CUpti_ActivityMemcpy5((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_MEMCPY. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityMemcpy5 kind(int setter); + + /** + * The kind of the memory copy, stored as a byte to reduce record + * size. @see CUpti_ActivityMemcpyKind + */ + public native @Cast("uint8_t") byte copyKind(); public native CUpti_ActivityMemcpy5 copyKind(byte setter); + + /** + * The source memory kind read by the memory copy, stored as a byte + * to reduce record size. @see CUpti_ActivityMemoryKind + */ + public native @Cast("uint8_t") byte srcKind(); public native CUpti_ActivityMemcpy5 srcKind(byte setter); + + /** + * The destination memory kind read by the memory copy, stored as a + * byte to reduce record size. @see CUpti_ActivityMemoryKind + */ + public native @Cast("uint8_t") byte dstKind(); public native CUpti_ActivityMemcpy5 dstKind(byte setter); + + /** + * The flags associated with the memory copy. @see CUpti_ActivityFlag + */ + public native @Cast("uint8_t") byte flags(); public native CUpti_ActivityMemcpy5 flags(byte setter); + + /** + * The number of bytes transferred by the memory copy. + */ + public native @Cast("uint64_t") long bytes(); public native CUpti_ActivityMemcpy5 bytes(long setter); + + /** + * The start timestamp for the memory copy, in ns. A value of 0 for + * both the start and end timestamps indicates that timestamp + * information could not be collected for the memory copy. + */ + public native @Cast("uint64_t") long start(); public native CUpti_ActivityMemcpy5 start(long setter); + + /** + * The end timestamp for the memory copy, in ns. A value of 0 for + * both the start and end timestamps indicates that timestamp + * information could not be collected for the memory copy. + */ + public native @Cast("uint64_t") long end(); public native CUpti_ActivityMemcpy5 end(long setter); + + /** + * The ID of the device where the memory copy is occurring. + */ + public native @Cast("uint32_t") int deviceId(); public native CUpti_ActivityMemcpy5 deviceId(int setter); + + /** + * The ID of the context where the memory copy is occurring. + */ + public native @Cast("uint32_t") int contextId(); public native CUpti_ActivityMemcpy5 contextId(int setter); + + /** + * The ID of the stream where the memory copy is occurring. + */ + public native @Cast("uint32_t") int streamId(); public native CUpti_ActivityMemcpy5 streamId(int setter); + + /** + * The correlation ID of the memory copy. Each memory copy is + * assigned a unique correlation ID that is identical to the + * correlation ID in the driver API activity record that launched + * the memory copy. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityMemcpy5 correlationId(int setter); + + /** + * The runtime correlation ID of the memory copy. Each memory copy + * is assigned a unique runtime correlation ID that is identical to + * the correlation ID in the runtime API activity record that + * launched the memory copy. + */ + public native @Cast("uint32_t") int runtimeCorrelationId(); public native CUpti_ActivityMemcpy5 runtimeCorrelationId(int setter); + +// #ifdef CUPTILP64 + /** + * Undefined. Reserved for internal use. + */ + public native @Cast("uint32_t") int pad(); public native CUpti_ActivityMemcpy5 pad(int setter); +// #endif + + /** + * Undefined. Reserved for internal use. + */ + public native Pointer reserved0(); public native CUpti_ActivityMemcpy5 reserved0(Pointer setter); + + /** + * The unique ID of the graph node that executed this memcpy through graph launch. + * This field will be 0 if the memcpy is not done through graph launch. + */ + public native @Cast("uint64_t") long graphNodeId(); public native CUpti_ActivityMemcpy5 graphNodeId(long setter); + + /** + * The unique ID of the graph that executed this memcpy through graph launch. + * This field will be 0 if the memcpy is not done through graph launch. + */ + public native @Cast("uint32_t") int graphId(); public native CUpti_ActivityMemcpy5 graphId(int setter); + + /** + * The ID of the HW channel on which the memory copy is occurring. + */ + public native @Cast("uint32_t") int channelID(); public native CUpti_ActivityMemcpy5 channelID(int setter); + + /** + * The type of the channel + */ + public native @Cast("CUpti_ChannelType") int channelType(); public native CUpti_ActivityMemcpy5 channelType(int setter); + + /** + * Reserved for internal use. + */ + public native @Cast("uint32_t") int pad2(); public native CUpti_ActivityMemcpy5 pad2(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemcpyPtoP4.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemcpyPtoP4.java new file mode 100644 index 00000000000..991780fbf90 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemcpyPtoP4.java @@ -0,0 +1,160 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for peer-to-peer memory copies. + * + * This activity record represents a peer-to-peer memory copy + * (CUPTI_ACTIVITY_KIND_MEMCPY2). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityMemcpyPtoP4 extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityMemcpyPtoP4() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityMemcpyPtoP4(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityMemcpyPtoP4(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityMemcpyPtoP4 position(long position) { + return (CUpti_ActivityMemcpyPtoP4)super.position(position); + } + @Override public CUpti_ActivityMemcpyPtoP4 getPointer(long i) { + return new CUpti_ActivityMemcpyPtoP4((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_MEMCPY2. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityMemcpyPtoP4 kind(int setter); + + /** + * The kind of the memory copy, stored as a byte to reduce record + * size. @see CUpti_ActivityMemcpyKind + */ + public native @Cast("uint8_t") byte copyKind(); public native CUpti_ActivityMemcpyPtoP4 copyKind(byte setter); + + /** + * The source memory kind read by the memory copy, stored as a byte + * to reduce record size. @see CUpti_ActivityMemoryKind + */ + public native @Cast("uint8_t") byte srcKind(); public native CUpti_ActivityMemcpyPtoP4 srcKind(byte setter); + + /** + * The destination memory kind read by the memory copy, stored as a + * byte to reduce record size. @see CUpti_ActivityMemoryKind + */ + public native @Cast("uint8_t") byte dstKind(); public native CUpti_ActivityMemcpyPtoP4 dstKind(byte setter); + + /** + * The flags associated with the memory copy. @see + * CUpti_ActivityFlag + */ + public native @Cast("uint8_t") byte flags(); public native CUpti_ActivityMemcpyPtoP4 flags(byte setter); + + /** + * The number of bytes transferred by the memory copy. + */ + public native @Cast("uint64_t") long bytes(); public native CUpti_ActivityMemcpyPtoP4 bytes(long setter); + + /** + * The start timestamp for the memory copy, in ns. A value of 0 for + * both the start and end timestamps indicates that timestamp + * information could not be collected for the memory copy. + */ + public native @Cast("uint64_t") long start(); public native CUpti_ActivityMemcpyPtoP4 start(long setter); + + /** + * The end timestamp for the memory copy, in ns. A value of 0 for + * both the start and end timestamps indicates that timestamp + * information could not be collected for the memory copy. + */ + public native @Cast("uint64_t") long end(); public native CUpti_ActivityMemcpyPtoP4 end(long setter); + + /** + * The ID of the device where the memory copy is occurring. + */ + public native @Cast("uint32_t") int deviceId(); public native CUpti_ActivityMemcpyPtoP4 deviceId(int setter); + + /** + * The ID of the context where the memory copy is occurring. + */ + public native @Cast("uint32_t") int contextId(); public native CUpti_ActivityMemcpyPtoP4 contextId(int setter); + + /** + * The ID of the stream where the memory copy is occurring. + */ + public native @Cast("uint32_t") int streamId(); public native CUpti_ActivityMemcpyPtoP4 streamId(int setter); + + /** + * The ID of the device where memory is being copied from. + */ + public native @Cast("uint32_t") int srcDeviceId(); public native CUpti_ActivityMemcpyPtoP4 srcDeviceId(int setter); + + /** + * The ID of the context owning the memory being copied from. + */ + public native @Cast("uint32_t") int srcContextId(); public native CUpti_ActivityMemcpyPtoP4 srcContextId(int setter); + + /** + * The ID of the device where memory is being copied to. + */ + public native @Cast("uint32_t") int dstDeviceId(); public native CUpti_ActivityMemcpyPtoP4 dstDeviceId(int setter); + + /** + * The ID of the context owning the memory being copied to. + */ + public native @Cast("uint32_t") int dstContextId(); public native CUpti_ActivityMemcpyPtoP4 dstContextId(int setter); + + /** + * The correlation ID of the memory copy. Each memory copy is + * assigned a unique correlation ID that is identical to the + * correlation ID in the driver and runtime API activity record that + * launched the memory copy. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityMemcpyPtoP4 correlationId(int setter); + +// #ifndef CUPTILP64 +// #endif + + /** + * Undefined. Reserved for internal use. + */ + public native Pointer reserved0(); public native CUpti_ActivityMemcpyPtoP4 reserved0(Pointer setter); + + /** + * The unique ID of the graph node that executed the memcpy through graph launch. + * This field will be 0 if memcpy is not done using graph launch. + */ + public native @Cast("uint64_t") long graphNodeId(); public native CUpti_ActivityMemcpyPtoP4 graphNodeId(long setter); + + /** + * The unique ID of the graph that executed this memcpy through graph launch. + * This field will be 0 if the memcpy is not done through graph launch. + */ + public native @Cast("uint32_t") int graphId(); public native CUpti_ActivityMemcpyPtoP4 graphId(int setter); + + /** + * The ID of the HW channel on which the memory copy is occurring. + */ + public native @Cast("uint32_t") int channelID(); public native CUpti_ActivityMemcpyPtoP4 channelID(int setter); + + /** + * The type of the channel + */ + public native @Cast("CUpti_ChannelType") int channelType(); public native CUpti_ActivityMemcpyPtoP4 channelType(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemory.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemory.java new file mode 100644 index 00000000000..464cd58bbf3 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemory.java @@ -0,0 +1,120 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for memory. + * + * This activity record represents a memory allocation and free operation + * (CUPTI_ACTIVITY_KIND_MEMORY). + * This activity record provides a single record for the memory + * allocation and memory release operations. + * + * Note: It is recommended to move to the new activity record \ref CUpti_ActivityMemory4 + * enabled using the kind \ref CUPTI_ACTIVITY_KIND_MEMORY2. + * \ref CUpti_ActivityMemory4 provides separate records for memory + * allocation and memory release operations. This allows to correlate the + * corresponding driver and runtime API activity record with the memory operation. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityMemory extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityMemory() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityMemory(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityMemory(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityMemory position(long position) { + return (CUpti_ActivityMemory)super.position(position); + } + @Override public CUpti_ActivityMemory getPointer(long i) { + return new CUpti_ActivityMemory((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_MEMORY + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityMemory kind(int setter); + + /** + * The memory kind requested by the user + */ + public native @Cast("CUpti_ActivityMemoryKind") int memoryKind(); public native CUpti_ActivityMemory memoryKind(int setter); + + /** + * The virtual address of the allocation + */ + public native @Cast("uint64_t") @Name("address") long _address(); public native CUpti_ActivityMemory _address(long setter); + + /** + * The number of bytes of memory allocated. + */ + public native @Cast("uint64_t") long bytes(); public native CUpti_ActivityMemory bytes(long setter); + + /** + * The start timestamp for the memory operation, i.e. + * the time when memory was allocated, in ns. + */ + public native @Cast("uint64_t") long start(); public native CUpti_ActivityMemory start(long setter); + + /** + * The end timestamp for the memory operation, i.e. + * the time when memory was freed, in ns. + * This will be 0 if memory is not freed in the application + */ + public native @Cast("uint64_t") long end(); public native CUpti_ActivityMemory end(long setter); + + /** + * The program counter of the allocation of memory + */ + public native @Cast("uint64_t") long allocPC(); public native CUpti_ActivityMemory allocPC(long setter); + + /** + * The program counter of the freeing of memory. This will + * be 0 if memory is not freed in the application + */ + public native @Cast("uint64_t") long freePC(); public native CUpti_ActivityMemory freePC(long setter); + + /** + * The ID of the process to which this record belongs to. + */ + public native @Cast("uint32_t") int processId(); public native CUpti_ActivityMemory processId(int setter); + + /** + * The ID of the device where the memory allocation is taking place. + */ + public native @Cast("uint32_t") int deviceId(); public native CUpti_ActivityMemory deviceId(int setter); + + /** + * The ID of the context. If context is NULL, \p contextId is set to CUPTI_INVALID_CONTEXT_ID. + */ + public native @Cast("uint32_t") int contextId(); public native CUpti_ActivityMemory contextId(int setter); + +// #ifdef CUPTILP64 + /** + * Undefined. Reserved for internal use. + */ + public native @Cast("uint32_t") int pad(); public native CUpti_ActivityMemory pad(int setter); +// #endif + + /** + * Variable name. This name is shared across all activity + * records representing the same symbol, and so should not be + * modified. + */ + public native @Cast("const char*") BytePointer name(); public native CUpti_ActivityMemory name(BytePointer setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemory4.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemory4.java new file mode 100644 index 00000000000..b740e43546e --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemory4.java @@ -0,0 +1,177 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for memory. + * + * This activity record represents a memory allocation and free operation + * (CUPTI_ACTIVITY_KIND_MEMORY2). + * This activity record provides separate records for memory allocation and + * memory release operations. + * This allows to correlate the corresponding driver and runtime API + * activity record with the memory operation. + * + * Note: This activity record is an upgrade over \ref CUpti_ActivityMemory + * enabled using the kind \ref CUPTI_ACTIVITY_KIND_MEMORY. + * \ref CUpti_ActivityMemory provides a single record for the memory + * allocation and memory release operations. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityMemory4 extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityMemory4() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityMemory4(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityMemory4(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityMemory4 position(long position) { + return (CUpti_ActivityMemory4)super.position(position); + } + @Override public CUpti_ActivityMemory4 getPointer(long i) { + return new CUpti_ActivityMemory4((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_MEMORY2 + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityMemory4 kind(int setter); + + /** + * The memory operation requested by the user, \ref CUpti_ActivityMemoryOperationType. + */ + public native @Cast("CUpti_ActivityMemoryOperationType") int memoryOperationType(); public native CUpti_ActivityMemory4 memoryOperationType(int setter); + + /** + * The memory kind requested by the user, \ref CUpti_ActivityMemoryKind. + */ + public native @Cast("CUpti_ActivityMemoryKind") int memoryKind(); public native CUpti_ActivityMemory4 memoryKind(int setter); + + /** + * The correlation ID of the memory operation. Each memory operation is + * assigned a unique correlation ID that is identical to the + * correlation ID in the driver and runtime API activity record that + * launched the memory operation. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityMemory4 correlationId(int setter); + + /** + * The virtual address of the allocation. + */ + public native @Cast("uint64_t") @Name("address") long _address(); public native CUpti_ActivityMemory4 _address(long setter); + + /** + * The number of bytes of memory allocated. + */ + public native @Cast("uint64_t") long bytes(); public native CUpti_ActivityMemory4 bytes(long setter); + + /** + * The start timestamp for the memory operation, in ns. + */ + public native @Cast("uint64_t") long timestamp(); public native CUpti_ActivityMemory4 timestamp(long setter); + + /** + * The program counter of the memory operation. + */ + public native @Cast("uint64_t") long PC(); public native CUpti_ActivityMemory4 PC(long setter); + + /** + * The ID of the process to which this record belongs to. + */ + public native @Cast("uint32_t") int processId(); public native CUpti_ActivityMemory4 processId(int setter); + + /** + * The ID of the device where the memory operation is taking place. + */ + public native @Cast("uint32_t") int deviceId(); public native CUpti_ActivityMemory4 deviceId(int setter); + + /** + * The ID of the context. If context is NULL, \p contextId is set to CUPTI_INVALID_CONTEXT_ID. + */ + public native @Cast("uint32_t") int contextId(); public native CUpti_ActivityMemory4 contextId(int setter); + + /** + * The ID of the stream. If memory operation is not async, \p streamId is set to CUPTI_INVALID_STREAM_ID. + */ + public native @Cast("uint32_t") int streamId(); public native CUpti_ActivityMemory4 streamId(int setter); + + /** + * Variable name. This name is shared across all activity + * records representing the same symbol, and so should not be + * modified. + */ + public native @Cast("const char*") BytePointer name(); public native CUpti_ActivityMemory4 name(BytePointer setter); + + /** + * \p isAsync is set if memory operation happens through async memory APIs. + */ + public native @Cast("uint32_t") int isAsync(); public native CUpti_ActivityMemory4 isAsync(int setter); + +// #ifdef CUPTILP64 + /** + * Undefined. Reserved for internal use. + */ + public native @Cast("uint32_t") int pad1(); public native CUpti_ActivityMemory4 pad1(int setter); +// #endif + + /** + * The memory pool configuration used for the memory operations. + */ + /** + * The type of the memory pool, \ref CUpti_ActivityMemoryPoolType + */ + @Name("memoryPoolConfig.memoryPoolType") public native @Cast("CUpti_ActivityMemoryPoolType") int memoryPoolConfig_memoryPoolType(); public native CUpti_ActivityMemory4 memoryPoolConfig_memoryPoolType(int setter); + +// #ifdef CUPTILP64 + /** + * Undefined. Reserved for internal use. + */ + @Name("memoryPoolConfig.pad2") public native @Cast("uint32_t") int memoryPoolConfig_pad2(); public native CUpti_ActivityMemory4 memoryPoolConfig_pad2(int setter); +// #endif + + /** + * The base address of the memory pool. + */ + @Name("memoryPoolConfig.address") public native @Cast("uint64_t") long memoryPoolConfig_address(); public native CUpti_ActivityMemory4 memoryPoolConfig_address(long setter); + + /** + * The release threshold of the memory pool in bytes. \p releaseThreshold is + * valid for CUPTI_ACTIVITY_MEMORY_POOL_TYPE_LOCAL, \ref CUpti_ActivityMemoryPoolType. + */ + @Name("memoryPoolConfig.releaseThreshold") public native @Cast("uint64_t") long memoryPoolConfig_releaseThreshold(); public native CUpti_ActivityMemory4 memoryPoolConfig_releaseThreshold(long setter); + + /** + * The size of memory pool in bytes and the processId of the memory pools + * \p size is valid if \p memoryPoolType is + * CUPTI_ACTIVITY_MEMORY_POOL_TYPE_LOCAL, \ref CUpti_ActivityMemoryPoolType. + * \p processId is valid if \p memoryPoolType is + * CUPTI_ACTIVITY_MEMORY_POOL_TYPE_IMPORTED, \ref CUpti_ActivityMemoryPoolType + */ + @Name("memoryPoolConfig.pool.size") public native @Cast("uint64_t") long memoryPoolConfig_pool_size(); public native CUpti_ActivityMemory4 memoryPoolConfig_pool_size(long setter); + @Name("memoryPoolConfig.pool.processId") public native @Cast("uint64_t") long memoryPoolConfig_pool_processId(); public native CUpti_ActivityMemory4 memoryPoolConfig_pool_processId(long setter); + + /** + * The utilized size of the memory pool. \p utilizedSize is + * valid for CUPTI_ACTIVITY_MEMORY_POOL_TYPE_LOCAL, \ref CUpti_ActivityMemoryPoolType. + */ + @Name("memoryPoolConfig.utilizedSize") public native @Cast("uint64_t") long memoryPoolConfig_utilizedSize(); public native CUpti_ActivityMemory4 memoryPoolConfig_utilizedSize(long setter); + + /** + * The shared object or binary that the memory allocation request comes from. + */ + public native @Cast("const char*") BytePointer source(); public native CUpti_ActivityMemory4 source(BytePointer setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemoryPool2.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemoryPool2.java new file mode 100644 index 00000000000..e73f753ec9b --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemoryPool2.java @@ -0,0 +1,115 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for memory pool. + * + * This activity record represents a memory pool creation, destruction and + * trimming (CUPTI_ACTIVITY_KIND_MEMORY_POOL). + * This activity record provides separate records for memory pool creation, + * destruction and trimming operations. + * This allows to correlate the corresponding driver and runtime API + * activity record with the memory pool operation. + * + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityMemoryPool2 extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityMemoryPool2() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityMemoryPool2(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityMemoryPool2(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityMemoryPool2 position(long position) { + return (CUpti_ActivityMemoryPool2)super.position(position); + } + @Override public CUpti_ActivityMemoryPool2 getPointer(long i) { + return new CUpti_ActivityMemoryPool2((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_MEMORY_POOL + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityMemoryPool2 kind(int setter); + + /** + * The memory operation requested by the user, \ref CUpti_ActivityMemoryPoolOperationType. + */ + public native @Cast("CUpti_ActivityMemoryPoolOperationType") int memoryPoolOperationType(); public native CUpti_ActivityMemoryPool2 memoryPoolOperationType(int setter); + + /** + * The type of the memory pool, \ref CUpti_ActivityMemoryPoolType + */ + public native @Cast("CUpti_ActivityMemoryPoolType") int memoryPoolType(); public native CUpti_ActivityMemoryPool2 memoryPoolType(int setter); + + /** + * The correlation ID of the memory pool operation. Each memory pool + * operation is assigned a unique correlation ID that is identical to the + * correlation ID in the driver and runtime API activity record that + * launched the memory operation. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityMemoryPool2 correlationId(int setter); + + /** + * The ID of the process to which this record belongs to. + */ + public native @Cast("uint32_t") int processId(); public native CUpti_ActivityMemoryPool2 processId(int setter); + + /** + * The ID of the device where the memory pool is created. + */ + public native @Cast("uint32_t") int deviceId(); public native CUpti_ActivityMemoryPool2 deviceId(int setter); + + /** + * The minimum bytes to keep of the memory pool. \p minBytesToKeep is + * valid for CUPTI_ACTIVITY_MEMORY_POOL_OPERATION_TYPE_TRIMMED, + * \ref CUpti_ActivityMemoryPoolOperationType + */ + public native @Cast("size_t") long minBytesToKeep(); public native CUpti_ActivityMemoryPool2 minBytesToKeep(long setter); + +// #ifndef CUPTILP64 +// #endif + + /** + * The virtual address of the allocation. + */ + public native @Cast("uint64_t") @Name("address") long _address(); public native CUpti_ActivityMemoryPool2 _address(long setter); + + /** + * The size of the memory pool operation in bytes. \p size is + * valid for CUPTI_ACTIVITY_MEMORY_POOL_TYPE_LOCAL, \ref CUpti_ActivityMemoryPoolType. + */ + public native @Cast("uint64_t") long size(); public native CUpti_ActivityMemoryPool2 size(long setter); + + /** + * The release threshold of the memory pool. \p releaseThreshold is + * valid for CUPTI_ACTIVITY_MEMORY_POOL_TYPE_LOCAL, \ref CUpti_ActivityMemoryPoolType. + */ + public native @Cast("uint64_t") long releaseThreshold(); public native CUpti_ActivityMemoryPool2 releaseThreshold(long setter); + + /** + * The start timestamp for the memory operation, in ns. + */ + public native @Cast("uint64_t") long timestamp(); public native CUpti_ActivityMemoryPool2 timestamp(long setter); + + /** + * The utilized size of the memory pool. \p utilizedSize is + * valid for CUPTI_ACTIVITY_MEMORY_POOL_TYPE_LOCAL, \ref CUpti_ActivityMemoryPoolType. + */ + public native @Cast("uint64_t") long utilizedSize(); public native CUpti_ActivityMemoryPool2 utilizedSize(long setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemset4.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemset4.java new file mode 100644 index 00000000000..eee64039bb4 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMemset4.java @@ -0,0 +1,139 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for memset. + * + * This activity record represents a memory set operation + * (CUPTI_ACTIVITY_KIND_MEMSET). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityMemset4 extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityMemset4() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityMemset4(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityMemset4(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityMemset4 position(long position) { + return (CUpti_ActivityMemset4)super.position(position); + } + @Override public CUpti_ActivityMemset4 getPointer(long i) { + return new CUpti_ActivityMemset4((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_MEMSET. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityMemset4 kind(int setter); + + /** + * The value being assigned to memory by the memory set. + */ + public native @Cast("uint32_t") int value(); public native CUpti_ActivityMemset4 value(int setter); + + /** + * The number of bytes being set by the memory set. + */ + public native @Cast("uint64_t") long bytes(); public native CUpti_ActivityMemset4 bytes(long setter); + + /** + * The start timestamp for the memory set, in ns. A value of 0 for + * both the start and end timestamps indicates that timestamp + * information could not be collected for the memory set. + */ + public native @Cast("uint64_t") long start(); public native CUpti_ActivityMemset4 start(long setter); + + /** + * The end timestamp for the memory set, in ns. A value of 0 for + * both the start and end timestamps indicates that timestamp + * information could not be collected for the memory set. + */ + public native @Cast("uint64_t") long end(); public native CUpti_ActivityMemset4 end(long setter); + + /** + * The ID of the device where the memory set is occurring. + */ + public native @Cast("uint32_t") int deviceId(); public native CUpti_ActivityMemset4 deviceId(int setter); + + /** + * The ID of the context where the memory set is occurring. + */ + public native @Cast("uint32_t") int contextId(); public native CUpti_ActivityMemset4 contextId(int setter); + + /** + * The ID of the stream where the memory set is occurring. + */ + public native @Cast("uint32_t") int streamId(); public native CUpti_ActivityMemset4 streamId(int setter); + + /** + * The correlation ID of the memory set. Each memory set is assigned + * a unique correlation ID that is identical to the correlation ID + * in the driver API activity record that launched the memory set. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityMemset4 correlationId(int setter); + + /** + * The flags associated with the memset. @see CUpti_ActivityFlag + */ + public native @Cast("uint16_t") short flags(); public native CUpti_ActivityMemset4 flags(short setter); + + /** + * The memory kind of the memory set @see CUpti_ActivityMemoryKind + */ + public native @Cast("uint16_t") short memoryKind(); public native CUpti_ActivityMemset4 memoryKind(short setter); + +// #ifdef CUPTILP64 + /** + * Undefined. Reserved for internal use. + */ + public native @Cast("uint32_t") int pad(); public native CUpti_ActivityMemset4 pad(int setter); +// #endif + + /** + * Undefined. Reserved for internal use. + */ + public native Pointer reserved0(); public native CUpti_ActivityMemset4 reserved0(Pointer setter); + + /** + * The unique ID of the graph node that executed this memset through graph launch. + * This field will be 0 if the memset is not executed through graph launch. + */ + public native @Cast("uint64_t") long graphNodeId(); public native CUpti_ActivityMemset4 graphNodeId(long setter); + + /** + * The unique ID of the graph that executed this memset through graph launch. + * This field will be 0 if the memset is not executed through graph launch. + */ + public native @Cast("uint32_t") int graphId(); public native CUpti_ActivityMemset4 graphId(int setter); + + /** + * The ID of the HW channel on which the memory set is occurring. + */ + public native @Cast("uint32_t") int channelID(); public native CUpti_ActivityMemset4 channelID(int setter); + + /** + * The type of the channel + */ + public native @Cast("CUpti_ChannelType") int channelType(); public native CUpti_ActivityMemset4 channelType(int setter); + + /** + * Undefined. Reserved for internal use + */ + public native @Cast("uint32_t") int pad2(); public native CUpti_ActivityMemset4 pad2(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMetric.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMetric.java new file mode 100644 index 00000000000..41883ac038f --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMetric.java @@ -0,0 +1,76 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for a CUPTI metric. + * + * This activity record represents the collection of a CUPTI metric + * value (CUPTI_ACTIVITY_KIND_METRIC). This activity record kind is not + * produced by the activity API but is included for completeness and + * ease-of-use. Profile frameworks built on top of CUPTI that collect + * metric data may choose to use this type to store the collected metric + * data. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityMetric extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityMetric() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityMetric(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityMetric(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityMetric position(long position) { + return (CUpti_ActivityMetric)super.position(position); + } + @Override public CUpti_ActivityMetric getPointer(long i) { + return new CUpti_ActivityMetric((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_METRIC. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityMetric kind(int setter); + + /** + * The metric ID. + */ + public native @Cast("CUpti_MetricID") int id(); public native CUpti_ActivityMetric id(int setter); + + /** + * The metric value. + */ + public native @ByRef CUpti_MetricValue value(); public native CUpti_ActivityMetric value(CUpti_MetricValue setter); + + /** + * The correlation ID of the metric. Use of this ID is user-defined, + * but typically this ID value will equal the correlation ID of the + * kernel for which the metric was gathered. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityMetric correlationId(int setter); + + /** + * The properties of this metric. @see CUpti_ActivityFlag + */ + public native @Cast("uint8_t") byte flags(); public native CUpti_ActivityMetric flags(byte setter); + + /** + * Undefined. Reserved for internal use. + */ + public native @Cast("uint8_t") byte pad(int i); public native CUpti_ActivityMetric pad(int i, byte setter); + @MemberGetter public native @Cast("uint8_t*") BytePointer pad(); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMetricInstance.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMetricInstance.java new file mode 100644 index 00000000000..668f56d8ba5 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityMetricInstance.java @@ -0,0 +1,86 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for a CUPTI metric with instance + * information. + * + * This activity record represents a CUPTI metric value + * for a specific metric domain instance + * (CUPTI_ACTIVITY_KIND_METRIC_INSTANCE). This activity record kind + * is not produced by the activity API but is included for + * completeness and ease-of-use. Profile frameworks built on top of + * CUPTI that collect metric data may choose to use this type to store + * the collected metric data. This activity record should be used when + * metric domain instance information needs to be associated with the + * metric. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityMetricInstance extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityMetricInstance() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityMetricInstance(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityMetricInstance(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityMetricInstance position(long position) { + return (CUpti_ActivityMetricInstance)super.position(position); + } + @Override public CUpti_ActivityMetricInstance getPointer(long i) { + return new CUpti_ActivityMetricInstance((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be + * CUPTI_ACTIVITY_KIND_METRIC_INSTANCE. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityMetricInstance kind(int setter); + + /** + * The metric ID. + */ + public native @Cast("CUpti_MetricID") int id(); public native CUpti_ActivityMetricInstance id(int setter); + + /** + * The metric value. + */ + public native @ByRef CUpti_MetricValue value(); public native CUpti_ActivityMetricInstance value(CUpti_MetricValue setter); + + /** + * The metric domain instance. + */ + public native @Cast("uint32_t") int instance(); public native CUpti_ActivityMetricInstance instance(int setter); + + /** + * The correlation ID of the metric. Use of this ID is user-defined, + * but typically this ID value will equal the correlation ID of the + * kernel for which the metric was gathered. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityMetricInstance correlationId(int setter); + + /** + * The properties of this metric. @see CUpti_ActivityFlag + */ + public native @Cast("uint8_t") byte flags(); public native CUpti_ActivityMetricInstance flags(byte setter); + + /** + * Undefined. Reserved for internal use. + */ + public native @Cast("uint8_t") byte pad(int i); public native CUpti_ActivityMetricInstance pad(int i, byte setter); + @MemberGetter public native @Cast("uint8_t*") BytePointer pad(); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityModule.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityModule.java new file mode 100644 index 00000000000..83a8e6cc727 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityModule.java @@ -0,0 +1,71 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for a CUDA module. + * + * This activity record represents a CUDA module + * (CUPTI_ACTIVITY_KIND_MODULE). This activity record kind is not + * produced by the activity API but is included for completeness and + * ease-of-use. Profile frameworks built on top of CUPTI that collect + * module data from the module callback may choose to use this type to + * store the collected module data. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityModule extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityModule() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityModule(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityModule(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityModule position(long position) { + return (CUpti_ActivityModule)super.position(position); + } + @Override public CUpti_ActivityModule getPointer(long i) { + return new CUpti_ActivityModule((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_MODULE. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityModule kind(int setter); + + /** + * The ID of the context where the module is loaded. + */ + public native @Cast("uint32_t") int contextId(); public native CUpti_ActivityModule contextId(int setter); + + /** + * The module ID. + */ + public native @Cast("uint32_t") int id(); public native CUpti_ActivityModule id(int setter); + + /** + * The cubin size. + */ + public native @Cast("uint32_t") int cubinSize(); public native CUpti_ActivityModule cubinSize(int setter); + +// #ifndef CUPTILP64 +// #endif + + /** + * The pointer to cubin. + */ + public native @Const Pointer cubin(); public native CUpti_ActivityModule cubin(Pointer setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityName.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityName.java new file mode 100644 index 00000000000..2d67756a092 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityName.java @@ -0,0 +1,69 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record providing a name. + * + * This activity record provides a name for a device, context, thread, + * etc. and other resource naming done via NVTX APIs + * (CUPTI_ACTIVITY_KIND_NAME). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityName extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityName() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityName(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityName(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityName position(long position) { + return (CUpti_ActivityName)super.position(position); + } + @Override public CUpti_ActivityName getPointer(long i) { + return new CUpti_ActivityName((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_NAME. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityName kind(int setter); + + /** + * The kind of activity object being named. + */ + public native @Cast("CUpti_ActivityObjectKind") int objectKind(); public native CUpti_ActivityName objectKind(int setter); + + /** + * The identifier for the activity object. 'objectKind' indicates + * which ID is valid for this record. + */ + public native @ByRef CUpti_ActivityObjectKindId objectId(); public native CUpti_ActivityName objectId(CUpti_ActivityObjectKindId setter); + +// #ifdef CUPTILP64 + /** + * Undefined. Reserved for internal use. + */ + public native @Cast("uint32_t") int pad(); public native CUpti_ActivityName pad(int setter); +// #endif + + /** + * The name. + */ + public native @Cast("const char*") BytePointer name(); public native CUpti_ActivityName name(BytePointer setter); + +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityNvLink4.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityNvLink4.java new file mode 100644 index 00000000000..3f3e1ea2f24 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityNvLink4.java @@ -0,0 +1,141 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** +* \brief NVLink information. +* +* This structure gives capabilities of each logical NVLink connection between two devices, +* gpu<->gpu or gpu<->CPU which can be used to understand the topology. +*/ + +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityNvLink4 extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityNvLink4() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityNvLink4(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityNvLink4(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityNvLink4 position(long position) { + return (CUpti_ActivityNvLink4)super.position(position); + } + @Override public CUpti_ActivityNvLink4 getPointer(long i) { + return new CUpti_ActivityNvLink4((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_NVLINK. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityNvLink4 kind(int setter); + + /** + * NvLink version. + */ + public native @Cast("uint32_t") int nvlinkVersion(); public native CUpti_ActivityNvLink4 nvlinkVersion(int setter); + + /** + * Type of device 0 \ref CUpti_DevType + */ + public native @Cast("CUpti_DevType") int typeDev0(); public native CUpti_ActivityNvLink4 typeDev0(int setter); + + /** + * Type of device 1 \ref CUpti_DevType + */ + public native @Cast("CUpti_DevType") int typeDev1(); public native CUpti_ActivityNvLink4 typeDev1(int setter); + + /** + * If typeDev0 is CUPTI_DEV_TYPE_GPU, UUID for device 0. \ref CUpti_ActivityDevice5. + * If typeDev0 is CUPTI_DEV_TYPE_NPU, struct npu for NPU. + */ + @Name("idDev0.uuidDev") public native @ByRef CUuuid idDev0_uuidDev(); public native CUpti_ActivityNvLink4 idDev0_uuidDev(CUuuid setter); + /** + * Index of the NPU. First index will always be zero. + */ + @Name("idDev0.npu.index") public native @Cast("uint32_t") int idDev0_npu_index(); public native CUpti_ActivityNvLink4 idDev0_npu_index(int setter); + + /** + * Domain ID of NPU. On Linux, this can be queried using lspci. + */ + @Name("idDev0.npu.domainId") public native @Cast("uint32_t") int idDev0_npu_domainId(); public native CUpti_ActivityNvLink4 idDev0_npu_domainId(int setter); + + /** + * If typeDev1 is CUPTI_DEV_TYPE_GPU, UUID for device 1. \ref CUpti_ActivityDevice5. + * If typeDev1 is CUPTI_DEV_TYPE_NPU, struct npu for NPU. + */ + @Name("idDev1.uuidDev") public native @ByRef CUuuid idDev1_uuidDev(); public native CUpti_ActivityNvLink4 idDev1_uuidDev(CUuuid setter); + + /** + * Index of the NPU. First index will always be zero. + */ + @Name("idDev1.npu.index") public native @Cast("uint32_t") int idDev1_npu_index(); public native CUpti_ActivityNvLink4 idDev1_npu_index(int setter); + + /** + * Domain ID of NPU. On Linux, this can be queried using lspci. + */ + @Name("idDev1.npu.domainId") public native @Cast("uint32_t") int idDev1_npu_domainId(); public native CUpti_ActivityNvLink4 idDev1_npu_domainId(int setter); + + /** + * Flag gives capabilities of the link @see CUpti_LinkFlag + */ + public native @Cast("uint32_t") int flag(); public native CUpti_ActivityNvLink4 flag(int setter); + + /** + * Number of physical NVLinks present between two devices. + */ + public native @Cast("uint32_t") int physicalNvLinkCount(); public native CUpti_ActivityNvLink4 physicalNvLinkCount(int setter); + + /** + * Port numbers for maximum 32 NVLinks connected to device 0. + * If typeDev0 is CUPTI_DEV_TYPE_NPU, ignore this field. + * In case of invalid/unknown port number, this field will be set + * to value CUPTI_NVLINK_INVALID_PORT. + * This will be used to correlate the metric values to individual + * physical link and attribute traffic to the logical NVLink in + * the topology. + */ + public native byte portDev0(int i); public native CUpti_ActivityNvLink4 portDev0(int i, byte setter); + @MemberGetter public native BytePointer portDev0(); + + /** + * Port numbers for maximum 32 NVLinks connected to device 1. + * If typeDev1 is CUPTI_DEV_TYPE_NPU, ignore this field. + * In case of invalid/unknown port number, this field will be set + * to value CUPTI_NVLINK_INVALID_PORT. + * This will be used to correlate the metric values to individual + * physical link and attribute traffic to the logical NVLink in + * the topology. + */ + public native byte portDev1(int i); public native CUpti_ActivityNvLink4 portDev1(int i, byte setter); + @MemberGetter public native BytePointer portDev1(); + + /** + * Bandwidth of NVLink in kbytes/sec + */ + public native @Cast("uint64_t") long bandwidth(); public native CUpti_ActivityNvLink4 bandwidth(long setter); + + /** + * NVSwitch is connected as an intermediate node. + */ + public native @Cast("uint8_t") byte nvswitchConnected(); public native CUpti_ActivityNvLink4 nvswitchConnected(byte setter); + + /** + * Undefined. reserved for internal use + */ + public native @Cast("uint8_t") byte pad(int i); public native CUpti_ActivityNvLink4 pad(int i, byte setter); + @MemberGetter public native @Cast("uint8_t*") BytePointer pad(); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityObjectKindId.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityObjectKindId.java new file mode 100644 index 00000000000..bdfbfff53ab --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityObjectKindId.java @@ -0,0 +1,56 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief Identifiers for object kinds as specified by + * CUpti_ActivityObjectKind. + * @see CUpti_ActivityObjectKind + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityObjectKindId extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityObjectKindId() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityObjectKindId(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityObjectKindId(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityObjectKindId position(long position) { + return (CUpti_ActivityObjectKindId)super.position(position); + } + @Override public CUpti_ActivityObjectKindId getPointer(long i) { + return new CUpti_ActivityObjectKindId((Pointer)this).offsetAddress(i); + } + + /** + * A process object requires that we identify the process ID. A + * thread object requires that we identify both the process and + * thread ID. + */ + @Name("pt.processId") public native @Cast("uint32_t") int pt_processId(); public native CUpti_ActivityObjectKindId pt_processId(int setter); + @Name("pt.threadId") public native @Cast("uint32_t") int pt_threadId(); public native CUpti_ActivityObjectKindId pt_threadId(int setter); + + /** + * A device object requires that we identify the device ID. A + * context object requires that we identify both the device and + * context ID. A stream object requires that we identify device, + * context, and stream ID. + */ + @Name("dcs.deviceId") public native @Cast("uint32_t") int dcs_deviceId(); public native CUpti_ActivityObjectKindId dcs_deviceId(int setter); + @Name("dcs.contextId") public native @Cast("uint32_t") int dcs_contextId(); public native CUpti_ActivityObjectKindId dcs_contextId(int setter); + @Name("dcs.streamId") public native @Cast("uint32_t") int dcs_streamId(); public native CUpti_ActivityObjectKindId dcs_streamId(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOpenAcc.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOpenAcc.java new file mode 100644 index 00000000000..3c1b9ea17f5 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOpenAcc.java @@ -0,0 +1,184 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The base activity record for OpenAcc records. + * + * The OpenACC activity API part uses a CUpti_ActivityOpenAcc as a generic + * representation for any OpenACC activity. The 'kind' field is used to determine the + * specific activity kind, and from that the CUpti_ActivityOpenAcc object can + * be cast to the specific OpenACC activity record type appropriate for that kind. + * + * Note that all OpenACC activity record types are padded and aligned to + * ensure that each member of the record is naturally aligned. + * + * @see CUpti_ActivityKind + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityOpenAcc extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityOpenAcc() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityOpenAcc(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityOpenAcc(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityOpenAcc position(long position) { + return (CUpti_ActivityOpenAcc)super.position(position); + } + @Override public CUpti_ActivityOpenAcc getPointer(long i) { + return new CUpti_ActivityOpenAcc((Pointer)this).offsetAddress(i); + } + + /** + * The kind of this activity. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityOpenAcc kind(int setter); + + /** + * CUPTI OpenACC event kind (@see CUpti_OpenAccEventKind) + */ + public native @Cast("CUpti_OpenAccEventKind") int eventKind(); public native CUpti_ActivityOpenAcc eventKind(int setter); + + /** + * CUPTI OpenACC parent construct kind (@see CUpti_OpenAccConstructKind) + * + * Note that for applications using PGI OpenACC runtime < 16.1, this + * will always be CUPTI_OPENACC_CONSTRUCT_KIND_UNKNOWN. + */ + public native @Cast("CUpti_OpenAccConstructKind") int parentConstruct(); public native CUpti_ActivityOpenAcc parentConstruct(int setter); + + /** + * Version number + */ + public native @Cast("uint32_t") int version(); public native CUpti_ActivityOpenAcc version(int setter); + + /** + * 1 for any implicit event, such as an implicit wait at a synchronous data construct + * 0 otherwise + */ + public native @Cast("uint32_t") int implicit(); public native CUpti_ActivityOpenAcc implicit(int setter); + + /** + * Device type + */ + public native @Cast("uint32_t") int deviceType(); public native CUpti_ActivityOpenAcc deviceType(int setter); + + /** + * Device number + */ + public native @Cast("uint32_t") int deviceNumber(); public native CUpti_ActivityOpenAcc deviceNumber(int setter); + + /** + * ThreadId + */ + public native @Cast("uint32_t") int threadId(); public native CUpti_ActivityOpenAcc threadId(int setter); + + /** + * Value of async() clause of the corresponding directive + */ + public native @Cast("uint64_t") long async(); public native CUpti_ActivityOpenAcc async(long setter); + + /** + * Internal asynchronous queue number used + */ + public native @Cast("uint64_t") long asyncMap(); public native CUpti_ActivityOpenAcc asyncMap(long setter); + + /** + * The line number of the directive or program construct or the starting line + * number of the OpenACC construct corresponding to the event. + * A zero value means the line number is not known. + */ + public native @Cast("uint32_t") int lineNo(); public native CUpti_ActivityOpenAcc lineNo(int setter); + + /** + * For an OpenACC construct, this contains the line number of the end + * of the construct. A zero value means the line number is not known. + */ + public native @Cast("uint32_t") int endLineNo(); public native CUpti_ActivityOpenAcc endLineNo(int setter); + + /** + * The line number of the first line of the function named in funcName. + * A zero value means the line number is not known. + */ + public native @Cast("uint32_t") int funcLineNo(); public native CUpti_ActivityOpenAcc funcLineNo(int setter); + + /** + * The last line number of the function named in funcName. + * A zero value means the line number is not known. + */ + public native @Cast("uint32_t") int funcEndLineNo(); public native CUpti_ActivityOpenAcc funcEndLineNo(int setter); + + /** + * CUPTI start timestamp + */ + public native @Cast("uint64_t") long start(); public native CUpti_ActivityOpenAcc start(long setter); + + /** + * CUPTI end timestamp + */ + public native @Cast("uint64_t") long end(); public native CUpti_ActivityOpenAcc end(long setter); + + /** + * CUDA device id + * Valid only if deviceType is acc_device_nvidia. + */ + public native @Cast("uint32_t") int cuDeviceId(); public native CUpti_ActivityOpenAcc cuDeviceId(int setter); + + /** + * CUDA context id + * Valid only if deviceType is acc_device_nvidia. + */ + public native @Cast("uint32_t") int cuContextId(); public native CUpti_ActivityOpenAcc cuContextId(int setter); + + /** + * CUDA stream id + * Valid only if deviceType is acc_device_nvidia. + */ + public native @Cast("uint32_t") int cuStreamId(); public native CUpti_ActivityOpenAcc cuStreamId(int setter); + + /** + * The ID of the process where the OpenACC activity is executing. + */ + public native @Cast("uint32_t") int cuProcessId(); public native CUpti_ActivityOpenAcc cuProcessId(int setter); + + /** + * The ID of the thread where the OpenACC activity is executing. + */ + public native @Cast("uint32_t") int cuThreadId(); public native CUpti_ActivityOpenAcc cuThreadId(int setter); + + /** + * The OpenACC correlation ID. + * Valid only if deviceType is acc_device_nvidia. + * If not 0, it uniquely identifies this record. It is identical to the + * externalId in the preceding external correlation record of type + * CUPTI_EXTERNAL_CORRELATION_KIND_OPENACC. + */ + public native @Cast("uint32_t") int externalId(); public native CUpti_ActivityOpenAcc externalId(int setter); + + /* + * A pointer to null-terminated string containing the name of or path to + * the source file, if known, or a null pointer if not. + */ + public native @Cast("const char*") BytePointer srcFile(); public native CUpti_ActivityOpenAcc srcFile(BytePointer setter); + + /* + * A pointer to a null-terminated string containing the name of the + * function in which the event occurred. + */ + public native @Cast("const char*") BytePointer funcName(); public native CUpti_ActivityOpenAcc funcName(BytePointer setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOpenAccData.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOpenAccData.java new file mode 100644 index 00000000000..c10c2a38f3e --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOpenAccData.java @@ -0,0 +1,203 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for OpenACC data. + * + * (CUPTI_ACTIVITY_KIND_OPENACC_DATA). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityOpenAccData extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityOpenAccData() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityOpenAccData(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityOpenAccData(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityOpenAccData position(long position) { + return (CUpti_ActivityOpenAccData)super.position(position); + } + @Override public CUpti_ActivityOpenAccData getPointer(long i) { + return new CUpti_ActivityOpenAccData((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_OPENACC_DATA. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityOpenAccData kind(int setter); + + /** + * CUPTI OpenACC event kind (@see CUpti_OpenAccEventKind) + */ + public native @Cast("CUpti_OpenAccEventKind") int eventKind(); public native CUpti_ActivityOpenAccData eventKind(int setter); + + /* + * CUPTI OpenACC parent construct kind (\see CUpti_OpenAccConstructKind) + * + * Note that for applications using PGI OpenACC runtime < 16.1, this + * will always be CUPTI_OPENACC_CONSTRUCT_KIND_UNKNOWN. + */ + public native @Cast("CUpti_OpenAccConstructKind") int parentConstruct(); public native CUpti_ActivityOpenAccData parentConstruct(int setter); + + /* + * Version number + */ + public native @Cast("uint32_t") int version(); public native CUpti_ActivityOpenAccData version(int setter); + + /* + * 1 for any implicit event, such as an implicit wait at a synchronous data construct + * 0 otherwise + */ + public native @Cast("uint32_t") int implicit(); public native CUpti_ActivityOpenAccData implicit(int setter); + + /* + * Device type + */ + public native @Cast("uint32_t") int deviceType(); public native CUpti_ActivityOpenAccData deviceType(int setter); + + /* + * Device number + */ + public native @Cast("uint32_t") int deviceNumber(); public native CUpti_ActivityOpenAccData deviceNumber(int setter); + + /** + * ThreadId + */ + public native @Cast("uint32_t") int threadId(); public native CUpti_ActivityOpenAccData threadId(int setter); + + /* + * Value of async() clause of the corresponding directive + */ + public native @Cast("uint64_t") long async(); public native CUpti_ActivityOpenAccData async(long setter); + + /* + * Internal asynchronous queue number used + */ + public native @Cast("uint64_t") long asyncMap(); public native CUpti_ActivityOpenAccData asyncMap(long setter); + + /* + * The line number of the directive or program construct or the starting line + * number of the OpenACC construct corresponding to the event. + * A negative or zero value means the line number is not known. + */ + public native @Cast("uint32_t") int lineNo(); public native CUpti_ActivityOpenAccData lineNo(int setter); + + /* + * For an OpenACC construct, this contains the line number of the end + * of the construct. A negative or zero value means the line number is not known. + */ + public native @Cast("uint32_t") int endLineNo(); public native CUpti_ActivityOpenAccData endLineNo(int setter); + + /* + * The line number of the first line of the function named in func_name. + * A negative or zero value means the line number is not known. + */ + public native @Cast("uint32_t") int funcLineNo(); public native CUpti_ActivityOpenAccData funcLineNo(int setter); + + /* + * The last line number of the function named in func_name. + * A negative or zero value means the line number is not known. + */ + public native @Cast("uint32_t") int funcEndLineNo(); public native CUpti_ActivityOpenAccData funcEndLineNo(int setter); + + /** + * CUPTI start timestamp + */ + public native @Cast("uint64_t") long start(); public native CUpti_ActivityOpenAccData start(long setter); + + /** + * CUPTI end timestamp + */ + public native @Cast("uint64_t") long end(); public native CUpti_ActivityOpenAccData end(long setter); + + /** + * CUDA device id + * Valid only if deviceType is acc_device_nvidia. + */ + public native @Cast("uint32_t") int cuDeviceId(); public native CUpti_ActivityOpenAccData cuDeviceId(int setter); + + /** + * CUDA context id + * Valid only if deviceType is acc_device_nvidia. + */ + public native @Cast("uint32_t") int cuContextId(); public native CUpti_ActivityOpenAccData cuContextId(int setter); + + /** + * CUDA stream id + * Valid only if deviceType is acc_device_nvidia. + */ + public native @Cast("uint32_t") int cuStreamId(); public native CUpti_ActivityOpenAccData cuStreamId(int setter); + + /** + * The ID of the process where the OpenACC activity is executing. + */ + public native @Cast("uint32_t") int cuProcessId(); public native CUpti_ActivityOpenAccData cuProcessId(int setter); + + /** + * The ID of the thread where the OpenACC activity is executing. + */ + public native @Cast("uint32_t") int cuThreadId(); public native CUpti_ActivityOpenAccData cuThreadId(int setter); + + /** + * The OpenACC correlation ID. + * Valid only if deviceType is acc_device_nvidia. + * If not 0, it uniquely identifies this record. It is identical to the + * externalId in the preceding external correlation record of type + * CUPTI_EXTERNAL_CORRELATION_KIND_OPENACC. + */ + public native @Cast("uint32_t") int externalId(); public native CUpti_ActivityOpenAccData externalId(int setter); + + /* + * A pointer to null-terminated string containing the name of or path to + * the source file, if known, or a null pointer if not. + */ + public native @Cast("const char*") BytePointer srcFile(); public native CUpti_ActivityOpenAccData srcFile(BytePointer setter); + + /* + * A pointer to a null-terminated string containing the name of the + * function in which the event occurred. + */ + public native @Cast("const char*") BytePointer funcName(); public native CUpti_ActivityOpenAccData funcName(BytePointer setter); + + /* --- end of common CUpti_ActivityOpenAcc part --- */ + + /** + * Number of bytes + */ + public native @Cast("uint64_t") long bytes(); public native CUpti_ActivityOpenAccData bytes(long setter); + + /** + * Host pointer if available + */ + public native @Cast("uint64_t") long hostPtr(); public native CUpti_ActivityOpenAccData hostPtr(long setter); + + /** + * Device pointer if available + */ + public native @Cast("uint64_t") long devicePtr(); public native CUpti_ActivityOpenAccData devicePtr(long setter); + +// #ifndef CUPTILP64 +// #endif + + /* + * A pointer to null-terminated string containing the name of the variable + * for which this event is triggered, if known, or a null pointer if not. + */ + public native @Cast("const char*") BytePointer varName(); public native CUpti_ActivityOpenAccData varName(BytePointer setter); + +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOpenAccLaunch.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOpenAccLaunch.java new file mode 100644 index 00000000000..0d7df568a0e --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOpenAccLaunch.java @@ -0,0 +1,203 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for OpenACC launch. + * + * (CUPTI_ACTIVITY_KIND_OPENACC_LAUNCH). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityOpenAccLaunch extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityOpenAccLaunch() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityOpenAccLaunch(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityOpenAccLaunch(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityOpenAccLaunch position(long position) { + return (CUpti_ActivityOpenAccLaunch)super.position(position); + } + @Override public CUpti_ActivityOpenAccLaunch getPointer(long i) { + return new CUpti_ActivityOpenAccLaunch((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_OPENACC_LAUNCH. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityOpenAccLaunch kind(int setter); + + /** + * CUPTI OpenACC event kind (@see CUpti_OpenAccEventKind) + */ + public native @Cast("CUpti_OpenAccEventKind") int eventKind(); public native CUpti_ActivityOpenAccLaunch eventKind(int setter); + + /** + * CUPTI OpenACC parent construct kind (@see CUpti_OpenAccConstructKind) + * + * Note that for applications using PGI OpenACC runtime < 16.1, this + * will always be CUPTI_OPENACC_CONSTRUCT_KIND_UNKNOWN. + */ + public native @Cast("CUpti_OpenAccConstructKind") int parentConstruct(); public native CUpti_ActivityOpenAccLaunch parentConstruct(int setter); + + /** + * Version number + */ + public native @Cast("uint32_t") int version(); public native CUpti_ActivityOpenAccLaunch version(int setter); + + /** + * 1 for any implicit event, such as an implicit wait at a synchronous data construct + * 0 otherwise + */ + public native @Cast("uint32_t") int implicit(); public native CUpti_ActivityOpenAccLaunch implicit(int setter); + + /** + * Device type + */ + public native @Cast("uint32_t") int deviceType(); public native CUpti_ActivityOpenAccLaunch deviceType(int setter); + + /** + * Device number + */ + public native @Cast("uint32_t") int deviceNumber(); public native CUpti_ActivityOpenAccLaunch deviceNumber(int setter); + + /** + * ThreadId + */ + public native @Cast("uint32_t") int threadId(); public native CUpti_ActivityOpenAccLaunch threadId(int setter); + + /** + * Value of async() clause of the corresponding directive + */ + public native @Cast("uint64_t") long async(); public native CUpti_ActivityOpenAccLaunch async(long setter); + + /** + * Internal asynchronous queue number used + */ + public native @Cast("uint64_t") long asyncMap(); public native CUpti_ActivityOpenAccLaunch asyncMap(long setter); + + /** + * The line number of the directive or program construct or the starting line + * number of the OpenACC construct corresponding to the event. + * A negative or zero value means the line number is not known. + */ + public native @Cast("uint32_t") int lineNo(); public native CUpti_ActivityOpenAccLaunch lineNo(int setter); + + /** + * For an OpenACC construct, this contains the line number of the end + * of the construct. A negative or zero value means the line number is not known. + */ + public native @Cast("uint32_t") int endLineNo(); public native CUpti_ActivityOpenAccLaunch endLineNo(int setter); + + /** + * The line number of the first line of the function named in func_name. + * A negative or zero value means the line number is not known. + */ + public native @Cast("uint32_t") int funcLineNo(); public native CUpti_ActivityOpenAccLaunch funcLineNo(int setter); + + /** + * The last line number of the function named in func_name. + * A negative or zero value means the line number is not known. + */ + public native @Cast("uint32_t") int funcEndLineNo(); public native CUpti_ActivityOpenAccLaunch funcEndLineNo(int setter); + + /** + * CUPTI start timestamp + */ + public native @Cast("uint64_t") long start(); public native CUpti_ActivityOpenAccLaunch start(long setter); + + /** + * CUPTI end timestamp + */ + public native @Cast("uint64_t") long end(); public native CUpti_ActivityOpenAccLaunch end(long setter); + + /** + * CUDA device id + * Valid only if deviceType is acc_device_nvidia. + */ + public native @Cast("uint32_t") int cuDeviceId(); public native CUpti_ActivityOpenAccLaunch cuDeviceId(int setter); + + /** + * CUDA context id + * Valid only if deviceType is acc_device_nvidia. + */ + public native @Cast("uint32_t") int cuContextId(); public native CUpti_ActivityOpenAccLaunch cuContextId(int setter); + + /** + * CUDA stream id + * Valid only if deviceType is acc_device_nvidia. + */ + public native @Cast("uint32_t") int cuStreamId(); public native CUpti_ActivityOpenAccLaunch cuStreamId(int setter); + + /** + * The ID of the process where the OpenACC activity is executing. + */ + public native @Cast("uint32_t") int cuProcessId(); public native CUpti_ActivityOpenAccLaunch cuProcessId(int setter); + + /** + * The ID of the thread where the OpenACC activity is executing. + */ + public native @Cast("uint32_t") int cuThreadId(); public native CUpti_ActivityOpenAccLaunch cuThreadId(int setter); + + /** + * The OpenACC correlation ID. + * Valid only if deviceType is acc_device_nvidia. + * If not 0, it uniquely identifies this record. It is identical to the + * externalId in the preceding external correlation record of type + * CUPTI_EXTERNAL_CORRELATION_KIND_OPENACC. + */ + public native @Cast("uint32_t") int externalId(); public native CUpti_ActivityOpenAccLaunch externalId(int setter); + + /** + * A pointer to null-terminated string containing the name of or path to + * the source file, if known, or a null pointer if not. + */ + public native @Cast("const char*") BytePointer srcFile(); public native CUpti_ActivityOpenAccLaunch srcFile(BytePointer setter); + + /** + * A pointer to a null-terminated string containing the name of the + * function in which the event occurred. + */ + public native @Cast("const char*") BytePointer funcName(); public native CUpti_ActivityOpenAccLaunch funcName(BytePointer setter); + + /* --- end of common CUpti_ActivityOpenAcc part --- */ + + /** + * The number of gangs created for this kernel launch + */ + public native @Cast("uint64_t") long numGangs(); public native CUpti_ActivityOpenAccLaunch numGangs(long setter); + + /** + * The number of workers created for this kernel launch + */ + public native @Cast("uint64_t") long numWorkers(); public native CUpti_ActivityOpenAccLaunch numWorkers(long setter); + + /** + * The number of vector lanes created for this kernel launch + */ + public native @Cast("uint64_t") long vectorLength(); public native CUpti_ActivityOpenAccLaunch vectorLength(long setter); + +// #ifndef CUPTILP64 +// #endif + + /** + * A pointer to null-terminated string containing the name of the + * kernel being launched, if known, or a null pointer if not. + */ + public native @Cast("const char*") BytePointer kernelName(); public native CUpti_ActivityOpenAccLaunch kernelName(BytePointer setter); + +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOpenAccOther.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOpenAccOther.java new file mode 100644 index 00000000000..84fc4943e5c --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOpenAccOther.java @@ -0,0 +1,178 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for OpenACC other. + * + * (CUPTI_ACTIVITY_KIND_OPENACC_OTHER). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityOpenAccOther extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityOpenAccOther() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityOpenAccOther(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityOpenAccOther(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityOpenAccOther position(long position) { + return (CUpti_ActivityOpenAccOther)super.position(position); + } + @Override public CUpti_ActivityOpenAccOther getPointer(long i) { + return new CUpti_ActivityOpenAccOther((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_OPENACC_OTHER. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityOpenAccOther kind(int setter); + + /** + * CUPTI OpenACC event kind (@see CUpti_OpenAccEventKind) + */ + public native @Cast("CUpti_OpenAccEventKind") int eventKind(); public native CUpti_ActivityOpenAccOther eventKind(int setter); + + /** + * CUPTI OpenACC parent construct kind (@see CUpti_OpenAccConstructKind) + * + * Note that for applications using PGI OpenACC runtime < 16.1, this + * will always be CUPTI_OPENACC_CONSTRUCT_KIND_UNKNOWN. + */ + public native @Cast("CUpti_OpenAccConstructKind") int parentConstruct(); public native CUpti_ActivityOpenAccOther parentConstruct(int setter); + + /** + * Version number + */ + public native @Cast("uint32_t") int version(); public native CUpti_ActivityOpenAccOther version(int setter); + + /** + * 1 for any implicit event, such as an implicit wait at a synchronous data construct + * 0 otherwise + */ + public native @Cast("uint32_t") int implicit(); public native CUpti_ActivityOpenAccOther implicit(int setter); + + /** + * Device type + */ + public native @Cast("uint32_t") int deviceType(); public native CUpti_ActivityOpenAccOther deviceType(int setter); + + /** + * Device number + */ + public native @Cast("uint32_t") int deviceNumber(); public native CUpti_ActivityOpenAccOther deviceNumber(int setter); + + /** + * ThreadId + */ + public native @Cast("uint32_t") int threadId(); public native CUpti_ActivityOpenAccOther threadId(int setter); + + /** + * Value of async() clause of the corresponding directive + */ + public native @Cast("uint64_t") long async(); public native CUpti_ActivityOpenAccOther async(long setter); + + /** + * Internal asynchronous queue number used + */ + public native @Cast("uint64_t") long asyncMap(); public native CUpti_ActivityOpenAccOther asyncMap(long setter); + + /** + * The line number of the directive or program construct or the starting line + * number of the OpenACC construct corresponding to the event. + * A negative or zero value means the line number is not known. + */ + public native @Cast("uint32_t") int lineNo(); public native CUpti_ActivityOpenAccOther lineNo(int setter); + + /** + * For an OpenACC construct, this contains the line number of the end + * of the construct. A negative or zero value means the line number is not known. + */ + public native @Cast("uint32_t") int endLineNo(); public native CUpti_ActivityOpenAccOther endLineNo(int setter); + + /** + * The line number of the first line of the function named in func_name. + * A negative or zero value means the line number is not known. + */ + public native @Cast("uint32_t") int funcLineNo(); public native CUpti_ActivityOpenAccOther funcLineNo(int setter); + + /** + * The last line number of the function named in func_name. + * A negative or zero value means the line number is not known. + */ + public native @Cast("uint32_t") int funcEndLineNo(); public native CUpti_ActivityOpenAccOther funcEndLineNo(int setter); + + /** + * CUPTI start timestamp + */ + public native @Cast("uint64_t") long start(); public native CUpti_ActivityOpenAccOther start(long setter); + + /** + * CUPTI end timestamp + */ + public native @Cast("uint64_t") long end(); public native CUpti_ActivityOpenAccOther end(long setter); + + /** + * CUDA device id + * Valid only if deviceType is acc_device_nvidia. + */ + public native @Cast("uint32_t") int cuDeviceId(); public native CUpti_ActivityOpenAccOther cuDeviceId(int setter); + + /** + * CUDA context id + * Valid only if deviceType is acc_device_nvidia. + */ + public native @Cast("uint32_t") int cuContextId(); public native CUpti_ActivityOpenAccOther cuContextId(int setter); + + /** + * CUDA stream id + * Valid only if deviceType is acc_device_nvidia. + */ + public native @Cast("uint32_t") int cuStreamId(); public native CUpti_ActivityOpenAccOther cuStreamId(int setter); + + /** + * The ID of the process where the OpenACC activity is executing. + */ + public native @Cast("uint32_t") int cuProcessId(); public native CUpti_ActivityOpenAccOther cuProcessId(int setter); + + /** + * The ID of the thread where the OpenACC activity is executing. + */ + public native @Cast("uint32_t") int cuThreadId(); public native CUpti_ActivityOpenAccOther cuThreadId(int setter); + + /** + * The OpenACC correlation ID. + * Valid only if deviceType is acc_device_nvidia. + * If not 0, it uniquely identifies this record. It is identical to the + * externalId in the preceding external correlation record of type + * CUPTI_EXTERNAL_CORRELATION_KIND_OPENACC. + */ + public native @Cast("uint32_t") int externalId(); public native CUpti_ActivityOpenAccOther externalId(int setter); + + /** + * A pointer to null-terminated string containing the name of or path to + * the source file, if known, or a null pointer if not. + */ + public native @Cast("const char*") BytePointer srcFile(); public native CUpti_ActivityOpenAccOther srcFile(BytePointer setter); + + /** + * A pointer to a null-terminated string containing the name of the + * function in which the event occurred. + */ + public native @Cast("const char*") BytePointer funcName(); public native CUpti_ActivityOpenAccOther funcName(BytePointer setter); + + /* --- end of common CUpti_ActivityOpenAcc part --- */ +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOpenMp.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOpenMp.java new file mode 100644 index 00000000000..a6b30d5b499 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOpenMp.java @@ -0,0 +1,79 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The base activity record for OpenMp records. + * + * @see CUpti_ActivityKind + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityOpenMp extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityOpenMp() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityOpenMp(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityOpenMp(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityOpenMp position(long position) { + return (CUpti_ActivityOpenMp)super.position(position); + } + @Override public CUpti_ActivityOpenMp getPointer(long i) { + return new CUpti_ActivityOpenMp((Pointer)this).offsetAddress(i); + } + + + /** + * The kind of this activity. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityOpenMp kind(int setter); + + /** + * CUPTI OpenMP event kind (@see CUpti_OpenMpEventKind) + */ + public native @Cast("CUpti_OpenMpEventKind") int eventKind(); public native CUpti_ActivityOpenMp eventKind(int setter); + + /** + * Version number + */ + public native @Cast("uint32_t") int version(); public native CUpti_ActivityOpenMp version(int setter); + + /** + * ThreadId + */ + public native @Cast("uint32_t") int threadId(); public native CUpti_ActivityOpenMp threadId(int setter); + + /** + * CUPTI start timestamp + */ + public native @Cast("uint64_t") long start(); public native CUpti_ActivityOpenMp start(long setter); + + /** + * CUPTI end timestamp + */ + public native @Cast("uint64_t") long end(); public native CUpti_ActivityOpenMp end(long setter); + + /** + * The ID of the process where the OpenMP activity is executing. + */ + public native @Cast("uint32_t") int cuProcessId(); public native CUpti_ActivityOpenMp cuProcessId(int setter); + + /** + * The ID of the thread where the OpenMP activity is executing. + */ + public native @Cast("uint32_t") int cuThreadId(); public native CUpti_ActivityOpenMp cuThreadId(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOverhead3.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOverhead3.java new file mode 100644 index 00000000000..425263c984f --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOverhead3.java @@ -0,0 +1,96 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for CUPTI and driver overheads. + * + * This activity record provides CUPTI and driver overhead information + * (CUPTI_ACTIVITY_OVERHEAD). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityOverhead3 extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityOverhead3() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityOverhead3(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityOverhead3(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityOverhead3 position(long position) { + return (CUpti_ActivityOverhead3)super.position(position); + } + @Override public CUpti_ActivityOverhead3 getPointer(long i) { + return new CUpti_ActivityOverhead3((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_OVERHEAD. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityOverhead3 kind(int setter); + + /** + * The kind of overhead, CUPTI, DRIVER, COMPILER etc. + */ + public native @Cast("CUpti_ActivityOverheadKind") int overheadKind(); public native CUpti_ActivityOverhead3 overheadKind(int setter); + + /** + * The kind of activity object that the overhead is associated with. + */ + public native @Cast("CUpti_ActivityObjectKind") int objectKind(); public native CUpti_ActivityOverhead3 objectKind(int setter); + + /** + * The identifier for the activity object. 'objectKind' indicates + * which ID is valid for this record. + */ + public native @ByRef CUpti_ActivityObjectKindId objectId(); public native CUpti_ActivityOverhead3 objectId(CUpti_ActivityObjectKindId setter); + + /** + * The start timestamp for the overhead, in ns. A value of 0 for + * both the start and end timestamps indicates that timestamp + * information could not be collected for the overhead. + */ + public native @Cast("uint64_t") long start(); public native CUpti_ActivityOverhead3 start(long setter); + + /** + * The end timestamp for the overhead, in ns. A value of 0 for both + * the start and end timestamps indicates that timestamp information + * could not be collected for the overhead. + */ + public native @Cast("uint64_t") long end(); public native CUpti_ActivityOverhead3 end(long setter); + + /** + * The correlation ID of the overhead operation to which + * records belong to. This ID is identical to the + * correlation ID in the driver or runtime API activity record that + * launched the overhead operation. + * In some cases, it can be zero, such as for CUPTI_ACTIVITY_OVERHEAD_CUPTI_BUFFER_FLUSH records. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityOverhead3 correlationId(int setter); + + /** + * Reserved for internal use. + */ + public native @Cast("uint32_t") int reserved0(); public native CUpti_ActivityOverhead3 reserved0(int setter); + + /** + * Pointer to the struct with additional details about the overhead. + * Refer CUpti_ActivityOverheadKind enum and the corresponding structure to typecast and access additional overhead data. + * Client is responsible for freeing this memory using the free function when done. + */ + public native Pointer overheadData(); public native CUpti_ActivityOverhead3 overheadData(Pointer setter); + +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOverheadCommandBufferFullData.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOverheadCommandBufferFullData.java new file mode 100644 index 00000000000..0b80f6bc2b4 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityOverheadCommandBufferFullData.java @@ -0,0 +1,52 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The structure to provide additional data for CUPTI_ACTIVITY_OVERHEAD_COMMAND_BUFFER_FULL. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityOverheadCommandBufferFullData extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityOverheadCommandBufferFullData() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityOverheadCommandBufferFullData(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityOverheadCommandBufferFullData(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityOverheadCommandBufferFullData position(long position) { + return (CUpti_ActivityOverheadCommandBufferFullData)super.position(position); + } + @Override public CUpti_ActivityOverheadCommandBufferFullData getPointer(long i) { + return new CUpti_ActivityOverheadCommandBufferFullData((Pointer)this).offsetAddress(i); + } + + /** + * The length of the command buffer. + * + */ + public native @Cast("uint32_t") int commandBufferLength(); public native CUpti_ActivityOverheadCommandBufferFullData commandBufferLength(int setter); + /** + * The channel ID of the command buffer. + * + */ + public native @Cast("uint32_t") int channelID(); public native CUpti_ActivityOverheadCommandBufferFullData channelID(int setter); + /** + * The channel type of the command buffer. + * + */ + public native @Cast("uint32_t") int channelType(); public native CUpti_ActivityOverheadCommandBufferFullData channelType(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityPCSampling3.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityPCSampling3.java new file mode 100644 index 00000000000..f2790e5f788 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityPCSampling3.java @@ -0,0 +1,90 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for PC sampling. + * + * This activity records information obtained by sampling PC + * (CUPTI_ACTIVITY_KIND_PC_SAMPLING). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityPCSampling3 extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityPCSampling3() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityPCSampling3(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityPCSampling3(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityPCSampling3 position(long position) { + return (CUpti_ActivityPCSampling3)super.position(position); + } + @Override public CUpti_ActivityPCSampling3 getPointer(long i) { + return new CUpti_ActivityPCSampling3((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_PC_SAMPLING. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityPCSampling3 kind(int setter); + + /** + * The properties of this instruction. + */ + public native @Cast("CUpti_ActivityFlag") int flags(); public native CUpti_ActivityPCSampling3 flags(int setter); + + /** + * The ID for source locator. + */ + public native @Cast("uint32_t") int sourceLocatorId(); public native CUpti_ActivityPCSampling3 sourceLocatorId(int setter); + + /** + * The correlation ID of the kernel to which this result is associated. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityPCSampling3 correlationId(int setter); + + /** + * Correlation ID with global/device function name + */ + public native @Cast("uint32_t") int functionId(); public native CUpti_ActivityPCSampling3 functionId(int setter); + + /** + * Number of times the PC was sampled with the stallReason in the record. + * These samples indicate that no instruction was issued in that cycle from + * the warp scheduler from where the warp was sampled. + * Field is valid for devices with compute capability 6.0 and higher + */ + public native @Cast("uint32_t") int latencySamples(); public native CUpti_ActivityPCSampling3 latencySamples(int setter); + + /** + * Number of times the PC was sampled with the stallReason in the record. + * The same PC can be sampled with different stall reasons. The count includes + * latencySamples. + */ + public native @Cast("uint32_t") int samples(); public native CUpti_ActivityPCSampling3 samples(int setter); + + /** + * Current stall reason. Includes one of the reasons from + * \ref CUpti_ActivityPCSamplingStallReason + */ + public native @Cast("CUpti_ActivityPCSamplingStallReason") int stallReason(); public native CUpti_ActivityPCSampling3 stallReason(int setter); + + /** + * The pc offset for the instruction. + */ + public native @Cast("uint64_t") long pcOffset(); public native CUpti_ActivityPCSampling3 pcOffset(long setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityPCSamplingConfig.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityPCSamplingConfig.java new file mode 100644 index 00000000000..859a4ed8c37 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityPCSamplingConfig.java @@ -0,0 +1,65 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief PC sampling configuration structure + * + * This structure defines the pc sampling configuration. + * + * See function \ref cuptiActivityConfigurePCSampling + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityPCSamplingConfig extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityPCSamplingConfig() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityPCSamplingConfig(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityPCSamplingConfig(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityPCSamplingConfig position(long position) { + return (CUpti_ActivityPCSamplingConfig)super.position(position); + } + @Override public CUpti_ActivityPCSamplingConfig getPointer(long i) { + return new CUpti_ActivityPCSamplingConfig((Pointer)this).offsetAddress(i); + } + + /** + * Size of configuration structure. + * CUPTI client should set the size of the structure. It will be used in CUPTI to check what fields are + * available in the structure. Used to preserve backward compatibility. + */ + public native @Cast("uint32_t") int size(); public native CUpti_ActivityPCSamplingConfig size(int setter); + + /** + * There are 5 level provided for sampling period. The level + * internally maps to a period in terms of cycles. Same level can + * map to different number of cycles on different gpus. No of + * cycles will be chosen to minimize information loss. The period + * chosen will be given by samplingPeriodInCycles in + * \ref CUpti_ActivityPCSamplingRecordInfo for each kernel instance. + */ + public native @Cast("CUpti_ActivityPCSamplingPeriod") int samplingPeriod(); public native CUpti_ActivityPCSamplingConfig samplingPeriod(int setter); + + /** + * This will override the period set by samplingPeriod. Value 0 in samplingPeriod2 will be + * considered as samplingPeriod2 should not be used and samplingPeriod should be used. + * Valid values for samplingPeriod2 are between 5 to 31 both inclusive. + * This will set the sampling period to (2^samplingPeriod2) cycles. + */ + public native @Cast("uint32_t") int samplingPeriod2(); public native CUpti_ActivityPCSamplingConfig samplingPeriod2(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityPCSamplingRecordInfo.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityPCSamplingRecordInfo.java new file mode 100644 index 00000000000..4d439a660b5 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityPCSamplingRecordInfo.java @@ -0,0 +1,64 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for record status for PC sampling. + * + * This activity records information obtained by sampling PC + * (CUPTI_ACTIVITY_KIND_PC_SAMPLING_RECORD_INFO). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityPCSamplingRecordInfo extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityPCSamplingRecordInfo() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityPCSamplingRecordInfo(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityPCSamplingRecordInfo(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityPCSamplingRecordInfo position(long position) { + return (CUpti_ActivityPCSamplingRecordInfo)super.position(position); + } + @Override public CUpti_ActivityPCSamplingRecordInfo getPointer(long i) { + return new CUpti_ActivityPCSamplingRecordInfo((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_PC_SAMPLING_RECORD_INFO. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityPCSamplingRecordInfo kind(int setter); + + /** + * The correlation ID of the kernel to which this result is associated. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityPCSamplingRecordInfo correlationId(int setter); + + /** + * Number of times the PC was sampled for this kernel instance including all + * dropped samples. + */ + public native @Cast("uint64_t") long totalSamples(); public native CUpti_ActivityPCSamplingRecordInfo totalSamples(long setter); + + /** + * Number of samples that were dropped by hardware due to backpressure/overflow. + */ + public native @Cast("uint64_t") long droppedSamples(); public native CUpti_ActivityPCSamplingRecordInfo droppedSamples(long setter); + /** + * Sampling period in terms of number of cycles . + */ + public native @Cast("uint64_t") long samplingPeriodInCycles(); public native CUpti_ActivityPCSamplingRecordInfo samplingPeriodInCycles(long setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityPcie.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityPcie.java new file mode 100644 index 00000000000..778abb10543 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityPcie.java @@ -0,0 +1,128 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief PCI devices information required to construct topology + * + * This structure gives capabilities of GPU and PCI bridge connected to the PCIE bus + * which can be used to understand the topology. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityPcie extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityPcie() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityPcie(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityPcie(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityPcie position(long position) { + return (CUpti_ActivityPcie)super.position(position); + } + @Override public CUpti_ActivityPcie getPointer(long i) { + return new CUpti_ActivityPcie((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_PCIE. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityPcie kind(int setter); + + /** + * Type of device in topology, \ref CUpti_PcieDeviceType. If type is + * CUPTI_PCIE_DEVICE_TYPE_GPU use devId for id and gpuAttr and if type is + * CUPTI_PCIE_DEVICE_TYPE_BRIDGE use bridgeId for id and bridgeAttr. + */ + public native @Cast("CUpti_PcieDeviceType") int type(); public native CUpti_ActivityPcie type(int setter); + + /** + * A unique identifier for GPU or Bridge in Topology + */ + /** + * GPU device ID + */ + @Name("id.devId") public native @Cast("CUdevice") int id_devId(); public native CUpti_ActivityPcie id_devId(int setter); + + /** + * A unique identifier for Bridge in the Topology + */ + @Name("id.bridgeId") public native @Cast("uint32_t") int id_bridgeId(); public native CUpti_ActivityPcie id_bridgeId(int setter); + + /** + * Domain for the GPU or Bridge, required to identify which PCIE bus it belongs to in + * multiple NUMA systems. + */ + public native @Cast("uint32_t") int domain(); public native CUpti_ActivityPcie domain(int setter); + + /** + * PCIE Generation of GPU or Bridge. + */ + public native @Cast("uint16_t") short pcieGeneration(); public native CUpti_ActivityPcie pcieGeneration(short setter); + + /** + * Link rate of the GPU or bridge in gigatransfers per second (GT/s) + */ + public native @Cast("uint16_t") short linkRate(); public native CUpti_ActivityPcie linkRate(short setter); + + /** + * Link width of the GPU or bridge + */ + public native @Cast("uint16_t") short linkWidth(); public native CUpti_ActivityPcie linkWidth(short setter); + + /** + * Upstream bus ID for the GPU or PCI bridge. Required to identify which bus it is + * connected to in the topology. + */ + public native @Cast("uint16_t") short upstreamBus(); public native CUpti_ActivityPcie upstreamBus(short setter); + + /** + * Attributes for more information about GPU (gpuAttr) or PCI Bridge (bridgeAttr) + */ + /** + * UUID for the device. \ref CUpti_ActivityDevice5. + */ + @Name("attr.gpuAttr.uuidDev") public native @ByRef CUuuid attr_gpuAttr_uuidDev(); public native CUpti_ActivityPcie attr_gpuAttr_uuidDev(CUuuid setter); + + /** + * CUdevice with which this device has P2P capability. + * This can also be obtained by querying cuDeviceCanAccessPeer or + * cudaDeviceCanAccessPeer APIs + */ + @Name("attr.gpuAttr.peerDev") public native @Cast("CUdevice") int attr_gpuAttr_peerDev(int i); public native CUpti_ActivityPcie attr_gpuAttr_peerDev(int i, int setter); + @Name("attr.gpuAttr.peerDev") @MemberGetter public native @Cast("CUdevice*") IntPointer attr_gpuAttr_peerDev(); + + /** + * The downstream bus number, used to search downstream devices/bridges connected + * to this bridge. + */ + @Name("attr.bridgeAttr.secondaryBus") public native @Cast("uint16_t") short attr_bridgeAttr_secondaryBus(); public native CUpti_ActivityPcie attr_bridgeAttr_secondaryBus(short setter); + + /** + * Device ID of the bridge + */ + @Name("attr.bridgeAttr.deviceId") public native @Cast("uint16_t") short attr_bridgeAttr_deviceId(); public native CUpti_ActivityPcie attr_bridgeAttr_deviceId(short setter); + + /** + * Vendor ID of the bridge + */ + @Name("attr.bridgeAttr.vendorId") public native @Cast("uint16_t") short attr_bridgeAttr_vendorId(); public native CUpti_ActivityPcie attr_bridgeAttr_vendorId(short setter); + + /** + * Padding for alignment + */ + @Name("attr.bridgeAttr.pad0") public native @Cast("uint16_t") short attr_bridgeAttr_pad0(); public native CUpti_ActivityPcie attr_bridgeAttr_pad0(short setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityPreemption.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityPreemption.java new file mode 100644 index 00000000000..aee21c1c1be --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityPreemption.java @@ -0,0 +1,80 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for a preemption of a CDP kernel. + * + * This activity record represents a preemption of a CDP kernel. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityPreemption extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityPreemption() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityPreemption(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityPreemption(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityPreemption position(long position) { + return (CUpti_ActivityPreemption)super.position(position); + } + @Override public CUpti_ActivityPreemption getPointer(long i) { + return new CUpti_ActivityPreemption((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_PREEMPTION + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityPreemption kind(int setter); + + /** + * kind of the preemption + */ + public native @Cast("CUpti_ActivityPreemptionKind") int preemptionKind(); public native CUpti_ActivityPreemption preemptionKind(int setter); + + /** + * The timestamp of the preemption, in ns. A value of 0 indicates + * that timestamp information could not be collected for the + * preemption. + */ + public native @Cast("uint64_t") long timestamp(); public native CUpti_ActivityPreemption timestamp(long setter); + + /** + * The grid-id of the block that is preempted + */ + public native @Cast("int64_t") long gridId(); public native CUpti_ActivityPreemption gridId(long setter); + + /** + * The X-dimension of the block that is preempted + */ + public native @Cast("uint32_t") int blockX(); public native CUpti_ActivityPreemption blockX(int setter); + + /** + * The Y-dimension of the block that is preempted + */ + public native @Cast("uint32_t") int blockY(); public native CUpti_ActivityPreemption blockY(int setter); + + /** + * The Z-dimension of the block that is preempted + */ + public native @Cast("uint32_t") int blockZ(); public native CUpti_ActivityPreemption blockZ(int setter); + + /** + * Undefined. Reserved for internal use. + */ + public native @Cast("uint32_t") int pad(); public native CUpti_ActivityPreemption pad(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivitySharedAccess.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivitySharedAccess.java new file mode 100644 index 00000000000..a40aa89e5eb --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivitySharedAccess.java @@ -0,0 +1,99 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for source-level shared + * access. + * + * This activity records the locations of the shared + * accesses in the source + * (CUPTI_ACTIVITY_KIND_SHARED_ACCESS). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivitySharedAccess extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivitySharedAccess() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivitySharedAccess(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivitySharedAccess(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivitySharedAccess position(long position) { + return (CUpti_ActivitySharedAccess)super.position(position); + } + @Override public CUpti_ActivitySharedAccess getPointer(long i) { + return new CUpti_ActivitySharedAccess((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_SHARED_ACCESS. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivitySharedAccess kind(int setter); + + /** + * The properties of this shared access. + */ + public native @Cast("CUpti_ActivityFlag") int flags(); public native CUpti_ActivitySharedAccess flags(int setter); + + /** + * The ID for source locator. + */ + public native @Cast("uint32_t") int sourceLocatorId(); public native CUpti_ActivitySharedAccess sourceLocatorId(int setter); + + /** + * The correlation ID of the kernel to which this result is associated. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivitySharedAccess correlationId(int setter); + + /** + * Correlation ID with global/device function name + */ + public native @Cast("uint32_t") int functionId(); public native CUpti_ActivitySharedAccess functionId(int setter); + + /** + * The pc offset for the access. + */ + public native @Cast("uint32_t") int pcOffset(); public native CUpti_ActivitySharedAccess pcOffset(int setter); + + /** + * This increments each time when this instruction is executed by number + * of threads that executed this instruction with predicate and condition code evaluating to true. + */ + public native @Cast("uint64_t") long threadsExecuted(); public native CUpti_ActivitySharedAccess threadsExecuted(long setter); + + /** + * The total number of shared memory transactions generated by this access + */ + public native @Cast("uint64_t") long sharedTransactions(); public native CUpti_ActivitySharedAccess sharedTransactions(long setter); + + /** + * The minimum number of shared memory transactions possible based on the access pattern. + */ + public native @Cast("uint64_t") long theoreticalSharedTransactions(); public native CUpti_ActivitySharedAccess theoreticalSharedTransactions(long setter); + + /** + * The number of times this instruction was executed per warp. It will be incremented + * when at least one of thread among warp is active with predicate and condition code + * evaluating to true. + */ + public native @Cast("uint32_t") int executed(); public native CUpti_ActivitySharedAccess executed(int setter); + + /** + * Undefined. Reserved for internal use. + */ + public native @Cast("uint32_t") int pad(); public native CUpti_ActivitySharedAccess pad(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivitySourceLocator.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivitySourceLocator.java new file mode 100644 index 00000000000..065982bc93f --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivitySourceLocator.java @@ -0,0 +1,67 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for source locator. + * + * This activity record represents a source locator + * (CUPTI_ACTIVITY_KIND_SOURCE_LOCATOR). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivitySourceLocator extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivitySourceLocator() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivitySourceLocator(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivitySourceLocator(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivitySourceLocator position(long position) { + return (CUpti_ActivitySourceLocator)super.position(position); + } + @Override public CUpti_ActivitySourceLocator getPointer(long i) { + return new CUpti_ActivitySourceLocator((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_SOURCE_LOCATOR. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivitySourceLocator kind(int setter); + + /** + * The ID for the source path, will be used in all the source level + * results. + */ + public native @Cast("uint32_t") int id(); public native CUpti_ActivitySourceLocator id(int setter); + + /** + * The line number in the source . + */ + public native @Cast("uint32_t") int lineNumber(); public native CUpti_ActivitySourceLocator lineNumber(int setter); + +// #ifdef CUPTILP64 + /** + * Undefined. Reserved for internal use. + */ + public native @Cast("uint32_t") int pad(); public native CUpti_ActivitySourceLocator pad(int setter); +// #endif + + /** + * The path for the file. + */ + public native @Cast("const char*") BytePointer fileName(); public native CUpti_ActivitySourceLocator fileName(BytePointer setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityStream.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityStream.java new file mode 100644 index 00000000000..c92709671bf --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityStream.java @@ -0,0 +1,68 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for CUDA stream. + * + * This activity is used to track created streams. + * (CUPTI_ACTIVITY_KIND_STREAM). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityStream extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityStream() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityStream(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityStream(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityStream position(long position) { + return (CUpti_ActivityStream)super.position(position); + } + @Override public CUpti_ActivityStream getPointer(long i) { + return new CUpti_ActivityStream((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_STREAM. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityStream kind(int setter); + /** + * The ID of the context where the stream was created. + */ + public native @Cast("uint32_t") int contextId(); public native CUpti_ActivityStream contextId(int setter); + + /** + * A unique stream ID to identify the stream. + */ + public native @Cast("uint32_t") int streamId(); public native CUpti_ActivityStream streamId(int setter); + + /** + * The clamped priority for the stream. + */ + public native @Cast("uint32_t") int priority(); public native CUpti_ActivityStream priority(int setter); + + /** + * Flags associated with the stream. + */ + public native @Cast("CUpti_ActivityStreamFlag") int flag(); public native CUpti_ActivityStream flag(int setter); + + /** + * The correlation ID of the API to which this result is associated. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivityStream correlationId(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivitySynchronization.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivitySynchronization.java new file mode 100644 index 00000000000..8a9f594b6f9 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivitySynchronization.java @@ -0,0 +1,89 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for synchronization management. + * + * This activity is used to track various CUDA synchronization APIs. + * (CUPTI_ACTIVITY_KIND_SYNCHRONIZATION). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivitySynchronization extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivitySynchronization() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivitySynchronization(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivitySynchronization(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivitySynchronization position(long position) { + return (CUpti_ActivitySynchronization)super.position(position); + } + @Override public CUpti_ActivitySynchronization getPointer(long i) { + return new CUpti_ActivitySynchronization((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_SYNCHRONIZATION. + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivitySynchronization kind(int setter); + + /** + * The type of record. + */ + public native @Cast("CUpti_ActivitySynchronizationType") int type(); public native CUpti_ActivitySynchronization type(int setter); + + /** + * The start timestamp for the function, in ns. A value of 0 for + * both the start and end timestamps indicates that timestamp + * information could not be collected for the function. + */ + public native @Cast("uint64_t") long start(); public native CUpti_ActivitySynchronization start(long setter); + + /** + * The end timestamp for the function, in ns. A value of 0 for both + * the start and end timestamps indicates that timestamp information + * could not be collected for the function. + */ + public native @Cast("uint64_t") long end(); public native CUpti_ActivitySynchronization end(long setter); + + /** + * The correlation ID of the API to which this result is associated. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_ActivitySynchronization correlationId(int setter); + + /** + * The ID of the context for which the synchronization API is called. + * In case of context synchronization API it is the context id for which the API is called. + * In case of stream/event synchronization it is the ID of the context where the stream/event was created. + */ + public native @Cast("uint32_t") int contextId(); public native CUpti_ActivitySynchronization contextId(int setter); + + /** + * The compute stream for which the synchronization API is called. + * A CUPTI_SYNCHRONIZATION_INVALID_VALUE value indicate the field is not applicable for this record. + * Not valid for cuCtxSynchronize, cuEventSynchronize. + */ + public native @Cast("uint32_t") int streamId(); public native CUpti_ActivitySynchronization streamId(int setter); + + /** + * The event ID for which the synchronization API is called. + * A CUPTI_SYNCHRONIZATION_INVALID_VALUE value indicate the field is not applicable for this record. + * Not valid for cuCtxSynchronize, cuStreamSynchronize. + */ + public native @Cast("uint32_t") int cudaEventId(); public native CUpti_ActivitySynchronization cudaEventId(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityUnifiedMemoryCounter2.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityUnifiedMemoryCounter2.java new file mode 100644 index 00000000000..e5ac8e2d7ef --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityUnifiedMemoryCounter2.java @@ -0,0 +1,151 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief The activity record for Unified Memory counters (CUDA 7.0 and beyond) + * + * This activity record represents a Unified Memory counter + * (CUPTI_ACTIVITY_KIND_UNIFIED_MEMORY_COUNTER). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityUnifiedMemoryCounter2 extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityUnifiedMemoryCounter2() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityUnifiedMemoryCounter2(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityUnifiedMemoryCounter2(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityUnifiedMemoryCounter2 position(long position) { + return (CUpti_ActivityUnifiedMemoryCounter2)super.position(position); + } + @Override public CUpti_ActivityUnifiedMemoryCounter2 getPointer(long i) { + return new CUpti_ActivityUnifiedMemoryCounter2((Pointer)this).offsetAddress(i); + } + + /** + * The activity record kind, must be CUPTI_ACTIVITY_KIND_UNIFIED_MEMORY_COUNTER + */ + public native @Cast("CUpti_ActivityKind") int kind(); public native CUpti_ActivityUnifiedMemoryCounter2 kind(int setter); + + /** + * The Unified Memory counter kind + */ + public native @Cast("CUpti_ActivityUnifiedMemoryCounterKind") int counterKind(); public native CUpti_ActivityUnifiedMemoryCounter2 counterKind(int setter); + + /** + * Value of the counter + * For counterKind CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_BYTES_TRANSFER_HTOD, + * CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_BYTES_TRANSFER_DTOH, + * CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_THREASHING and + * CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_REMOTE_MAP, it is the size of the + * memory region in bytes. + * For counterKind CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_GPU_PAGE_FAULT, it + * is the number of page fault groups for the same page. + * For counterKind CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_CPU_PAGE_FAULT_COUNT, + * it is the program counter for the instruction that caused fault. + */ + public native @Cast("uint64_t") long value(); public native CUpti_ActivityUnifiedMemoryCounter2 value(long setter); + + /** + * The start timestamp of the counter, in ns. + * For counterKind CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_BYTES_TRANSFER_HTOD and + * CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_BYTES_TRANSFER_DTOH, timestamp is + * captured when activity starts on GPU. + * For counterKind CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_GPU_PAGE_FAULT and + * CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_CPU_PAGE_FAULT_COUNT, timestamp is + * captured when CUDA driver started processing the fault. + * For counterKind CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_THRASHING, timestamp + * is captured when CUDA driver detected thrashing of memory region. + * For counterKind CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_THROTTLING, + * timestamp is captured when throttling operation was started by CUDA driver. + * For counterKind CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_REMOTE_MAP, + * timestamp is captured when CUDA driver has pushed all required operations + * to the processor specified by dstId. + */ + public native @Cast("uint64_t") long start(); public native CUpti_ActivityUnifiedMemoryCounter2 start(long setter); + + /** + * The end timestamp of the counter, in ns. + * Ignore this field if counterKind is + * CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_CPU_PAGE_FAULT_COUNT or + * CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_THRASHING or + * CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_REMOTE_MAP. + * For counterKind CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_BYTES_TRANSFER_HTOD and + * CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_BYTES_TRANSFER_DTOH, timestamp is + * captured when activity finishes on GPU. + * For counterKind CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_GPU_PAGE_FAULT, timestamp is + * captured when CUDA driver queues the replay of faulting memory accesses on the GPU + * For counterKind CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_THROTTLING, timestamp + * is captured when throttling operation was finished by CUDA driver + */ + public native @Cast("uint64_t") long end(); public native CUpti_ActivityUnifiedMemoryCounter2 end(long setter); + + /** + * This is the virtual base address of the page/s being transferred. For cpu and + * gpu faults, the virtual address for the page that faulted. + */ + public native @Cast("uint64_t") @Name("address") long _address(); public native CUpti_ActivityUnifiedMemoryCounter2 _address(long setter); + + /** + * The ID of the source CPU/device involved in the memory transfer, page fault, thrashing, + * throttling or remote map operation. For counterKind + * CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_THRASHING, it is a bitwise ORing of the + * device IDs fighting for the memory region. Ignore this field if counterKind is + * CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_CPU_PAGE_FAULT_COUNT + */ + public native @Cast("uint32_t") int srcId(); public native CUpti_ActivityUnifiedMemoryCounter2 srcId(int setter); + + /** + * The ID of the destination CPU/device involved in the memory transfer or remote map + * operation. Ignore this field if counterKind is + * CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_GPU_PAGE_FAULT or + * CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_CPU_PAGE_FAULT_COUNT or + * CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_THRASHING or + * CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_THROTTLING + */ + public native @Cast("uint32_t") int dstId(); public native CUpti_ActivityUnifiedMemoryCounter2 dstId(int setter); + + /** + * The ID of the stream causing the transfer. + * This value of this field is invalid. + */ + public native @Cast("uint32_t") int streamId(); public native CUpti_ActivityUnifiedMemoryCounter2 streamId(int setter); + + /** + * The ID of the process to which this record belongs to. + */ + public native @Cast("uint32_t") int processId(); public native CUpti_ActivityUnifiedMemoryCounter2 processId(int setter); + + /** + * The flags associated with this record. See enums \ref CUpti_ActivityUnifiedMemoryAccessType + * if counterKind is CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_GPU_PAGE_FAULT + * and \ref CUpti_ActivityUnifiedMemoryMigrationCause if counterKind is + * CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_BYTES_TRANSFER_HTOD or + * CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_BYTES_TRANSFER_HTOD + * and \ref CUpti_ActivityUnifiedMemoryRemoteMapCause if counterKind is + * CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_REMOTE_MAP and \ref CUpti_ActivityFlag + * if counterKind is CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_THRASHING or + * CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_THROTTLING + */ + public native @Cast("uint32_t") int flags(); public native CUpti_ActivityUnifiedMemoryCounter2 flags(int setter); + + /** + * Undefined. Reserved for internal use. + */ + public native @Cast("uint32_t") int pad(); public native CUpti_ActivityUnifiedMemoryCounter2 pad(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityUnifiedMemoryCounterConfig.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityUnifiedMemoryCounterConfig.java new file mode 100644 index 00000000000..69a2f21b556 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ActivityUnifiedMemoryCounterConfig.java @@ -0,0 +1,55 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ActivityUnifiedMemoryCounterConfig extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ActivityUnifiedMemoryCounterConfig() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ActivityUnifiedMemoryCounterConfig(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ActivityUnifiedMemoryCounterConfig(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ActivityUnifiedMemoryCounterConfig position(long position) { + return (CUpti_ActivityUnifiedMemoryCounterConfig)super.position(position); + } + @Override public CUpti_ActivityUnifiedMemoryCounterConfig getPointer(long i) { + return new CUpti_ActivityUnifiedMemoryCounterConfig((Pointer)this).offsetAddress(i); + } + + /** + * Unified Memory counter Counter scope. (deprecated in CUDA 7.0) + */ + public native @Cast("CUpti_ActivityUnifiedMemoryCounterScope") int scope(); public native CUpti_ActivityUnifiedMemoryCounterConfig scope(int setter); + + /** + * Unified Memory counter Counter kind + */ + public native @Cast("CUpti_ActivityUnifiedMemoryCounterKind") int kind(); public native CUpti_ActivityUnifiedMemoryCounterConfig kind(int setter); + + /** + * Device id of the target device. This is relevant only + * for single device scopes. (deprecated in CUDA 7.0) + */ + public native @Cast("uint32_t") int deviceId(); public native CUpti_ActivityUnifiedMemoryCounterConfig deviceId(int setter); + + /** + * Control to enable/disable the counter. To enable the counter + * set it to non-zero value while disable is indicated by zero. + */ + public native @Cast("uint32_t") int enable(); public native CUpti_ActivityUnifiedMemoryCounterConfig enable(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_BuffersCallbackCompleteFunc.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_BuffersCallbackCompleteFunc.java new file mode 100644 index 00000000000..7130423182d --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_BuffersCallbackCompleteFunc.java @@ -0,0 +1,56 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief Function type for callback used by CUPTI to return a buffer + * of activity records. + * + * This callback function returns to the CUPTI client a buffer + * containing activity records. The buffer contains \p validSize + * bytes of activity records which should be read using + * cuptiActivityGetNextRecord. The number of dropped records can be + * read using cuptiActivityGetNumDroppedRecords. After this call CUPTI + * relinquished ownership of the buffer and will not use it + * anymore. The client may return the buffer to CUPTI using the + * CUpti_BuffersCallbackRequestFunc callback. + * Note: CUDA 6.0 onwards, all buffers returned by this callback are + * global buffers i.e. there is no context/stream specific buffer. + * User needs to parse the global buffer to extract the context/stream + * specific activity records. + * + * @param context The context this buffer is associated with. If NULL, the + * buffer is associated with the global activities. This field is deprecated + * as of CUDA 6.0 and will always be NULL. + * @param streamId The stream id this buffer is associated with. + * This field is deprecated as of CUDA 6.0 and will always be NULL. + * @param buffer The activity record buffer. + * @param size The total size of the buffer in bytes as set in + * CUpti_BuffersCallbackRequestFunc. + * @param validSize The number of valid bytes in the buffer. + */ +@Convention("CUPTIAPI") @Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_BuffersCallbackCompleteFunc extends FunctionPointer { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_BuffersCallbackCompleteFunc(Pointer p) { super(p); } + protected CUpti_BuffersCallbackCompleteFunc() { allocate(); } + private native void allocate(); + public native void call( + CUctx_st context, + @Cast("uint32_t") int streamId, + @Cast("uint8_t*") BytePointer buffer, + @Cast("size_t") long size, + @Cast("size_t") long validSize); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_BuffersCallbackRequestFunc.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_BuffersCallbackRequestFunc.java new file mode 100644 index 00000000000..7d76045d783 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_BuffersCallbackRequestFunc.java @@ -0,0 +1,45 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief Function type for callback used by CUPTI to request an empty + * buffer for storing activity records. + * + * This callback function signals the CUPTI client that an activity + * buffer is needed by CUPTI. The activity buffer is used by CUPTI to + * store activity records. The callback function can decline the + * request by setting \p *buffer to NULL. In this case CUPTI may drop + * activity records. + * + * @param buffer Returns the new buffer. If set to NULL then no buffer + * is returned. + * @param size Returns the size of the returned buffer. + * @param maxNumRecords Returns the maximum number of records that + * should be placed in the buffer. If 0 then the buffer is filled with + * as many records as possible. If > 0 the buffer is filled with at + * most that many records before it is returned. + */ +@Convention("CUPTIAPI") @Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_BuffersCallbackRequestFunc extends FunctionPointer { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_BuffersCallbackRequestFunc(Pointer p) { super(p); } + protected CUpti_BuffersCallbackRequestFunc() { allocate(); } + private native void allocate(); + public native void call( + @Cast("uint8_t**") PointerPointer buffer, + @Cast("size_t*") SizeTPointer size, + @Cast("size_t*") SizeTPointer maxNumRecords); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_CallbackData.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_CallbackData.java new file mode 100644 index 00000000000..0e79317c8de --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_CallbackData.java @@ -0,0 +1,124 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief Data passed into a runtime or driver API callback function. + * + * Data passed into a runtime or driver API callback function as the + * \p cbdata argument to \ref CUpti_CallbackFunc. The \p cbdata will + * be this type for \p domain equal to CUPTI_CB_DOMAIN_DRIVER_API or + * CUPTI_CB_DOMAIN_RUNTIME_API. The callback data is valid only within + * the invocation of the callback function that is passed the data. If + * you need to retain some data for use outside of the callback, you + * must make a copy of that data. For example, if you make a shallow + * copy of CUpti_CallbackData within a callback, you cannot + * dereference \p functionParams outside of that callback to access + * the function parameters. \p functionName is an exception: the + * string pointed to by \p functionName is a global constant and so + * may be accessed outside of the callback. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_CallbackData extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_CallbackData() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_CallbackData(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_CallbackData(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_CallbackData position(long position) { + return (CUpti_CallbackData)super.position(position); + } + @Override public CUpti_CallbackData getPointer(long i) { + return new CUpti_CallbackData((Pointer)this).offsetAddress(i); + } + + /** + * Point in the runtime or driver function from where the callback + * was issued. + */ + public native @Cast("CUpti_ApiCallbackSite") int callbackSite(); public native CUpti_CallbackData callbackSite(int setter); + + /** + * Name of the runtime or driver API function which issued the + * callback. This string is a global constant and so may be + * accessed outside of the callback. + */ + public native @Cast("const char*") BytePointer functionName(); public native CUpti_CallbackData functionName(BytePointer setter); + + /** + * Pointer to the arguments passed to the runtime or driver API + * call. See generated_cuda_runtime_api_meta.h and + * generated_cuda_meta.h for structure definitions for the + * parameters for each runtime and driver API function. + */ + public native @Const Pointer functionParams(); public native CUpti_CallbackData functionParams(Pointer setter); + + /** + * Pointer to the return value of the runtime or driver API + * call. This field is only valid within the exit::CUPTI_API_EXIT + * callback. For a runtime API \p functionReturnValue points to a + * \p cudaError_t. For a driver API \p functionReturnValue points + * to a \p CUresult. + */ + public native Pointer functionReturnValue(); public native CUpti_CallbackData functionReturnValue(Pointer setter); + + /** + * Name of the symbol operated on by the runtime or driver API + * function which issued the callback. This entry is valid only for + * driver and runtime launch callbacks, where it returns the name of + * the kernel. + */ + public native @Cast("const char*") BytePointer symbolName(); public native CUpti_CallbackData symbolName(BytePointer setter); + + /** + * Driver context current to the thread, or null if no context is + * current. This value can change from the entry to exit callback + * of a runtime API function if the runtime initializes a context. + */ + public native CUctx_st context(); public native CUpti_CallbackData context(CUctx_st setter); + + /** + * Unique ID for the CUDA context associated with the thread. The + * UIDs are assigned sequentially as contexts are created and are + * unique within a process. + */ + public native @Cast("uint32_t") int contextUid(); public native CUpti_CallbackData contextUid(int setter); + + /** + * Pointer to data shared between the entry and exit callbacks of + * a given runtime or drive API function invocation. This field + * can be used to pass 64-bit values from the entry callback to + * the corresponding exit callback. + */ + public native @Cast("uint64_t*") LongPointer correlationData(); public native CUpti_CallbackData correlationData(LongPointer setter); + + /** + * The activity record correlation ID for this callback. For a + * driver domain callback (i.e. \p domain + * CUPTI_CB_DOMAIN_DRIVER_API) this ID will equal the correlation ID + * in the CUpti_ActivityAPI record corresponding to the CUDA driver + * function call. For a runtime domain callback (i.e. \p domain + * CUPTI_CB_DOMAIN_RUNTIME_API) this ID will equal the correlation + * ID in the CUpti_ActivityAPI record corresponding to the CUDA + * runtime function call. Within the callback, this ID can be + * recorded to correlate user data with the activity record. This + * field is new in 4.1. + */ + public native @Cast("uint32_t") int correlationId(); public native CUpti_CallbackData correlationId(int setter); + +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_CallbackFunc.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_CallbackFunc.java new file mode 100644 index 00000000000..ed59d0e8914 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_CallbackFunc.java @@ -0,0 +1,45 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief Function type for a callback. + * + * Function type for a callback. The type of the data passed to the + * callback in \p cbdata depends on the \p domain. If \p domain is + * CUPTI_CB_DOMAIN_DRIVER_API or CUPTI_CB_DOMAIN_RUNTIME_API the type + * of \p cbdata will be CUpti_CallbackData. If \p domain is + * CUPTI_CB_DOMAIN_RESOURCE the type of \p cbdata will be + * CUpti_ResourceData. If \p domain is CUPTI_CB_DOMAIN_SYNCHRONIZE the + * type of \p cbdata will be CUpti_SynchronizeData. If \p domain is + * CUPTI_CB_DOMAIN_NVTX the type of \p cbdata will be CUpti_NvtxData. + * + * @param userdata User data supplied at subscription of the callback + * @param domain The domain of the callback + * @param cbid The ID of the callback + * @param cbdata Data passed to the callback. + */ +@Convention("CUPTIAPI") @Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_CallbackFunc extends FunctionPointer { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_CallbackFunc(Pointer p) { super(p); } + protected CUpti_CallbackFunc() { allocate(); } + private native void allocate(); + public native void call( + Pointer userdata, + @Cast("CUpti_CallbackDomain") int domain, + @Cast("CUpti_CallbackId") int cbid, + @Const Pointer cbdata); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_EventGroup.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_EventGroup.java new file mode 100644 index 00000000000..e1bbacbed15 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_EventGroup.java @@ -0,0 +1,29 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief A group of events. + * + * An event group is a collection of events that are managed + * together. All events in an event group must belong to the same + * domain. + */ +@Namespace @Name("void") @Opaque @Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_EventGroup extends Pointer { + /** Empty constructor. Calls {@code super((Pointer)null)}. */ + public CUpti_EventGroup() { super((Pointer)null); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_EventGroup(Pointer p) { super(p); } +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_EventGroupSet.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_EventGroupSet.java new file mode 100644 index 00000000000..ec051da45df --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_EventGroupSet.java @@ -0,0 +1,52 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + + +/** + * \brief A set of event groups. + * + * A set of event groups. When returned by \ref + * cuptiEventGroupSetsCreate and \ref cuptiMetricCreateEventGroupSets + * a set indicates that event groups that can be enabled at the same + * time (i.e. all the events in the set can be collected + * simultaneously). + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_EventGroupSet extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_EventGroupSet() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_EventGroupSet(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_EventGroupSet(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_EventGroupSet position(long position) { + return (CUpti_EventGroupSet)super.position(position); + } + @Override public CUpti_EventGroupSet getPointer(long i) { + return new CUpti_EventGroupSet((Pointer)this).offsetAddress(i); + } + + /** + * The number of event groups in the set. + */ + public native @Cast("uint32_t") int numEventGroups(); public native CUpti_EventGroupSet numEventGroups(int setter); + /** + * An array of \p numEventGroups event groups. + */ + public native @ByPtrPtr CUpti_EventGroup eventGroups(); public native CUpti_EventGroupSet eventGroups(CUpti_EventGroup setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_EventGroupSets.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_EventGroupSets.java new file mode 100644 index 00000000000..f94b6aca65b --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_EventGroupSets.java @@ -0,0 +1,51 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief A set of event group sets. + * + * A set of event group sets. When returned by \ref + * cuptiEventGroupSetsCreate and \ref cuptiMetricCreateEventGroupSets + * a CUpti_EventGroupSets indicates the number of passes required to + * collect all the events, and the event groups that should be + * collected during each pass. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_EventGroupSets extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_EventGroupSets() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_EventGroupSets(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_EventGroupSets(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_EventGroupSets position(long position) { + return (CUpti_EventGroupSets)super.position(position); + } + @Override public CUpti_EventGroupSets getPointer(long i) { + return new CUpti_EventGroupSets((Pointer)this).offsetAddress(i); + } + + /** + * Number of event group sets. + */ + public native @Cast("uint32_t") int numSets(); public native CUpti_EventGroupSets numSets(int setter); + /** + * An array of \p numSets event group sets. + */ + public native CUpti_EventGroupSet sets(); public native CUpti_EventGroupSets sets(CUpti_EventGroupSet setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_GraphData.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_GraphData.java new file mode 100644 index 00000000000..7ad2b5e5c1f --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_GraphData.java @@ -0,0 +1,74 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief CUDA graphs data passed into a resource callback function. + * + * CUDA graphs data passed into a resource callback function as the \p cbdata + * argument to \ref CUpti_CallbackFunc. The \p cbdata will be this + * type for \p domain equal to CUPTI_CB_DOMAIN_RESOURCE. The graph + * data is valid only within the invocation of the callback function + * that is passed the data. If you need to retain some data for use + * outside of the callback, you must make a copy of that data. + */ + +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_GraphData extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_GraphData() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_GraphData(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_GraphData(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_GraphData position(long position) { + return (CUpti_GraphData)super.position(position); + } + @Override public CUpti_GraphData getPointer(long i) { + return new CUpti_GraphData((Pointer)this).offsetAddress(i); + } + + /** + * CUDA graph + */ + public native CUgraph_st graph(); public native CUpti_GraphData graph(CUgraph_st setter); + /** + * The original CUDA graph from which @param graph is cloned + */ + public native CUgraph_st originalGraph(); public native CUpti_GraphData originalGraph(CUgraph_st setter); + /** + * CUDA graph node + */ + public native CUgraphNode_st node(); public native CUpti_GraphData node(CUgraphNode_st setter); + /** + * The original CUDA graph node from which @param node is cloned + */ + public native CUgraphNode_st originalNode(); public native CUpti_GraphData originalNode(CUgraphNode_st setter); + /** + * Type of the @param node + */ + public native @Cast("CUgraphNodeType") int nodeType(); public native CUpti_GraphData nodeType(int setter); + /** + * The dependent graph node + * The size of the array is @param numDependencies. + */ + public native CUgraphNode_st dependency(); public native CUpti_GraphData dependency(CUgraphNode_st setter); + /** + * CUDA executable graph + */ + public native CUgraphExec_st graphExec(); public native CUpti_GraphData graphExec(CUgraphExec_st setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_KernelReplayUpdateFunc.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_KernelReplayUpdateFunc.java new file mode 100644 index 00000000000..2c5fcdfef46 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_KernelReplayUpdateFunc.java @@ -0,0 +1,34 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief Function type for getting updates on kernel replay. + * + * @param kernelName The mangled kernel name + * @param numReplaysDone Number of replays done so far + * @param customData Pointer of any custom data passed in when subscribing + */ +@Convention("CUPTIAPI") @Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_KernelReplayUpdateFunc extends FunctionPointer { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_KernelReplayUpdateFunc(Pointer p) { super(p); } + protected CUpti_KernelReplayUpdateFunc() { allocate(); } + private native void allocate(); + public native void call( + @Cast("const char*") BytePointer kernelName, + int numReplaysDone, + Pointer customData); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_MetricValue.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_MetricValue.java new file mode 100644 index 00000000000..d52d73b7acd --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_MetricValue.java @@ -0,0 +1,68 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief A metric value. + * + * Metric values can be one of several different kinds. Corresponding + * to each kind is a member of the CUpti_MetricValue union. The metric + * value returned by \ref cuptiMetricGetValue should be accessed using + * the appropriate member of that union based on its value kind. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_MetricValue extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_MetricValue() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_MetricValue(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_MetricValue(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_MetricValue position(long position) { + return (CUpti_MetricValue)super.position(position); + } + @Override public CUpti_MetricValue getPointer(long i) { + return new CUpti_MetricValue((Pointer)this).offsetAddress(i); + } + + /* + * Value for CUPTI_METRIC_VALUE_KIND_DOUBLE. + */ + public native double metricValueDouble(); public native CUpti_MetricValue metricValueDouble(double setter); + /* + * Value for CUPTI_METRIC_VALUE_KIND_UINT64. + */ + public native @Cast("uint64_t") long metricValueUint64(); public native CUpti_MetricValue metricValueUint64(long setter); + /* + * Value for CUPTI_METRIC_VALUE_KIND_INT64. + */ + public native @Cast("int64_t") long metricValueInt64(); public native CUpti_MetricValue metricValueInt64(long setter); + /* + * Value for CUPTI_METRIC_VALUE_KIND_PERCENT. For example, 57.5% is + * represented by the value 57.5. + */ + public native double metricValuePercent(); public native CUpti_MetricValue metricValuePercent(double setter); + /* + * Value for CUPTI_METRIC_VALUE_KIND_THROUGHPUT. The unit for + * throughput values is bytes/second. + */ + public native @Cast("uint64_t") long metricValueThroughput(); public native CUpti_MetricValue metricValueThroughput(long setter); + /* + * Value for CUPTI_METRIC_VALUE_KIND_UTILIZATION_LEVEL. + */ + public native @Cast("CUpti_MetricValueUtilizationLevel") int metricValueUtilizationLevel(); public native CUpti_MetricValue metricValueUtilizationLevel(int setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ModuleResourceData.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ModuleResourceData.java new file mode 100644 index 00000000000..c77ab172fe2 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ModuleResourceData.java @@ -0,0 +1,60 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + + +/** + * \brief Module data passed into a resource callback function. + * + * CUDA module data passed into a resource callback function as the \p cbdata + * argument to \ref CUpti_CallbackFunc. The \p cbdata will be this + * type for \p domain equal to CUPTI_CB_DOMAIN_RESOURCE. The module + * data is valid only within the invocation of the callback function + * that is passed the data. If you need to retain some data for use + * outside of the callback, you must make a copy of that data. + */ + +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ModuleResourceData extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ModuleResourceData() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ModuleResourceData(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ModuleResourceData(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ModuleResourceData position(long position) { + return (CUpti_ModuleResourceData)super.position(position); + } + @Override public CUpti_ModuleResourceData getPointer(long i) { + return new CUpti_ModuleResourceData((Pointer)this).offsetAddress(i); + } + + /** + * Identifier to associate with the CUDA module. + */ + public native @Cast("uint32_t") int moduleId(); public native CUpti_ModuleResourceData moduleId(int setter); + + /** + * The size of the cubin. + */ + public native @Cast("size_t") long cubinSize(); public native CUpti_ModuleResourceData cubinSize(long setter); + + /** + * Pointer to the associated cubin. + */ + public native @Cast("const char*") BytePointer pCubin(); public native CUpti_ModuleResourceData pCubin(BytePointer setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_NvtxData.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_NvtxData.java new file mode 100644 index 00000000000..c0169723539 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_NvtxData.java @@ -0,0 +1,63 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief Data passed into a NVTX callback function. + * + * Data passed into a NVTX callback function as the \p cbdata argument + * to \ref CUpti_CallbackFunc. The \p cbdata will be this type for \p + * domain equal to CUPTI_CB_DOMAIN_NVTX. Unless otherwise notes, the + * callback data is valid only within the invocation of the callback + * function that is passed the data. If you need to retain some data + * for use outside of the callback, you must make a copy of that data. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_NvtxData extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_NvtxData() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_NvtxData(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_NvtxData(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_NvtxData position(long position) { + return (CUpti_NvtxData)super.position(position); + } + @Override public CUpti_NvtxData getPointer(long i) { + return new CUpti_NvtxData((Pointer)this).offsetAddress(i); + } + + /** + * Name of the NVTX API function which issued the callback. This + * string is a global constant and so may be accessed outside of the + * callback. + */ + public native @Cast("const char*") BytePointer functionName(); public native CUpti_NvtxData functionName(BytePointer setter); + + /** + * Pointer to the arguments passed to the NVTX API call. See + * generated_nvtx_meta.h for structure definitions for the + * parameters for each NVTX API function. + */ + public native @Const Pointer functionParams(); public native CUpti_NvtxData functionParams(Pointer setter); + + /** + * Pointer to the return value of the NVTX API call. See + * nvToolsExt.h for each NVTX API function's return value. + */ + public native @Const Pointer functionReturnValue(); public native CUpti_NvtxData functionReturnValue(Pointer setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ResourceData.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ResourceData.java new file mode 100644 index 00000000000..e3530855a6f --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_ResourceData.java @@ -0,0 +1,64 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief Data passed into a resource callback function. + * + * Data passed into a resource callback function as the \p cbdata + * argument to \ref CUpti_CallbackFunc. The \p cbdata will be this + * type for \p domain equal to CUPTI_CB_DOMAIN_RESOURCE. The callback + * data is valid only within the invocation of the callback function + * that is passed the data. If you need to retain some data for use + * outside of the callback, you must make a copy of that data. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_ResourceData extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_ResourceData() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_ResourceData(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_ResourceData(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_ResourceData position(long position) { + return (CUpti_ResourceData)super.position(position); + } + @Override public CUpti_ResourceData getPointer(long i) { + return new CUpti_ResourceData((Pointer)this).offsetAddress(i); + } + + /** + * For CUPTI_CBID_RESOURCE_CONTEXT_CREATED and + * CUPTI_CBID_RESOURCE_CONTEXT_DESTROY_STARTING, the context being + * created or destroyed. For CUPTI_CBID_RESOURCE_STREAM_CREATED and + * CUPTI_CBID_RESOURCE_STREAM_DESTROY_STARTING, the context + * containing the stream being created or destroyed. + */ + public native CUctx_st context(); public native CUpti_ResourceData context(CUctx_st setter); + + /** + * For CUPTI_CBID_RESOURCE_STREAM_CREATED and + * CUPTI_CBID_RESOURCE_STREAM_DESTROY_STARTING, the stream being + * created or destroyed. + */ + @Name("resourceHandle.stream") public native CUstream_st resourceHandle_stream(); public native CUpti_ResourceData resourceHandle_stream(CUstream_st setter); + + /** + * Reserved for future use. + */ + public native Pointer resourceDescriptor(); public native CUpti_ResourceData resourceDescriptor(Pointer setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_StateData.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_StateData.java new file mode 100644 index 00000000000..f12f81e8535 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_StateData.java @@ -0,0 +1,56 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief Data passed into a State callback function. + * + * Data passed into a State callback function as the \p cbdata argument + * to \ref CUpti_CallbackFunc. The \p cbdata will be this type for \p + * domain equal to CUPTI_CB_DOMAIN_STATE and callback Ids belonging to CUpti_CallbackIdState. + * Unless otherwise noted, the callback data is valid only within the invocation of the callback + * function that is passed the data. If you need to retain some data + * for use outside of the callback, you must make a copy of that data. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_StateData extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_StateData() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_StateData(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_StateData(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_StateData position(long position) { + return (CUpti_StateData)super.position(position); + } + @Override public CUpti_StateData getPointer(long i) { + return new CUpti_StateData((Pointer)this).offsetAddress(i); + } + + /** + * Data passed along with the callback Ids + * Enum CUpti_CallbackIdState used to denote callback ids + */ + /** + * Error code + */ + @Name("notification.result") public native @Cast("CUptiResult") int notification_result(); public native CUpti_StateData notification_result(int setter); + /** + * String containing more details. It can be NULL. + */ + @Name("notification.message") public native @Cast("const char*") BytePointer notification_message(); public native CUpti_StateData notification_message(BytePointer setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_StreamAttrData.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_StreamAttrData.java new file mode 100644 index 00000000000..5a569d8cce1 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_StreamAttrData.java @@ -0,0 +1,59 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief Stream attribute data passed into a resource callback function + * for CUPTI_CBID_RESOURCE_STREAM_ATTRIBUTE_CHANGED callback +

+ * Data passed into a resource callback function as the \p cbdata + * argument to \ref CUpti_CallbackFunc. The \p cbdata will be this + * type for \p domain equal to CUPTI_CB_DOMAIN_RESOURCE. The + * stream attribute data is valid only within the invocation of the callback + * function that is passed the data. If you need to retain some data + * for use outside of the callback, you must make a copy of that data. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_StreamAttrData extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_StreamAttrData() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_StreamAttrData(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_StreamAttrData(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_StreamAttrData position(long position) { + return (CUpti_StreamAttrData)super.position(position); + } + @Override public CUpti_StreamAttrData getPointer(long i) { + return new CUpti_StreamAttrData((Pointer)this).offsetAddress(i); + } + + /** + * The CUDA stream handle for the attribute + */ + public native CUstream_st stream(); public native CUpti_StreamAttrData stream(CUstream_st setter); + + /** + * The type of the CUDA stream attribute + */ + public native @Cast("CUstreamAttrID") int attr(); public native CUpti_StreamAttrData attr(int setter); + + /** + * The value of the CUDA stream attribute + */ + public native @Cast("const CUstreamAttrValue*") CUlaunchAttributeValue value(); public native CUpti_StreamAttrData value(CUlaunchAttributeValue setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_Subscriber_st.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_Subscriber_st.java new file mode 100644 index 00000000000..71ac9882cfb --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_Subscriber_st.java @@ -0,0 +1,25 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief A callback subscriber. + */ +@Opaque @Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_Subscriber_st extends Pointer { + /** Empty constructor. Calls {@code super((Pointer)null)}. */ + public CUpti_Subscriber_st() { super((Pointer)null); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_Subscriber_st(Pointer p) { super(p); } +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_SynchronizeData.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_SynchronizeData.java new file mode 100644 index 00000000000..d84423d1487 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_SynchronizeData.java @@ -0,0 +1,52 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief Data passed into a synchronize callback function. + * + * Data passed into a synchronize callback function as the \p cbdata + * argument to \ref CUpti_CallbackFunc. The \p cbdata will be this + * type for \p domain equal to CUPTI_CB_DOMAIN_SYNCHRONIZE. The + * callback data is valid only within the invocation of the callback + * function that is passed the data. If you need to retain some data + * for use outside of the callback, you must make a copy of that data. + */ +@Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_SynchronizeData extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public CUpti_SynchronizeData() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public CUpti_SynchronizeData(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_SynchronizeData(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public CUpti_SynchronizeData position(long position) { + return (CUpti_SynchronizeData)super.position(position); + } + @Override public CUpti_SynchronizeData getPointer(long i) { + return new CUpti_SynchronizeData((Pointer)this).offsetAddress(i); + } + + /** + * The context of the stream being synchronized. + */ + public native CUctx_st context(); public native CUpti_SynchronizeData context(CUctx_st setter); + /** + * The stream being synchronized. + */ + public native CUstream_st stream(); public native CUpti_SynchronizeData stream(CUstream_st setter); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_TimestampCallbackFunc.java b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_TimestampCallbackFunc.java new file mode 100644 index 00000000000..005560afd89 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/cupti/CUpti_TimestampCallbackFunc.java @@ -0,0 +1,36 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.cupti; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +import static org.bytedeco.cuda.global.cupti.*; + + +/** + * \brief Function type for callback used by CUPTI to request a timestamp + * to be used in activity records. + * + * This callback function signals the CUPTI client that a timestamp needs + * to be returned. This timestamp would be treated as normalized timestamp + * to be used for various purposes in CUPTI. For example to store start and + * end timestamps reported in the CUPTI activity records. + * The returned timestamp must be in nanoseconds. + * + * @see ::cuptiActivityRegisterTimestampCallback + */ +@Convention("CUPTIAPI") @Properties(inherit = org.bytedeco.cuda.presets.cupti.class) +public class CUpti_TimestampCallbackFunc extends FunctionPointer { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public CUpti_TimestampCallbackFunc(Pointer p) { super(p); } + protected CUpti_TimestampCallbackFunc() { allocate(); } + private native void allocate(); + public native @Cast("uint64_t") long call(); +} diff --git a/cuda/src/gen/java/org/bytedeco/cuda/global/cupti.java b/cuda/src/gen/java/org/bytedeco/cuda/global/cupti.java new file mode 100644 index 00000000000..5e744d43514 --- /dev/null +++ b/cuda/src/gen/java/org/bytedeco/cuda/global/cupti.java @@ -0,0 +1,8245 @@ +// Targeted by JavaCPP version 1.5.11-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.cuda.global; + +import org.bytedeco.cuda.cupti.*; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import org.bytedeco.cuda.cudart.*; +import static org.bytedeco.cuda.global.cudart.*; + +public class cupti extends org.bytedeco.cuda.presets.cupti { + static { Loader.load(); } + +// Parsed from cupti_result.h + +/* + * Copyright 2010-2021 NVIDIA Corporation. All rights reserved. + * + * NOTICE TO LICENSEE: + * + * This source code and/or documentation ("Licensed Deliverables") are + * subject to NVIDIA intellectual property rights under U.S. and + * international Copyright laws. + * + * These Licensed Deliverables contained herein is PROPRIETARY and + * CONFIDENTIAL to NVIDIA and is being provided under the terms and + * conditions of a form of NVIDIA software license agreement by and + * between NVIDIA and Licensee ("License Agreement") or electronically + * accepted by Licensee. Notwithstanding any terms or conditions to + * the contrary in the License Agreement, reproduction or disclosure + * of the Licensed Deliverables to any third party without the express + * written consent of NVIDIA is prohibited. + * + * NOTWITHSTANDING ANY TERMS OR CONDITIONS TO THE CONTRARY IN THE + * LICENSE AGREEMENT, NVIDIA MAKES NO REPRESENTATION ABOUT THE + * SUITABILITY OF THESE LICENSED DELIVERABLES FOR ANY PURPOSE. IT IS + * PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY OF ANY KIND. + * NVIDIA DISCLAIMS ALL WARRANTIES WITH REGARD TO THESE LICENSED + * DELIVERABLES, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY, + * NONINFRINGEMENT, AND FITNESS FOR A PARTICULAR PURPOSE. + * NOTWITHSTANDING ANY TERMS OR CONDITIONS TO THE CONTRARY IN THE + * LICENSE AGREEMENT, IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY + * SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, OR ANY + * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, + * WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS + * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE + * OF THESE LICENSED DELIVERABLES. + * + * U.S. Government End Users. These Licensed Deliverables are a + * "commercial item" as that term is defined at 48 C.F.R. 2.101 (OCT + * 1995), consisting of "commercial computer software" and "commercial + * computer software documentation" as such terms are used in 48 + * C.F.R. 12.212 (SEPT 1995) and is provided to the U.S. Government + * only as a commercial end item. Consistent with 48 C.F.R.12.212 and + * 48 C.F.R. 227.7202-1 through 227.7202-4 (JUNE 1995), all + * U.S. Government End Users acquire the Licensed Deliverables with + * only those rights set forth herein. + * + * Any use of the Licensed Deliverables in individual and commercial + * software must include, in the user documentation and internal + * comments to the code, the above Disclaimer and U.S. Government End + * Users Notice. + */ + +// #if !defined(_CUPTI_RESULT_H_) +// #define _CUPTI_RESULT_H_ + +// #ifndef CUPTIAPI +// #ifdef _WIN32 +// #define CUPTIAPI __stdcall +// #else +// #define CUPTIAPI +// #endif +// #endif + +// #if defined(__cplusplus) +// #endif + +// #if defined(__GNUC__) && defined(CUPTI_LIB) +// #pragma GCC visibility push(default) +// #endif + +/** + * \defgroup CUPTI_RESULT_API CUPTI Result Codes + * Error and result codes returned by CUPTI functions. + * \{ + */ + +/** + * \brief CUPTI result codes. + * + * Error and result codes returned by CUPTI functions. + */ +/** enum CUptiResult */ +public static final int + /** + * No error. + */ + CUPTI_SUCCESS = 0, + /** + * One or more of the parameters is invalid. + */ + CUPTI_ERROR_INVALID_PARAMETER = 1, + /** + * The device does not correspond to a valid CUDA device. + */ + CUPTI_ERROR_INVALID_DEVICE = 2, + /** + * The context is NULL or not valid. + */ + CUPTI_ERROR_INVALID_CONTEXT = 3, + /** + * The event domain id is invalid. + */ + CUPTI_ERROR_INVALID_EVENT_DOMAIN_ID = 4, + /** + * The event id is invalid. + */ + CUPTI_ERROR_INVALID_EVENT_ID = 5, + /** + * The event name is invalid. + */ + CUPTI_ERROR_INVALID_EVENT_NAME = 6, + /** + * The current operation cannot be performed due to dependency on + * other factors. + */ + CUPTI_ERROR_INVALID_OPERATION = 7, + /** + * Unable to allocate enough memory to perform the requested + * operation. + */ + CUPTI_ERROR_OUT_OF_MEMORY = 8, + /** + * An error occurred on the performance monitoring hardware. + */ + CUPTI_ERROR_HARDWARE = 9, + /** + * The output buffer size is not sufficient to return all + * requested data. + */ + CUPTI_ERROR_PARAMETER_SIZE_NOT_SUFFICIENT = 10, + /** + * API is not implemented. + */ + CUPTI_ERROR_API_NOT_IMPLEMENTED = 11, + /** + * The maximum limit is reached. + */ + CUPTI_ERROR_MAX_LIMIT_REACHED = 12, + /** + * The object is not yet ready to perform the requested operation. + */ + CUPTI_ERROR_NOT_READY = 13, + /** + * The current operation is not compatible with the current state + * of the object + */ + CUPTI_ERROR_NOT_COMPATIBLE = 14, + /** + * CUPTI is unable to initialize its connection to the CUDA + * driver. + */ + CUPTI_ERROR_NOT_INITIALIZED = 15, + /** + * The metric id is invalid. + */ + CUPTI_ERROR_INVALID_METRIC_ID = 16, + /** + * The metric name is invalid. + */ + CUPTI_ERROR_INVALID_METRIC_NAME = 17, + /** + * The queue is empty. + */ + CUPTI_ERROR_QUEUE_EMPTY = 18, + /** + * Invalid handle (internal?). + */ + CUPTI_ERROR_INVALID_HANDLE = 19, + /** + * Invalid stream. + */ + CUPTI_ERROR_INVALID_STREAM = 20, + /** + * Invalid kind. + */ + CUPTI_ERROR_INVALID_KIND = 21, + /** + * Invalid event value. + */ + CUPTI_ERROR_INVALID_EVENT_VALUE = 22, + /** + * CUPTI is disabled due to conflicts with other enabled profilers + */ + CUPTI_ERROR_DISABLED = 23, + /** + * Invalid module. + */ + CUPTI_ERROR_INVALID_MODULE = 24, + /** + * Invalid metric value. + */ + CUPTI_ERROR_INVALID_METRIC_VALUE = 25, + /** + * The performance monitoring hardware is in use by other client. + */ + CUPTI_ERROR_HARDWARE_BUSY = 26, + /** + * The attempted operation is not supported on the current + * system or device. + */ + CUPTI_ERROR_NOT_SUPPORTED = 27, + /** + * Unified memory profiling is not supported on the system. + * Potential reason could be unsupported OS or architecture. + */ + CUPTI_ERROR_UM_PROFILING_NOT_SUPPORTED = 28, + /** + * Unified memory profiling is not supported on the device + */ + CUPTI_ERROR_UM_PROFILING_NOT_SUPPORTED_ON_DEVICE = 29, + /** + * Unified memory profiling is not supported on a multi-GPU + * configuration without P2P support between any pair of devices + */ + CUPTI_ERROR_UM_PROFILING_NOT_SUPPORTED_ON_NON_P2P_DEVICES = 30, + /** + * Unified memory profiling is not supported under the + * Multi-Process Service (MPS) environment. CUDA 7.5 removes this + * restriction. + */ + CUPTI_ERROR_UM_PROFILING_NOT_SUPPORTED_WITH_MPS = 31, + /** + * In CUDA 9.0, devices with compute capability 7.0 don't + * support CDP tracing + */ + CUPTI_ERROR_CDP_TRACING_NOT_SUPPORTED = 32, + /** + * Profiling on virtualized GPU is not supported. + */ + CUPTI_ERROR_VIRTUALIZED_DEVICE_NOT_SUPPORTED = 33, + /** + * Profiling results might be incorrect for CUDA applications + * compiled with nvcc version older than 9.0 for devices with + * compute capability 6.0 and 6.1. + * Profiling session will continue and CUPTI will notify it using this error code. + * User is advised to recompile the application code with nvcc version 9.0 or later. + * Ignore this warning if code is already compiled with the recommended nvcc version. + */ + CUPTI_ERROR_CUDA_COMPILER_NOT_COMPATIBLE = 34, + /** + * User doesn't have sufficient privileges which are required to + * start the profiling session. + * One possible reason for this may be that the NVIDIA driver or your system + * administrator may have restricted access to the NVIDIA GPU performance counters. + * To learn how to resolve this issue and find more information, please visit + * https://developer.nvidia.com/CUPTI_ERROR_INSUFFICIENT_PRIVILEGES + */ + CUPTI_ERROR_INSUFFICIENT_PRIVILEGES = 35, + /** + * Legacy CUPTI Profiling API i.e. event API from the header cupti_events.h and + * metric API from the header cupti_metrics.h are not compatible with the + * Profiling API in the header cupti_profiler_target.h and Perfworks metrics API + * in the headers nvperf_host.h and nvperf_target.h. + */ + CUPTI_ERROR_OLD_PROFILER_API_INITIALIZED = 36, + /** + * Missing definition of the OpenACC API routine in the linked OpenACC library. + * + * One possible reason is that OpenACC library is linked statically in the + * user application, which might not have the definition of all the OpenACC + * API routines needed for the OpenACC profiling, as compiler might ignore + * definitions for the functions not used in the application. This issue + * can be mitigated by linking the OpenACC library dynamically. + */ + CUPTI_ERROR_OPENACC_UNDEFINED_ROUTINE = 37, + /** + * Legacy CUPTI Profiling API i.e. event API from the header cupti_events.h and + * metric API from the header cupti_metrics.h are not supported on devices with + * compute capability 7.5 and higher (i.e. Turing and later GPU architectures). + * These API will be deprecated in a future CUDA release. These are replaced by + * Profiling API in the header cupti_profiler_target.h and Perfworks metrics API + * in the headers nvperf_host.h and nvperf_target.h. + */ + CUPTI_ERROR_LEGACY_PROFILER_NOT_SUPPORTED = 38, + /** + * CUPTI doesn't allow multiple callback subscribers. Only a single subscriber + * can be registered at a time. + * Same error code is used when application is launched using NVIDIA tools + * like nvprof, Visual Profiler, Nsight Systems, Nsight Compute, cuda-gdb and + * cuda-memcheck. + */ + CUPTI_ERROR_MULTIPLE_SUBSCRIBERS_NOT_SUPPORTED = 39, + /** + * Profiling on virtualized GPU is not allowed by hypervisor. + */ + CUPTI_ERROR_VIRTUALIZED_DEVICE_INSUFFICIENT_PRIVILEGES = 40, + /** + * Profiling and tracing are not allowed when confidential computing mode + * is enabled. + */ + CUPTI_ERROR_CONFIDENTIAL_COMPUTING_NOT_SUPPORTED = 41, + /** + * CUPTI does not support NVIDIA Crypto Mining Processors (CMP). + * For more information, please visit https://developer.nvidia.com/ERR_NVCMPGPU + */ + CUPTI_ERROR_CMP_DEVICE_NOT_SUPPORTED = 42, + /** + * An unknown internal error has occurred. + */ + CUPTI_ERROR_UNKNOWN = 999, + CUPTI_ERROR_FORCE_INT = 0x7fffffff; + +/** + * \brief Get the descriptive string for a CUptiResult. + * + * Return the descriptive string for a CUptiResult in \p *str. + * \note \b Thread-safety: this function is thread safe. + * + * @param result The result to get the string for + * @param str Returns the string + * + * \retval CUPTI_SUCCESS on success + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p str is NULL or \p + * result is not a valid CUptiResult + */ +public static native @Cast("CUptiResult") int cuptiGetResultString(@Cast("CUptiResult") int result, @Cast("const char**") PointerPointer str); +public static native @Cast("CUptiResult") int cuptiGetResultString(@Cast("CUptiResult") int result, @Cast("const char**") @ByPtrPtr BytePointer str); +public static native @Cast("CUptiResult") int cuptiGetResultString(@Cast("CUptiResult") int result, @Cast("const char**") @ByPtrPtr ByteBuffer str); +public static native @Cast("CUptiResult") int cuptiGetResultString(@Cast("CUptiResult") int result, @Cast("const char**") @ByPtrPtr byte[] str); + +/** + * \brief Get the descriptive message corresponding to error codes returned + * by CUPTI. + * + * Return the descriptive error message for a CUptiResult in \p *str. + * \note \b Thread-safety: this function is thread safe. + * + * @param result The result to get the descriptive error message for + * @param str Returns the error message string + * + * \retval CUPTI_SUCCESS on success + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p str is NULL or \p + * result is not a valid CUptiResult + * + */ + +public static native @Cast("CUptiResult") int cuptiGetErrorMessage(@Cast("CUptiResult") int result, @Cast("const char**") PointerPointer str); +public static native @Cast("CUptiResult") int cuptiGetErrorMessage(@Cast("CUptiResult") int result, @Cast("const char**") @ByPtrPtr BytePointer str); +public static native @Cast("CUptiResult") int cuptiGetErrorMessage(@Cast("CUptiResult") int result, @Cast("const char**") @ByPtrPtr ByteBuffer str); +public static native @Cast("CUptiResult") int cuptiGetErrorMessage(@Cast("CUptiResult") int result, @Cast("const char**") @ByPtrPtr byte[] str); + +/** \} */ /* END CUPTI_RESULT_API */ + +// #if defined(__GNUC__) && defined(CUPTI_LIB) +// #pragma GCC visibility pop +// #endif + +// #if defined(__cplusplus) +// #endif + +// #endif /*_CUPTI_RESULT_H_*/ + + + + +// Parsed from cupti_version.h + +/* + * Copyright 2010-2024 NVIDIA Corporation. All rights reserved. + * + * NOTICE TO LICENSEE: + * + * This source code and/or documentation ("Licensed Deliverables") are + * subject to NVIDIA intellectual property rights under U.S. and + * international Copyright laws. + * + * These Licensed Deliverables contained herein is PROPRIETARY and + * CONFIDENTIAL to NVIDIA and is being provided under the terms and + * conditions of a form of NVIDIA software license agreement by and + * between NVIDIA and Licensee ("License Agreement") or electronically + * accepted by Licensee. Notwithstanding any terms or conditions to + * the contrary in the License Agreement, reproduction or disclosure + * of the Licensed Deliverables to any third party without the express + * written consent of NVIDIA is prohibited. + * + * NOTWITHSTANDING ANY TERMS OR CONDITIONS TO THE CONTRARY IN THE + * LICENSE AGREEMENT, NVIDIA MAKES NO REPRESENTATION ABOUT THE + * SUITABILITY OF THESE LICENSED DELIVERABLES FOR ANY PURPOSE. IT IS + * PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY OF ANY KIND. + * NVIDIA DISCLAIMS ALL WARRANTIES WITH REGARD TO THESE LICENSED + * DELIVERABLES, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY, + * NONINFRINGEMENT, AND FITNESS FOR A PARTICULAR PURPOSE. + * NOTWITHSTANDING ANY TERMS OR CONDITIONS TO THE CONTRARY IN THE + * LICENSE AGREEMENT, IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY + * SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, OR ANY + * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, + * WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS + * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE + * OF THESE LICENSED DELIVERABLES. + * + * U.S. Government End Users. These Licensed Deliverables are a + * "commercial item" as that term is defined at 48 C.F.R. 2.101 (OCT + * 1995), consisting of "commercial computer software" and "commercial + * computer software documentation" as such terms are used in 48 + * C.F.R. 12.212 (SEPT 1995) and is provided to the U.S. Government + * only as a commercial end item. Consistent with 48 C.F.R.12.212 and + * 48 C.F.R. 227.7202-1 through 227.7202-4 (JUNE 1995), all + * U.S. Government End Users acquire the Licensed Deliverables with + * only those rights set forth herein. + * + * Any use of the Licensed Deliverables in individual and commercial + * software must include, in the user documentation and internal + * comments to the code, the above Disclaimer and U.S. Government End + * Users Notice. + */ + +// #if !defined(_CUPTI_VERSION_H_) +// #define _CUPTI_VERSION_H_ + +// #include +// #include + +// #ifndef CUPTIAPI +// #ifdef _WIN32 +// #define CUPTIAPI __stdcall +// #else +// #define CUPTIAPI +// #endif +// #endif + +// #if defined(__cplusplus) +// #endif + +// #if defined(__GNUC__) && defined(CUPTI_LIB) +// #pragma GCC visibility push(default) +// #endif + +/** + * \defgroup CUPTI_VERSION_API CUPTI Version + * Function and macro to determine the CUPTI version. + * \{ + */ + +/** + * \brief The API version for this implementation of CUPTI. + * + * The API version for this implementation of CUPTI. This define along + * with \ref cuptiGetVersion can be used to dynamically detect if the + * version of CUPTI compiled against matches the version of the loaded + * CUPTI library. + * + * v1 : CUDAToolsSDK 4.0 + * v2 : CUDAToolsSDK 4.1 + * v3 : CUDA Toolkit 5.0 + * v4 : CUDA Toolkit 5.5 + * v5 : CUDA Toolkit 6.0 + * v6 : CUDA Toolkit 6.5 + * v7 : CUDA Toolkit 6.5(with sm_52 support) + * v8 : CUDA Toolkit 7.0 + * v9 : CUDA Toolkit 8.0 + * v10 : CUDA Toolkit 9.0 + * v11 : CUDA Toolkit 9.1 + * v12 : CUDA Toolkit 10.0, 10.1 and 10.2 + * v13 : CUDA Toolkit 11.0 + * v14 : CUDA Toolkit 11.1 + * v15 : CUDA Toolkit 11.2, 11.3 and 11.4 + * v16 : CUDA Toolkit 11.5 + * v17 : CUDA Toolkit 11.6 + * v18 : CUDA Toolkit 11.8 + * v19 : CUDA Toolkit 12.0 + * v20 : CUDA Toolkit 12.2 + * v21 : CUDA Toolkit 12.3 + * v22 : CUDA Toolkit 12.4 + * v23 : CUDA Toolkit 12.5 + * v24 : CUDA Toolkit 12.6 + */ +public static final int CUPTI_API_VERSION = 24; + +/** + * \brief Get the CUPTI API version. + * + * Return the API version in \p *version. + * + * @param version Returns the version + * + * \retval CUPTI_SUCCESS on success + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p version is NULL + * @see CUPTI_API_VERSION + */ +public static native @Cast("CUptiResult") int cuptiGetVersion(@Cast("uint32_t*") IntPointer version); +public static native @Cast("CUptiResult") int cuptiGetVersion(@Cast("uint32_t*") IntBuffer version); +public static native @Cast("CUptiResult") int cuptiGetVersion(@Cast("uint32_t*") int[] version); + +/** \} */ /* END CUPTI_VERSION_API */ + +// #if defined(__GNUC__) && defined(CUPTI_LIB) +// #pragma GCC visibility pop +// #endif + +// #if defined(__cplusplus) +// #endif + +// #endif /*_CUPTI_VERSION_H_*/ + + +// Parsed from cupti_activity.h + +/* + * Copyright 2011-2024 NVIDIA Corporation. All rights reserved. + * + * NOTICE TO LICENSEE: + * + * This source code and/or documentation ("Licensed Deliverables") are + * subject to NVIDIA intellectual property rights under U.S. and + * international Copyright laws. + * + * These Licensed Deliverables contained herein is PROPRIETARY and + * CONFIDENTIAL to NVIDIA and is being provided under the terms and + * conditions of a form of NVIDIA software license agreement by and + * between NVIDIA and Licensee ("License Agreement") or electronically + * accepted by Licensee. Notwithstanding any terms or conditions to + * the contrary in the License Agreement, reproduction or disclosure + * of the Licensed Deliverables to any third party without the express + * written consent of NVIDIA is prohibited. + * + * NOTWITHSTANDING ANY TERMS OR CONDITIONS TO THE CONTRARY IN THE + * LICENSE AGREEMENT, NVIDIA MAKES NO REPRESENTATION ABOUT THE + * SUITABILITY OF THESE LICENSED DELIVERABLES FOR ANY PURPOSE. IT IS + * PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY OF ANY KIND. + * NVIDIA DISCLAIMS ALL WARRANTIES WITH REGARD TO THESE LICENSED + * DELIVERABLES, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY, + * NONINFRINGEMENT, AND FITNESS FOR A PARTICULAR PURPOSE. + * NOTWITHSTANDING ANY TERMS OR CONDITIONS TO THE CONTRARY IN THE + * LICENSE AGREEMENT, IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY + * SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, OR ANY + * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, + * WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS + * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE + * OF THESE LICENSED DELIVERABLES. + * + * U.S. Government End Users. These Licensed Deliverables are a + * "commercial item" as that term is defined at 48 C.F.R. 2.101 (OCT + * 1995), consisting of "commercial computer software" and "commercial + * computer software documentation" as such terms are used in 48 + * C.F.R. 12.212 (SEPT 1995) and is provided to the U.S. Government + * only as a commercial end item. Consistent with 48 C.F.R.12.212 and + * 48 C.F.R. 227.7202-1 through 227.7202-4 (JUNE 1995), all + * U.S. Government End Users acquire the Licensed Deliverables with + * only those rights set forth herein. + * + * Any use of the Licensed Deliverables in individual and commercial + * software must include, in the user documentation and internal + * comments to the code, the above Disclaimer and U.S. Government End + * Users Notice. + */ + +// #if !defined(_CUPTI_ACTIVITY_H_) +// #define _CUPTI_ACTIVITY_H_ + +/** + * Deprecated APIs and structures have been moved to the + * header :doc: {@code cupti_activity_deprecated.h}, which is included at + * the bottom of this file. Header cupti_activity.h contains + * only the latest version of APIs and structures. + */ + +// #include +// #include +// #include +// #include +// #include + +// #if defined(CUPTI_DIRECTIVE_SUPPORT) +// #include +// #include +// #endif + +// #include + +public static final int CUPTI_UNIFIED_MEMORY_CPU_DEVICE_ID = ((int) 0xFFFFFFFF); +public static final int CUPTI_INVALID_CONTEXT_ID = ((int) 0xFFFFFFFF); +public static final int CUPTI_INVALID_STREAM_ID = ((int) 0xFFFFFFFF); +public static final int CUPTI_INVALID_CHANNEL_ID = ((int) 0xFFFFFFFF); + +// #if defined(__cplusplus) +// #endif + +// #if defined(__GNUC__) && defined(CUPTI_LIB) +// #pragma GCC visibility push(default) +// #endif + +public static final int invalidNumaId = ((int) 0xFFFFFFFF); + +/** + * \defgroup CUPTI_ACTIVITY_API CUPTI Activity API + * Functions, types, and enums that implement the CUPTI Activity API. + * \{ + */ + +/** + * \brief The kinds of activity records. + * + * Each activity record kind represents information about a GPU or an + * activity occurring on a CPU or GPU. Each kind is associated with a + * activity record structure that holds the information associated + * with the kind. + * @see CUpti_Activity + * @see CUpti_ActivityAPI + * @see CUpti_ActivityContext + * @see CUpti_ActivityContext2 + * @see CUpti_ActivityContext3 + * @see CUpti_ActivityDevice + * @see CUpti_ActivityDevice2 + * @see CUpti_ActivityDevice3 + * @see CUpti_ActivityDevice4 + * @see CUpti_ActivityDeviceAttribute + * @see CUpti_ActivityEvent + * @see CUpti_ActivityEventInstance + * @see CUpti_ActivityKernel + * @see CUpti_ActivityKernel2 + * @see CUpti_ActivityKernel3 + * @see CUpti_ActivityKernel4 + * @see CUpti_ActivityKernel5 + * @see CUpti_ActivityKernel6 + * @see CUpti_ActivityKernel7 + * @see CUpti_ActivityKernel8 + * @see CUpti_ActivityKernel9 + * @see CUpti_ActivityCdpKernel + * @see CUpti_ActivityPreemption + * @see CUpti_ActivityMemcpy + * @see CUpti_ActivityMemcpy3 + * @see CUpti_ActivityMemcpy4 + * @see CUpti_ActivityMemcpy5 + * @see CUpti_ActivityMemcpyPtoP + * @see CUpti_ActivityMemcpyPtoP2 + * @see CUpti_ActivityMemcpyPtoP3 + * @see CUpti_ActivityMemcpyPtoP4 + * @see CUpti_ActivityMemset + * @see CUpti_ActivityMemset2 + * @see CUpti_ActivityMemset3 + * @see CUpti_ActivityMemset4 + * @see CUpti_ActivityMemory + * @see CUpti_ActivityMemory2 + * @see CUpti_ActivityMemory3 + * @see CUpti_ActivityMemory4 + * @see CUpti_ActivityMemoryPool + * @see CUpti_ActivityMemoryPool2 + * @see CUpti_ActivityMetric + * @see CUpti_ActivityMetricInstance + * @see CUpti_ActivityName + * @see CUpti_ActivityMarker + * @see CUpti_ActivityMarker2 + * @see CUpti_ActivityMarkerData + * @see CUpti_ActivitySourceLocator + * @see CUpti_ActivityGlobalAccess + * @see CUpti_ActivityGlobalAccess2 + * @see CUpti_ActivityGlobalAccess3 + * @see CUpti_ActivityBranch + * @see CUpti_ActivityBranch2 + * @see CUpti_ActivityOverhead3 + * @see CUpti_ActivityEnvironment + * @see CUpti_ActivityInstructionExecution + * @see CUpti_ActivityUnifiedMemoryCounter + * @see CUpti_ActivityFunction + * @see CUpti_ActivityModule + * @see CUpti_ActivitySharedAccess + * @see CUpti_ActivityPCSampling + * @see CUpti_ActivityPCSampling2 + * @see CUpti_ActivityPCSampling3 + * @see CUpti_ActivityPCSamplingRecordInfo + * @see CUpti_ActivityCudaEvent + * @see CUpti_ActivityStream + * @see CUpti_ActivitySynchronization + * @see CUpti_ActivityInstructionCorrelation + * @see CUpti_ActivityExternalCorrelation + * @see CUpti_ActivityUnifiedMemoryCounter2 + * @see CUpti_ActivityOpenAccData + * @see CUpti_ActivityOpenAccLaunch + * @see CUpti_ActivityOpenAccOther + * @see CUpti_ActivityOpenMp + * @see CUpti_ActivityNvLink + * @see CUpti_ActivityNvLink2 + * @see CUpti_ActivityNvLink3 + * @see CUpti_ActivityNvLink4 + * @see CUpti_ActivityPcie + * @see CUpti_ActivityConfidentialComputeRotation + */ + +/** enum CUpti_ActivityKind */ +public static final int + /** + * The activity record is invalid. + */ + CUPTI_ACTIVITY_KIND_INVALID = 0, + + /** + * A host<->host, host<->device, or device<->device memory copy. The + * corresponding activity record structure is \ref + * CUpti_ActivityMemcpy5. + */ + CUPTI_ACTIVITY_KIND_MEMCPY = 1, + + /** + * A memory set executing on the GPU. The corresponding activity + * record structure is \ref CUpti_ActivityMemset4. + */ + CUPTI_ACTIVITY_KIND_MEMSET = 2, + + /** + * A kernel executing on the GPU. This activity kind may significantly change + * the overall performance characteristics of the application because all + * kernel executions are serialized on the GPU. Other activity kind for kernel + * CUPTI_ACTIVITY_KIND_CONCURRENT_KERNEL doesn't break kernel concurrency. + * The corresponding activity record structure is \ref CUpti_ActivityKernel9. + */ + CUPTI_ACTIVITY_KIND_KERNEL = 3, + + /** + * A CUDA driver API function execution. The corresponding activity + * record structure is \ref CUpti_ActivityAPI. + */ + CUPTI_ACTIVITY_KIND_DRIVER = 4, + + /** + * A CUDA runtime API function execution. The corresponding activity + * record structure is \ref CUpti_ActivityAPI. + */ + CUPTI_ACTIVITY_KIND_RUNTIME = 5, + + /** + * An event value. The corresponding activity record structure is + * \ref CUpti_ActivityEvent. + */ + CUPTI_ACTIVITY_KIND_EVENT = 6, + + /** + * A metric value. The corresponding activity record structure is + * \ref CUpti_ActivityMetric. + */ + CUPTI_ACTIVITY_KIND_METRIC = 7, + + /** + * Information about a device. The corresponding activity record + * structure is \ref CUpti_ActivityDevice5. + */ + CUPTI_ACTIVITY_KIND_DEVICE = 8, + + /** + * Information about a context. The corresponding activity record + * structure is \ref CUpti_ActivityContext3. + */ + CUPTI_ACTIVITY_KIND_CONTEXT = 9, + + /** + * A kernel executing on the GPU. This activity kind doesn't break + * kernel concurrency. The corresponding activity record structure + * is \ref CUpti_ActivityKernel9. + */ + CUPTI_ACTIVITY_KIND_CONCURRENT_KERNEL = 10, + + /** + * Resource naming done via NVTX APIs for thread, device, context, etc. + * The corresponding activity record structure is \ref CUpti_ActivityName. + */ + CUPTI_ACTIVITY_KIND_NAME = 11, + + /** + * Instantaneous, start, or end NVTX marker. The corresponding activity + * record structure is \ref CUpti_ActivityMarker2. + */ + CUPTI_ACTIVITY_KIND_MARKER = 12, + + /** + * Extended, optional, data about a marker. The corresponding + * activity record structure is \ref CUpti_ActivityMarkerData. + */ + CUPTI_ACTIVITY_KIND_MARKER_DATA = 13, + + /** + * Source information about source level result. The corresponding + * activity record structure is \ref CUpti_ActivitySourceLocator. + * In CUDA 12.6, this kind is deprecated for Volta and later GPU architectures + * in favor of SASS Metric APIs from the header cupti_sass_metrics.h. + */ + CUPTI_ACTIVITY_KIND_SOURCE_LOCATOR = 14, + + /** + * Results for source-level global access. The + * corresponding activity record structure is \ref + * CUpti_ActivityGlobalAccess3. + * In CUDA 12.6, this kind is deprecated for Volta and later GPU architectures + * in favor of SASS Metric APIs from the header cupti_sass_metrics.h. + */ + CUPTI_ACTIVITY_KIND_GLOBAL_ACCESS = 15, + + /** + * Results for source-level branch. The corresponding + * activity record structure is \ref CUpti_ActivityBranch2. + * In CUDA 12.6, this kind is deprecated for Volta and later GPU architectures + * in favor of SASS Metric APIs from the header cupti_sass_metrics.h. + */ + CUPTI_ACTIVITY_KIND_BRANCH = 16, + + /** + * Overhead activity records. The + * corresponding activity record structure is + * \ref CUpti_ActivityOverhead3. + */ + CUPTI_ACTIVITY_KIND_OVERHEAD = 17, + + /** + * A CDP (CUDA Dynamic Parallel) kernel executing on the GPU. The + * corresponding activity record structure is \ref + * CUpti_ActivityCdpKernel. This activity can not be directly + * enabled or disabled. It is enabled and disabled through + * concurrent kernel activity i.e. _CONCURRENT_KERNEL. + */ + CUPTI_ACTIVITY_KIND_CDP_KERNEL = 18, + /** + * Preemption activity record indicating a preemption of a CDP (CUDA + * Dynamic Parallel) kernel executing on the GPU. The corresponding + * activity record structure is \ref CUpti_ActivityPreemption. + */ + CUPTI_ACTIVITY_KIND_PREEMPTION = 19, + + /** + * Environment activity records indicating power, clock, thermal, + * etc. levels of the GPU. The corresponding activity record + * structure is \ref CUpti_ActivityEnvironment. + */ + CUPTI_ACTIVITY_KIND_ENVIRONMENT = 20, + + /** + * An event value associated with a specific event domain + * instance. The corresponding activity record structure is \ref + * CUpti_ActivityEventInstance. + */ + CUPTI_ACTIVITY_KIND_EVENT_INSTANCE = 21, + + /** + * A peer to peer memory copy. The corresponding activity record + * structure is \ref CUpti_ActivityMemcpyPtoP4. + */ + CUPTI_ACTIVITY_KIND_MEMCPY2 = 22, + + /** + * A metric value associated with a specific metric domain + * instance. The corresponding activity record structure is \ref + * CUpti_ActivityMetricInstance. + */ + CUPTI_ACTIVITY_KIND_METRIC_INSTANCE = 23, + + /** + * Results for source-level instruction execution. + * The corresponding activity record structure is \ref + * CUpti_ActivityInstructionExecution. + * In CUDA 12.6, this kind is deprecated for Volta and later GPU architectures + * in favor of SASS Metric APIs from the header cupti_sass_metrics.h. + */ + CUPTI_ACTIVITY_KIND_INSTRUCTION_EXECUTION = 24, + + /** + * Unified Memory counter record. The corresponding activity + * record structure is \ref CUpti_ActivityUnifiedMemoryCounter2. + */ + CUPTI_ACTIVITY_KIND_UNIFIED_MEMORY_COUNTER = 25, + + /** + * Device global/function record. The corresponding activity + * record structure is \ref CUpti_ActivityFunction. + */ + CUPTI_ACTIVITY_KIND_FUNCTION = 26, + + /** + * CUDA Module record. The corresponding activity + * record structure is \ref CUpti_ActivityModule. + */ + CUPTI_ACTIVITY_KIND_MODULE = 27, + + /** + * A device attribute value. The corresponding activity record + * structure is \ref CUpti_ActivityDeviceAttribute. + */ + CUPTI_ACTIVITY_KIND_DEVICE_ATTRIBUTE = 28, + + /** + * Results for source-level shared access. The + * corresponding activity record structure is \ref + * CUpti_ActivitySharedAccess. + * In CUDA 12.6, this kind is deprecated for Volta and later GPU architectures + * in favor of SASS Metric APIs from the header cupti_sass_metrics.h. + */ + CUPTI_ACTIVITY_KIND_SHARED_ACCESS = 29, + + /** + * Enable PC sampling for kernels. This will serialize + * kernels. The corresponding activity record structure + * is \ref CUpti_ActivityPCSampling3. In CUDA 12.5, this kind + * is deprecated for Volta and later GPU architectures in favor + * of PC Sampling APIs from the header cupti_pcsampling.h. + */ + CUPTI_ACTIVITY_KIND_PC_SAMPLING = 30, + + /** + * Summary information about PC sampling records. The + * corresponding activity record structure is \ref + * CUpti_ActivityPCSamplingRecordInfo. In CUDA 12.5, this kind + * is deprecated for Volta and later GPU architectures in favor + * of PC Sampling APIs from the header cupti_pcsampling.h. + */ + CUPTI_ACTIVITY_KIND_PC_SAMPLING_RECORD_INFO = 31, + + /** + * SASS/Source line-by-line correlation record. + * This will generate sass/source correlation for functions that have source + * level analysis or pc sampling results. The records will be generated only + * when either of source level analysis or pc sampling activity is enabled. + * The corresponding activity record structure is \ref + * CUpti_ActivityInstructionCorrelation. + * In CUDA 12.6, this kind is deprecated for Volta and later GPU architectures + * in favor of SASS Metric APIs from the header cupti_sass_metrics.h. + */ + CUPTI_ACTIVITY_KIND_INSTRUCTION_CORRELATION = 32, + + /** + * OpenACC data events. + * The corresponding activity record structure is \ref + * CUpti_ActivityOpenAccData. + */ + CUPTI_ACTIVITY_KIND_OPENACC_DATA = 33, + + /** + * OpenACC launch events. + * The corresponding activity record structure is \ref + * CUpti_ActivityOpenAccLaunch. + */ + CUPTI_ACTIVITY_KIND_OPENACC_LAUNCH = 34, + + /** + * OpenACC other events. + * The corresponding activity record structure is \ref + * CUpti_ActivityOpenAccOther. + */ + CUPTI_ACTIVITY_KIND_OPENACC_OTHER = 35, + + /** + * Information about a CUDA event. The + * corresponding activity record structure is \ref + * CUpti_ActivityCudaEvent. + */ + CUPTI_ACTIVITY_KIND_CUDA_EVENT = 36, + + /** + * Information about a CUDA stream. The + * corresponding activity record structure is \ref + * CUpti_ActivityStream. + */ + CUPTI_ACTIVITY_KIND_STREAM = 37, + + /** + * Records for synchronization management. The + * corresponding activity record structure is \ref + * CUpti_ActivitySynchronization. + */ + CUPTI_ACTIVITY_KIND_SYNCHRONIZATION = 38, + + /** + * Records for correlation of different programming APIs. The + * corresponding activity record structure is \ref + * CUpti_ActivityExternalCorrelation. + */ + CUPTI_ACTIVITY_KIND_EXTERNAL_CORRELATION = 39, + + /** + * NVLink information. + * The corresponding activity record structure is \ref + * CUpti_ActivityNvLink4. + */ + CUPTI_ACTIVITY_KIND_NVLINK = 40, + + /** + * Instantaneous Event information. + * The corresponding activity record structure is \ref + * CUpti_ActivityInstantaneousEvent. + */ + CUPTI_ACTIVITY_KIND_INSTANTANEOUS_EVENT = 41, + + /** + * Instantaneous Event information for a specific event + * domain instance. + * The corresponding activity record structure is \ref + * CUpti_ActivityInstantaneousEventInstance + */ + CUPTI_ACTIVITY_KIND_INSTANTANEOUS_EVENT_INSTANCE = 42, + + /** + * Instantaneous Metric information + * The corresponding activity record structure is \ref + * CUpti_ActivityInstantaneousMetric. + */ + CUPTI_ACTIVITY_KIND_INSTANTANEOUS_METRIC = 43, + + /** + * Instantaneous Metric information for a specific metric + * domain instance. + * The corresponding activity record structure is \ref + * CUpti_ActivityInstantaneousMetricInstance. + */ + CUPTI_ACTIVITY_KIND_INSTANTANEOUS_METRIC_INSTANCE = 44, + + /** + * Memory activity tracking allocation and freeing of the memory + * The corresponding activity record structure is \ref + * CUpti_ActivityMemory. + */ + CUPTI_ACTIVITY_KIND_MEMORY = 45, + + /** + * PCI devices information used for PCI topology. + * The corresponding activity record structure is \ref + * CUpti_ActivityPcie. + */ + CUPTI_ACTIVITY_KIND_PCIE = 46, + + /** + * OpenMP parallel events. + * The corresponding activity record structure is \ref + * CUpti_ActivityOpenMp. + */ + CUPTI_ACTIVITY_KIND_OPENMP = 47, + + /** + * A CUDA driver kernel launch occurring outside of any + * public API function execution. Tools can handle these + * like records for driver API launch functions, although + * the cbid field is not used here. + * The corresponding activity record structure is \ref + * CUpti_ActivityAPI. + */ + CUPTI_ACTIVITY_KIND_INTERNAL_LAUNCH_API = 48, + + /** + * Memory activity tracking allocation and freeing of the memory + * The corresponding activity record structure is \ref + * CUpti_ActivityMemory4. + */ + CUPTI_ACTIVITY_KIND_MEMORY2 = 49, + + /** + * Memory pool activity tracking creation, destruction and + * trimming of the memory pool. + * The corresponding activity record structure is \ref + * CUpti_ActivityMemoryPool2. + */ + CUPTI_ACTIVITY_KIND_MEMORY_POOL = 50, + + /** + * The corresponding activity record structure is + * \ref CUpti_ActivityGraphTrace2. + */ + CUPTI_ACTIVITY_KIND_GRAPH_TRACE = 51, + + /** + * JIT operation tracking + * The corresponding activity record structure is \ref + * CUpti_ActivityJit. + */ + CUPTI_ACTIVITY_KIND_JIT = 52, + + + + CUPTI_ACTIVITY_KIND_COUNT = 53, + + CUPTI_ACTIVITY_KIND_FORCE_INT = 0x7fffffff; + +/** + * \brief The kinds of activity objects. + * @see CUpti_ActivityObjectKindId + */ +/** enum CUpti_ActivityObjectKind */ +public static final int + /** + * The object kind is not known. + */ + CUPTI_ACTIVITY_OBJECT_UNKNOWN = 0, + + /** + * A process. + */ + CUPTI_ACTIVITY_OBJECT_PROCESS = 1, + + /** + * A thread. + */ + CUPTI_ACTIVITY_OBJECT_THREAD = 2, + + /** + * A device. + */ + CUPTI_ACTIVITY_OBJECT_DEVICE = 3, + + /** + * A context. + */ + CUPTI_ACTIVITY_OBJECT_CONTEXT = 4, + + /** + * A stream. + */ + CUPTI_ACTIVITY_OBJECT_STREAM = 5, + + CUPTI_ACTIVITY_OBJECT_FORCE_INT = 0x7fffffff; +// Targeting ../cupti/CUpti_ActivityObjectKindId.java + + +// Targeting ../cupti/CUpti_ActivityOverheadCommandBufferFullData.java + + + +/** + * \brief The kinds of activity overhead. + */ +/** enum CUpti_ActivityOverheadKind */ +public static final int + /** + * The overhead kind is not known. + */ + CUPTI_ACTIVITY_OVERHEAD_UNKNOWN = 0, + + /** + * Compiler overhead. + */ + CUPTI_ACTIVITY_OVERHEAD_DRIVER_COMPILER = 1, + + /** + * Activity buffer flush overhead. + */ + CUPTI_ACTIVITY_OVERHEAD_CUPTI_BUFFER_FLUSH = 1<<16, + + /** + * CUPTI instrumentation overhead. + */ + CUPTI_ACTIVITY_OVERHEAD_CUPTI_INSTRUMENTATION = 2<<16, + + /** + * CUPTI resource creation and destruction overhead. + */ + CUPTI_ACTIVITY_OVERHEAD_CUPTI_RESOURCE = 3<<16, + + /** + * CUDA Runtime triggered module loading overhead. + */ + CUPTI_ACTIVITY_OVERHEAD_RUNTIME_TRIGGERED_MODULE_LOADING = 4<<16, + + /** + * Lazy function loading overhead. + */ + CUPTI_ACTIVITY_OVERHEAD_LAZY_FUNCTION_LOADING = 5<<16, + + /** + * Overhead due to lack of command buffer space. + * Refer CUpti_ActivityOverheadCommandBufferFullData for more details. + */ + CUPTI_ACTIVITY_OVERHEAD_COMMAND_BUFFER_FULL = 6<<16, + + /** + * Overhead due to activity buffer request. + */ + CUPTI_ACTIVITY_OVERHEAD_ACTIVITY_BUFFER_REQUEST = 7<<16, + + CUPTI_ACTIVITY_OVERHEAD_FORCE_INT = 0x7fffffff; + +/** + * \brief The kind of a compute API. + */ +/** enum CUpti_ActivityComputeApiKind */ +public static final int + /** + * The compute API is not known. + */ + CUPTI_ACTIVITY_COMPUTE_API_UNKNOWN = 0, + + /** + * The compute APIs are for CUDA. + */ + CUPTI_ACTIVITY_COMPUTE_API_CUDA = 1, + + /** + * The compute APIs are for CUDA running + * in MPS (Multi-Process Service) environment. + */ + CUPTI_ACTIVITY_COMPUTE_API_CUDA_MPS = 2, + + CUPTI_ACTIVITY_COMPUTE_API_FORCE_INT = 0x7fffffff; + +/** + * \brief Flags associated with activity records. + * + * Activity record flags. Flags can be combined by bitwise OR to + * associated multiple flags with an activity record. Each flag is + * specific to a certain activity kind, as noted below. + */ +/** enum CUpti_ActivityFlag */ +public static final int + /** + * Indicates the activity record has no flags. + */ + CUPTI_ACTIVITY_FLAG_NONE = 0, + + /** + * Indicates the activity represents a device that supports + * concurrent kernel execution. Valid for + * CUPTI_ACTIVITY_KIND_DEVICE. + */ + CUPTI_ACTIVITY_FLAG_DEVICE_CONCURRENT_KERNELS = 1 << 0, + + /** + * Indicates if the activity represents a CUdevice_attribute value + * or a CUpti_DeviceAttribute value. Valid for + * CUPTI_ACTIVITY_KIND_DEVICE_ATTRIBUTE. + */ + CUPTI_ACTIVITY_FLAG_DEVICE_ATTRIBUTE_CUDEVICE = 1 << 0, + + /** + * Indicates the activity represents an asynchronous memcpy + * operation. Valid for CUPTI_ACTIVITY_KIND_MEMCPY. + */ + CUPTI_ACTIVITY_FLAG_MEMCPY_ASYNC = 1 << 0, + + /** + * Indicates the activity represents an instantaneous marker. Valid + * for CUPTI_ACTIVITY_KIND_MARKER. + */ + CUPTI_ACTIVITY_FLAG_MARKER_INSTANTANEOUS = 1 << 0, + + /** + * Indicates the activity represents a region start marker. Valid + * for CUPTI_ACTIVITY_KIND_MARKER. + */ + CUPTI_ACTIVITY_FLAG_MARKER_START = 1 << 1, + + /** + * Indicates the activity represents a region end marker. Valid for + * CUPTI_ACTIVITY_KIND_MARKER. + */ + CUPTI_ACTIVITY_FLAG_MARKER_END = 1 << 2, + + /** + * Indicates the activity represents an attempt to acquire a user + * defined synchronization object. + * Valid for CUPTI_ACTIVITY_KIND_MARKER. + */ + CUPTI_ACTIVITY_FLAG_MARKER_SYNC_ACQUIRE = 1 << 3, + + /** + * Indicates the activity represents success in acquiring the + * user defined synchronization object. + * Valid for CUPTI_ACTIVITY_KIND_MARKER. + */ + CUPTI_ACTIVITY_FLAG_MARKER_SYNC_ACQUIRE_SUCCESS = 1 << 4, + + /** + * Indicates the activity represents failure in acquiring the + * user defined synchronization object. + * Valid for CUPTI_ACTIVITY_KIND_MARKER. + */ + CUPTI_ACTIVITY_FLAG_MARKER_SYNC_ACQUIRE_FAILED = 1 << 5, + + /** + * Indicates the activity represents releasing a reservation on + * user defined synchronization object. + * Valid for CUPTI_ACTIVITY_KIND_MARKER. + */ + CUPTI_ACTIVITY_FLAG_MARKER_SYNC_RELEASE = 1 << 6, + + /** + * Indicates the activity represents a marker that does not specify + * a color. Valid for CUPTI_ACTIVITY_KIND_MARKER_DATA. + */ + CUPTI_ACTIVITY_FLAG_MARKER_COLOR_NONE = 1 << 0, + + /** + * Indicates the activity represents a marker that specifies a color + * in alpha-red-green-blue format. Valid for + * CUPTI_ACTIVITY_KIND_MARKER_DATA. + */ + CUPTI_ACTIVITY_FLAG_MARKER_COLOR_ARGB = 1 << 1, + + /** + * The number of bytes requested by each thread + * Valid for CUpti_ActivityGlobalAccess3. + */ + CUPTI_ACTIVITY_FLAG_GLOBAL_ACCESS_KIND_SIZE_MASK = 0xFF << 0, + + /** + * If bit in this flag is set, the access was load, else it is a + * store access. Valid for CUpti_ActivityGlobalAccess3. + */ + CUPTI_ACTIVITY_FLAG_GLOBAL_ACCESS_KIND_LOAD = 1 << 8, + + /** + * If this bit in flag is set, the load access was cached else it is + * uncached. Valid for CUpti_ActivityGlobalAccess3. + */ + CUPTI_ACTIVITY_FLAG_GLOBAL_ACCESS_KIND_CACHED = 1 << 9, + + /** + * If this bit in flag is set, the metric value overflowed. Valid + * for CUpti_ActivityMetric and CUpti_ActivityMetricInstance. + */ + CUPTI_ACTIVITY_FLAG_METRIC_OVERFLOWED = 1 << 0, + + /** + * If this bit in flag is set, the metric value couldn't be + * calculated. This occurs when a value(s) required to calculate the + * metric is missing. Valid for CUpti_ActivityMetric and + * CUpti_ActivityMetricInstance. + */ + CUPTI_ACTIVITY_FLAG_METRIC_VALUE_INVALID = 1 << 1, + + /** + * If this bit in flag is set, the source level metric value couldn't be + * calculated. This occurs when a value(s) required to calculate the + * source level metric cannot be evaluated. + * Valid for CUpti_ActivityInstructionExecution. + */ + CUPTI_ACTIVITY_FLAG_INSTRUCTION_VALUE_INVALID = 1 << 0, + + /** + * The mask for the instruction class, \ref CUpti_ActivityInstructionClass + * Valid for CUpti_ActivityInstructionExecution and + * CUpti_ActivityInstructionCorrelation + */ + CUPTI_ACTIVITY_FLAG_INSTRUCTION_CLASS_MASK = 0xFF << 1, + + /** + * When calling cuptiActivityFlushAll, this flag + * can be set to force CUPTI to flush all records in the buffer, whether + * finished or not + */ + CUPTI_ACTIVITY_FLAG_FLUSH_FORCED = 1 << 0, + + /** + * The number of bytes requested by each thread + * Valid for CUpti_ActivitySharedAccess. + */ + CUPTI_ACTIVITY_FLAG_SHARED_ACCESS_KIND_SIZE_MASK = 0xFF << 0, + + /** + * If bit in this flag is set, the access was load, else it is a + * store access. Valid for CUpti_ActivitySharedAccess. + */ + CUPTI_ACTIVITY_FLAG_SHARED_ACCESS_KIND_LOAD = 1 << 8, + + /** + * Indicates the activity represents an asynchronous memset + * operation. Valid for CUPTI_ACTIVITY_KIND_MEMSET. + */ + CUPTI_ACTIVITY_FLAG_MEMSET_ASYNC = 1 << 0, + + /** + * Indicates the activity represents thrashing in CPU. + * Valid for counter of kind CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_THRASHING in + * CUPTI_ACTIVITY_KIND_UNIFIED_MEMORY_COUNTER + */ + CUPTI_ACTIVITY_FLAG_THRASHING_IN_CPU = 1 << 0, + + /** + * Indicates the activity represents page throttling in CPU. + * Valid for counter of kind CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_THROTTLING in + * CUPTI_ACTIVITY_KIND_UNIFIED_MEMORY_COUNTER + */ + CUPTI_ACTIVITY_FLAG_THROTTLING_IN_CPU = 1 << 0, + + CUPTI_ACTIVITY_FLAG_FORCE_INT = 0x7fffffff; + +/** + * \brief The stall reason for PC sampling activity. + */ +/** enum CUpti_ActivityPCSamplingStallReason */ +public static final int + /** + * Invalid reason + */ + CUPTI_ACTIVITY_PC_SAMPLING_STALL_INVALID = 0, + + /** + * No stall, instruction is selected for issue + */ + CUPTI_ACTIVITY_PC_SAMPLING_STALL_NONE = 1, + + /** + * Warp is blocked because next instruction is not yet available, + * because of instruction cache miss, or because of branching effects + */ + CUPTI_ACTIVITY_PC_SAMPLING_STALL_INST_FETCH = 2, + + /** + * Instruction is waiting on an arithmetic dependency + */ + CUPTI_ACTIVITY_PC_SAMPLING_STALL_EXEC_DEPENDENCY = 3, + + /** + * Warp is blocked because it is waiting for a memory access to complete. + */ + CUPTI_ACTIVITY_PC_SAMPLING_STALL_MEMORY_DEPENDENCY = 4, + + /** + * Texture sub-system is fully utilized or has too many outstanding requests. + */ + CUPTI_ACTIVITY_PC_SAMPLING_STALL_TEXTURE = 5, + + /** + * Warp is blocked as it is waiting at __syncthreads() or at memory barrier. + */ + CUPTI_ACTIVITY_PC_SAMPLING_STALL_SYNC = 6, + + /** + * Warp is blocked waiting for __constant__ memory and immediate memory access to complete. + */ + CUPTI_ACTIVITY_PC_SAMPLING_STALL_CONSTANT_MEMORY_DEPENDENCY = 7, + + /** + * Compute operation cannot be performed due to the required resources not + * being available. + */ + CUPTI_ACTIVITY_PC_SAMPLING_STALL_PIPE_BUSY = 8, + + /** + * Warp is blocked because there are too many pending memory operations. + * In Kepler architecture it often indicates high number of memory replays. + */ + CUPTI_ACTIVITY_PC_SAMPLING_STALL_MEMORY_THROTTLE = 9, + + /** + * Warp was ready to issue, but some other warp issued instead. + */ + CUPTI_ACTIVITY_PC_SAMPLING_STALL_NOT_SELECTED = 10, + + /** + * Miscellaneous reasons + */ + CUPTI_ACTIVITY_PC_SAMPLING_STALL_OTHER = 11, + + /** + * Sleeping. + */ + CUPTI_ACTIVITY_PC_SAMPLING_STALL_SLEEPING = 12, + + CUPTI_ACTIVITY_PC_SAMPLING_STALL_FORCE_INT = 0x7fffffff; + +/** + * \brief Sampling period for PC sampling method + * + * Sampling period can be set using \ref cuptiActivityConfigurePCSampling + */ +/** enum CUpti_ActivityPCSamplingPeriod */ +public static final int + /** + * The PC sampling period is not set. + */ + CUPTI_ACTIVITY_PC_SAMPLING_PERIOD_INVALID = 0, + + /** + * Minimum sampling period available on the device. + */ + CUPTI_ACTIVITY_PC_SAMPLING_PERIOD_MIN = 1, + + /** + * Sampling period in lower range. + */ + CUPTI_ACTIVITY_PC_SAMPLING_PERIOD_LOW = 2, + + /** + * Medium sampling period. + */ + CUPTI_ACTIVITY_PC_SAMPLING_PERIOD_MID = 3, + + /** + * Sampling period in higher range. + */ + CUPTI_ACTIVITY_PC_SAMPLING_PERIOD_HIGH = 4, + + /** + * Maximum sampling period available on the device. + */ + CUPTI_ACTIVITY_PC_SAMPLING_PERIOD_MAX = 5, + + CUPTI_ACTIVITY_PC_SAMPLING_PERIOD_FORCE_INT = 0x7fffffff; + +/** + * \brief The kind of a memory copy, indicating the source and + * destination targets of the copy. + * + * Each kind represents the source and destination targets of a memory + * copy. Targets are host, device, and array. + */ +/** enum CUpti_ActivityMemcpyKind */ +public static final int + /** + * The memory copy kind is not known. + */ + CUPTI_ACTIVITY_MEMCPY_KIND_UNKNOWN = 0, + + /** + * A host to device memory copy. + */ + CUPTI_ACTIVITY_MEMCPY_KIND_HTOD = 1, + + /** + * A device to host memory copy. + */ + CUPTI_ACTIVITY_MEMCPY_KIND_DTOH = 2, + + /** + * A host to device array memory copy. + */ + CUPTI_ACTIVITY_MEMCPY_KIND_HTOA = 3, + + /** + * A device array to host memory copy. + */ + CUPTI_ACTIVITY_MEMCPY_KIND_ATOH = 4, + + /** + * A device array to device array memory copy. + */ + CUPTI_ACTIVITY_MEMCPY_KIND_ATOA = 5, + + /** + * A device array to device memory copy. + */ + CUPTI_ACTIVITY_MEMCPY_KIND_ATOD = 6, + + /** + * A device to device array memory copy. + */ + CUPTI_ACTIVITY_MEMCPY_KIND_DTOA = 7, + + /** + * A device to device memory copy on the same device. + */ + CUPTI_ACTIVITY_MEMCPY_KIND_DTOD = 8, + + /** + * A host to host memory copy. + */ + CUPTI_ACTIVITY_MEMCPY_KIND_HTOH = 9, + + /** + * A peer to peer memory copy across different devices. + */ + CUPTI_ACTIVITY_MEMCPY_KIND_PTOP = 10, + + CUPTI_ACTIVITY_MEMCPY_KIND_FORCE_INT = 0x7fffffff; + +/** + * \brief The kinds of memory accessed by a memory operation/copy. + * + * Each kind represents the type of the memory + * accessed by a memory operation/copy. + */ +/** enum CUpti_ActivityMemoryKind */ +public static final int + /** + * The memory kind is unknown. + */ + CUPTI_ACTIVITY_MEMORY_KIND_UNKNOWN = 0, + + /** + * The memory is pageable. + */ + CUPTI_ACTIVITY_MEMORY_KIND_PAGEABLE = 1, + + /** + * The memory is pinned. + */ + CUPTI_ACTIVITY_MEMORY_KIND_PINNED = 2, + + /** + * The memory is on the device. + */ + CUPTI_ACTIVITY_MEMORY_KIND_DEVICE = 3, + + /** + * The memory is an array. + */ + CUPTI_ACTIVITY_MEMORY_KIND_ARRAY = 4, + + /** + * The memory is managed + */ + CUPTI_ACTIVITY_MEMORY_KIND_MANAGED = 5, + + /** + * The memory is device static + */ + CUPTI_ACTIVITY_MEMORY_KIND_DEVICE_STATIC = 6, + + /** + * The memory is managed static + */ + CUPTI_ACTIVITY_MEMORY_KIND_MANAGED_STATIC = 7, + + CUPTI_ACTIVITY_MEMORY_KIND_FORCE_INT = 0x7fffffff; + +/** + * \brief The kind of a preemption activity. + */ +/** enum CUpti_ActivityPreemptionKind */ +public static final int + /** + * The preemption kind is not known. + */ + CUPTI_ACTIVITY_PREEMPTION_KIND_UNKNOWN = 0, + + /** + * Preemption to save CDP block. + */ + CUPTI_ACTIVITY_PREEMPTION_KIND_SAVE = 1, + + /** + * Preemption to restore CDP block. + */ + CUPTI_ACTIVITY_PREEMPTION_KIND_RESTORE = 2, + + CUPTI_ACTIVITY_PREEMPTION_KIND_FORCE_INT = 0x7fffffff; + +/** + * \brief The kind of environment data. Used to indicate what type of + * data is being reported by an environment activity record. + */ +/** enum CUpti_ActivityEnvironmentKind */ +public static final int + /** + * Unknown data. + */ + CUPTI_ACTIVITY_ENVIRONMENT_UNKNOWN = 0, + + /** + * The environment data is related to speed. + */ + CUPTI_ACTIVITY_ENVIRONMENT_SPEED = 1, + + /** + * The environment data is related to temperature. + */ + CUPTI_ACTIVITY_ENVIRONMENT_TEMPERATURE = 2, + + /** + * The environment data is related to power. + */ + CUPTI_ACTIVITY_ENVIRONMENT_POWER = 3, + + /** + * The environment data is related to cooling. + */ + CUPTI_ACTIVITY_ENVIRONMENT_COOLING = 4, + + CUPTI_ACTIVITY_ENVIRONMENT_COUNT = 5, + + CUPTI_ACTIVITY_ENVIRONMENT_KIND_FORCE_INT = 0x7fffffff; + +/** + * \brief Reasons for clock throttling. + * + * The possible reasons that a clock can be throttled. There can be + * more than one reason that a clock is being throttled so these types + * can be combined by bitwise OR. These are used in the + * clocksThrottleReason field in the Environment Activity Record. + */ +/** enum CUpti_EnvironmentClocksThrottleReason */ +public static final int + /** + * Nothing is running on the GPU and the clocks are dropping to idle + * state. + */ + CUPTI_CLOCKS_THROTTLE_REASON_GPU_IDLE = 0x00000001, + + /** + * The GPU clocks are limited by a user specified limit. + */ + CUPTI_CLOCKS_THROTTLE_REASON_USER_DEFINED_CLOCKS = 0x00000002, + + /** + * A software power scaling algorithm is reducing the clocks below + * requested clocks. + */ + CUPTI_CLOCKS_THROTTLE_REASON_SW_POWER_CAP = 0x00000004, + + /** + * Hardware slowdown to reduce the clock by a factor of two or more + * is engaged. This is an indicator of one of the following: 1) + * Temperature is too high, 2) External power brake assertion is + * being triggered (e.g. by the system power supply), 3) Change in + * power state. + */ + CUPTI_CLOCKS_THROTTLE_REASON_HW_SLOWDOWN = 0x00000008, + + /** + * Some unspecified factor is reducing the clocks. + */ + CUPTI_CLOCKS_THROTTLE_REASON_UNKNOWN = 0x80000000, + + /** + * Throttle reason is not supported for this GPU. + */ + CUPTI_CLOCKS_THROTTLE_REASON_UNSUPPORTED = 0x40000000, + + /** + * No clock throttling. + */ + CUPTI_CLOCKS_THROTTLE_REASON_NONE = 0x00000000, + + CUPTI_CLOCKS_THROTTLE_REASON_FORCE_INT = 0x7fffffff; + +/** + * \brief Scope of the unified memory counter (deprecated in CUDA 7.0) + */ +/** enum CUpti_ActivityUnifiedMemoryCounterScope */ +public static final int + /** + * The unified memory counter scope is not known. + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_SCOPE_UNKNOWN = 0, + + /** + * Collect unified memory counter for single process on one device + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_SCOPE_PROCESS_SINGLE_DEVICE = 1, + + /** + * Collect unified memory counter for single process across all devices + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_SCOPE_PROCESS_ALL_DEVICES = 2, + + CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_SCOPE_COUNT = 3, + + CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_SCOPE_FORCE_INT = 0x7fffffff; + +/** + * \brief Kind of the Unified Memory counter + * + * Many activities are associated with Unified Memory mechanism; among them + * are transfers from host to device, device to host, page fault at + * host side. + */ +/** enum CUpti_ActivityUnifiedMemoryCounterKind */ +public static final int + /** + * The unified memory counter kind is not known. + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_UNKNOWN = 0, + + /** + * Number of bytes transferred from host to device + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_BYTES_TRANSFER_HTOD = 1, + + /** + * Number of bytes transferred from device to host + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_BYTES_TRANSFER_DTOH = 2, + + /** + * Number of CPU page faults, this is only supported on 64 bit + * Linux and Mac platforms + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_CPU_PAGE_FAULT_COUNT = 3, + + /** + * Number of GPU page faults, this is only supported on devices with + * compute capability 6.0 and higher and 64 bit Linux platforms + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_GPU_PAGE_FAULT = 4, + + /** + * Thrashing occurs when data is frequently accessed by + * multiple processors and has to be constantly migrated around + * to achieve data locality. In this case the overhead of migration + * may exceed the benefits of locality. + * This is only supported on 64 bit Linux platforms. + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_THRASHING = 5, + + /** + * Throttling is a prevention technique used by the driver to avoid + * further thrashing. Here, the driver doesn't service the fault for + * one of the contending processors for a specific period of time, + * so that the other processor can run at full-speed. + * This is only supported on 64 bit Linux platforms. + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_THROTTLING = 6, + + /** + * In case throttling does not help, the driver tries to pin the memory + * to a processor for a specific period of time. One of the contending + * processors will have slow access to the memory, while the other will + * have fast access. + * This is only supported on 64 bit Linux platforms. + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_REMOTE_MAP = 7, + + /** + * Number of bytes transferred from one device to another device. + * This is only supported on 64 bit Linux platforms. + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_BYTES_TRANSFER_DTOD = 8, + + CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_COUNT = 9, + + CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_FORCE_INT = 0x7fffffff; + +/** + * \brief Memory access type for unified memory page faults + * + * This is valid for \ref CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_GPU_PAGE_FAULT + * and \ref CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_CPU_PAGE_FAULT_COUNT + */ +/** enum CUpti_ActivityUnifiedMemoryAccessType */ +public static final int + /** + * The unified memory access type is not known + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_ACCESS_TYPE_UNKNOWN = 0, + + /** + * The page fault was triggered by read memory instruction + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_ACCESS_TYPE_READ = 1, + + /** + * The page fault was triggered by write memory instruction + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_ACCESS_TYPE_WRITE = 2, + + /** + * The page fault was triggered by atomic memory instruction + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_ACCESS_TYPE_ATOMIC = 3, + + /** + * The page fault was triggered by memory prefetch operation + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_ACCESS_TYPE_PREFETCH = 4; + +/** + * \brief Migration cause of the Unified Memory counter + * + * This is valid for \ref CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_BYTES_TRANSFER_HTOD and + * \ref CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_BYTES_TRANSFER_DTOH + */ +/** enum CUpti_ActivityUnifiedMemoryMigrationCause */ +public static final int + /** + * The unified memory migration cause is not known + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_MIGRATION_CAUSE_UNKNOWN = 0, + + /** + * The unified memory migrated due to an explicit call from + * the user e.g. cudaMemPrefetchAsync + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_MIGRATION_CAUSE_USER = 1, + + /** + * The unified memory migrated to guarantee data coherence + * e.g. CPU/GPU faults on Pascal+ and kernel launch on pre-Pascal GPUs + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_MIGRATION_CAUSE_COHERENCE = 2, + + /** + * The unified memory was speculatively migrated by the UVM driver + * before being accessed by the destination processor to improve + * performance + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_MIGRATION_CAUSE_PREFETCH = 3, + + /** + * The unified memory migrated to the CPU because it was evicted to make + * room for another block of memory on the GPU + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_MIGRATION_CAUSE_EVICTION = 4, + + /** + * The unified memory migrated to another processor because of access counter + * notifications. Only frequently accessed pages are migrated between CPU and GPU, or + * between peer GPUs. + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_MIGRATION_CAUSE_ACCESS_COUNTERS = 5; + +/** + * \brief Remote memory map cause of the Unified Memory counter + * + * This is valid for \ref CUPTI_ACTIVITY_UNIFIED_MEMORY_COUNTER_KIND_REMOTE_MAP + */ +/** enum CUpti_ActivityUnifiedMemoryRemoteMapCause */ +public static final int + /** + * The cause of mapping to remote memory was unknown + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_REMOTE_MAP_CAUSE_UNKNOWN = 0, + + /** + * Mapping to remote memory was added to maintain data coherence. + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_REMOTE_MAP_CAUSE_COHERENCE = 1, + + /** + * Mapping to remote memory was added to prevent further thrashing + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_REMOTE_MAP_CAUSE_THRASHING = 2, + + /** + * Mapping to remote memory was added to enforce the hints + * specified by the programmer or by performance heuristics of the + * UVM driver + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_REMOTE_MAP_CAUSE_POLICY = 3, + + /** + * Mapping to remote memory was added because there is no more + * memory available on the processor and eviction was not + * possible + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_REMOTE_MAP_CAUSE_OUT_OF_MEMORY = 4, + + /** + * Mapping to remote memory was added after the memory was + * evicted to make room for another block of memory on the GPU + */ + CUPTI_ACTIVITY_UNIFIED_MEMORY_REMOTE_MAP_CAUSE_EVICTION = 5; + +/** + * \brief SASS instruction classification. + * + * The sass instruction are broadly divided into different class. Each enum represents a classification. + */ +/** enum CUpti_ActivityInstructionClass */ +public static final int + /** + * The instruction class is not known. + */ + CUPTI_ACTIVITY_INSTRUCTION_CLASS_UNKNOWN = 0, + + /** + * Represents a 32 bit floating point operation. + */ + CUPTI_ACTIVITY_INSTRUCTION_CLASS_FP_32 = 1, + + /** + * Represents a 64 bit floating point operation. + */ + CUPTI_ACTIVITY_INSTRUCTION_CLASS_FP_64 = 2, + + /** + * Represents an integer operation. + */ + CUPTI_ACTIVITY_INSTRUCTION_CLASS_INTEGER = 3, + + /** + * Represents a bit conversion operation. + */ + CUPTI_ACTIVITY_INSTRUCTION_CLASS_BIT_CONVERSION = 4, + + /** + * Represents a control flow instruction. + */ + CUPTI_ACTIVITY_INSTRUCTION_CLASS_CONTROL_FLOW = 5, + + /** + * Represents a global load-store instruction. + */ + CUPTI_ACTIVITY_INSTRUCTION_CLASS_GLOBAL = 6, + + /** + * Represents a shared load-store instruction. + */ + CUPTI_ACTIVITY_INSTRUCTION_CLASS_SHARED = 7, + + /** + * Represents a local load-store instruction. + */ + CUPTI_ACTIVITY_INSTRUCTION_CLASS_LOCAL = 8, + + /** + * Represents a generic load-store instruction. + */ + CUPTI_ACTIVITY_INSTRUCTION_CLASS_GENERIC = 9, + + /** + * Represents a surface load-store instruction. + */ + CUPTI_ACTIVITY_INSTRUCTION_CLASS_SURFACE = 10, + + /** + * Represents a constant load instruction. + */ + CUPTI_ACTIVITY_INSTRUCTION_CLASS_CONSTANT = 11, + + /** + * Represents a texture load-store instruction. + */ + CUPTI_ACTIVITY_INSTRUCTION_CLASS_TEXTURE = 12, + + /** + * Represents a global atomic instruction. + */ + CUPTI_ACTIVITY_INSTRUCTION_CLASS_GLOBAL_ATOMIC = 13, + + /** + * Represents a shared atomic instruction. + */ + CUPTI_ACTIVITY_INSTRUCTION_CLASS_SHARED_ATOMIC = 14, + + /** + * Represents a surface atomic instruction. + */ + CUPTI_ACTIVITY_INSTRUCTION_CLASS_SURFACE_ATOMIC = 15, + + /** + * Represents a inter-thread communication instruction. + */ + CUPTI_ACTIVITY_INSTRUCTION_CLASS_INTER_THREAD_COMMUNICATION = 16, + + /** + * Represents a barrier instruction. + */ + CUPTI_ACTIVITY_INSTRUCTION_CLASS_BARRIER = 17, + + /** + * Represents some miscellaneous instructions which do not fit in the above classification. + */ + CUPTI_ACTIVITY_INSTRUCTION_CLASS_MISCELLANEOUS = 18, + + /** + * Represents a 16 bit floating point operation. + */ + CUPTI_ACTIVITY_INSTRUCTION_CLASS_FP_16 = 19, + + /** + * Represents uniform instruction. + */ + CUPTI_ACTIVITY_INSTRUCTION_CLASS_UNIFORM = 20, + + CUPTI_ACTIVITY_INSTRUCTION_CLASS_KIND_FORCE_INT = 0x7fffffff; + +/** + * \brief Partitioned global caching option + */ +/** enum CUpti_ActivityPartitionedGlobalCacheConfig */ +public static final int + /** + * Partitioned global cache config unknown. + */ + CUPTI_ACTIVITY_PARTITIONED_GLOBAL_CACHE_CONFIG_UNKNOWN = 0, + + /** + * Partitioned global cache not supported. + */ + CUPTI_ACTIVITY_PARTITIONED_GLOBAL_CACHE_CONFIG_NOT_SUPPORTED = 1, + + /** + * Partitioned global cache config off. + */ + CUPTI_ACTIVITY_PARTITIONED_GLOBAL_CACHE_CONFIG_OFF = 2, + + /** + * Partitioned global cache config on. + */ + CUPTI_ACTIVITY_PARTITIONED_GLOBAL_CACHE_CONFIG_ON = 3, + + CUPTI_ACTIVITY_PARTITIONED_GLOBAL_CACHE_CONFIG_FORCE_INT = 0x7fffffff; + +/** + * \brief Synchronization type. + * + * The types of synchronization to be used with CUpti_ActivitySynchronization. + */ + +/** enum CUpti_ActivitySynchronizationType */ +public static final int + /** + * Unknown data. + */ + CUPTI_ACTIVITY_SYNCHRONIZATION_TYPE_UNKNOWN = 0, + + /** + * Event synchronize API. + */ + CUPTI_ACTIVITY_SYNCHRONIZATION_TYPE_EVENT_SYNCHRONIZE = 1, + + /** + * Stream wait event API. + */ + CUPTI_ACTIVITY_SYNCHRONIZATION_TYPE_STREAM_WAIT_EVENT = 2, + + /** + * Stream synchronize API. + */ + CUPTI_ACTIVITY_SYNCHRONIZATION_TYPE_STREAM_SYNCHRONIZE = 3, + + /** + * Context synchronize API. + */ + CUPTI_ACTIVITY_SYNCHRONIZATION_TYPE_CONTEXT_SYNCHRONIZE = 4, + + CUPTI_ACTIVITY_SYNCHRONIZATION_TYPE_FORCE_INT = 0x7fffffff; + +/** + * \brief stream type. + * + * The types of stream to be used with CUpti_ActivityStream. + */ + +/** enum CUpti_ActivityStreamFlag */ +public static final int + /** + * Unknown data. + */ + CUPTI_ACTIVITY_STREAM_CREATE_FLAG_UNKNOWN = 0, + + /** + * Default stream. + */ + CUPTI_ACTIVITY_STREAM_CREATE_FLAG_DEFAULT = 1, + + /** + * Non-blocking stream. + */ + CUPTI_ACTIVITY_STREAM_CREATE_FLAG_NON_BLOCKING = 2, + + /** + * Null stream. + */ + CUPTI_ACTIVITY_STREAM_CREATE_FLAG_NULL = 3, + + /** + * Stream create Mask + */ + CUPTI_ACTIVITY_STREAM_CREATE_MASK = 0xFFFF, + + CUPTI_ACTIVITY_STREAM_CREATE_FLAG_FORCE_INT = 0x7fffffff; + +/** +* \brief Link flags. +* +* Describes link properties, to be used with CUpti_ActivityNvLink. +*/ + +/** enum CUpti_LinkFlag */ +public static final int + /** + * The flag is invalid. + */ + CUPTI_LINK_FLAG_INVALID = 0, + + /** + * Is peer to peer access supported by this link. + */ + CUPTI_LINK_FLAG_PEER_ACCESS = (1 << 1), + + /** + * Is system memory access supported by this link. + */ + CUPTI_LINK_FLAG_SYSMEM_ACCESS = (1 << 2), + + /** + * Is peer atomic access supported by this link. + */ + CUPTI_LINK_FLAG_PEER_ATOMICS = (1 << 3), + + /** + * Is system memory atomic access supported by this link. + */ + CUPTI_LINK_FLAG_SYSMEM_ATOMICS = (1 << 4), + + CUPTI_LINK_FLAG_FORCE_INT = 0x7fffffff; + +/** +* \brief Memory operation types. +* +* Describes the type of memory operation, to be used with CUpti_ActivityMemory4. +*/ + +/** enum CUpti_ActivityMemoryOperationType */ +public static final int + /** + * The operation is invalid. + */ + CUPTI_ACTIVITY_MEMORY_OPERATION_TYPE_INVALID = 0, + + /** + * Memory is allocated. + */ + CUPTI_ACTIVITY_MEMORY_OPERATION_TYPE_ALLOCATION = 1, + + /** + * Memory is released. + */ + CUPTI_ACTIVITY_MEMORY_OPERATION_TYPE_RELEASE = 2, + + CUPTI_ACTIVITY_MEMORY_OPERATION_TYPE_FORCE_INT = 0x7fffffff; + +/** +* \brief Memory pool types. +* +* Describes the type of memory pool, to be used with CUpti_ActivityMemory4. +*/ + +/** enum CUpti_ActivityMemoryPoolType */ +public static final int + /** + * The operation is invalid. + */ + CUPTI_ACTIVITY_MEMORY_POOL_TYPE_INVALID = 0, + + /** + * Memory pool is local to the process. + */ + CUPTI_ACTIVITY_MEMORY_POOL_TYPE_LOCAL = 1, + + /** + * Memory pool is imported by the process. + */ + CUPTI_ACTIVITY_MEMORY_POOL_TYPE_IMPORTED = 2, + + CUPTI_ACTIVITY_MEMORY_POOL_TYPE_FORCE_INT = 0x7fffffff; + +/** +* \brief Memory pool operation types. +* +* Describes the type of memory pool operation, to be used with CUpti_ActivityMemoryPool2. +*/ + +/** enum CUpti_ActivityMemoryPoolOperationType */ +public static final int + /** + * The operation is invalid. + */ + CUPTI_ACTIVITY_MEMORY_POOL_OPERATION_TYPE_INVALID = 0, + + /** + * Memory pool is created. + */ + CUPTI_ACTIVITY_MEMORY_POOL_OPERATION_TYPE_CREATED = 1, + + /** + * Memory pool is destroyed. + */ + CUPTI_ACTIVITY_MEMORY_POOL_OPERATION_TYPE_DESTROYED = 2, + + /** + * Memory pool is trimmed. + */ + CUPTI_ACTIVITY_MEMORY_POOL_OPERATION_TYPE_TRIMMED = 3, + + CUPTI_ACTIVITY_MEMORY_POOL_OPERATION_TYPE_FORCE_INT = 0x7fffffff; + +/** enum CUpti_ChannelType */ +public static final int + CUPTI_CHANNEL_TYPE_INVALID = 0, + + /** + * Channel is used for standard work launch and tracking + */ + CUPTI_CHANNEL_TYPE_COMPUTE = 1, + + /** + * Channel is used by an asynchronous copy engine + * For confidential compute configurations, work launch and + * completion are done using the copy engines. + */ + CUPTI_CHANNEL_TYPE_ASYNC_MEMCPY = 2, + + CUPTI_CHANNEL_TYPE_FORCE_INT = 0x7fffffff; + +/** +* \brief CIG (CUDA in Graphics) Modes. +* +* Describes the CIG modes associated with the CUDA context. +*/ + +/** enum CUpti_ContextCigMode */ +public static final int + /** + * Regular (non-CIG) mode + */ + CUPTI_CONTEXT_CIG_MODE_NONE = 0, + /** + * CIG mode + */ + CUPTI_CONTEXT_CIG_MODE_CIG = 1, + /** + * CIG fallback mode + */ + CUPTI_CONTEXT_CIG_MODE_CIG_FALLBACK = 2, + + CUPTI_CONTEXT_CIG_MODE_FORCE_INT = 0x7fffffff; + +/** + * The source-locator ID that indicates an unknown source + * location. There is not an actual CUpti_ActivitySourceLocator object + * corresponding to this value. + */ +public static final int CUPTI_SOURCE_LOCATOR_ID_UNKNOWN = 0; + +/** + * An invalid function index ID. + */ +public static final int CUPTI_FUNCTION_INDEX_ID_INVALID = 0; + +/** + * An invalid/unknown correlation ID. A correlation ID of this value + * indicates that there is no correlation for the activity record. + */ +public static final int CUPTI_CORRELATION_ID_UNKNOWN = 0; + +/** + * An invalid/unknown grid ID. + */ +public static final long CUPTI_GRID_ID_UNKNOWN = 0L; + +/** + * An invalid/unknown timestamp for a start, end, queued, submitted, + * or completed time. + */ +public static final long CUPTI_TIMESTAMP_UNKNOWN = 0L; + +/** + * An invalid/unknown value. + */ +public static final int CUPTI_SYNCHRONIZATION_INVALID_VALUE = -1; + +/** + * An invalid/unknown process id. + */ +public static final int CUPTI_AUTO_BOOST_INVALID_CLIENT_PID = 0; + +/** + * Invalid/unknown NVLink port number. +*/ +public static final int CUPTI_NVLINK_INVALID_PORT = -1; + +/** + * Maximum NVLink port numbers. +*/ +public static final int CUPTI_MAX_NVLINK_PORTS = 32; +// Targeting ../cupti/CUpti_ActivityUnifiedMemoryCounterConfig.java + + +// Targeting ../cupti/CUpti_ActivityAutoBoostState.java + + +// Targeting ../cupti/CUpti_ActivityPCSamplingConfig.java + + +// Targeting ../cupti/CUpti_Activity.java + + +// Targeting ../cupti/CUpti_ActivityMemcpy5.java + + +// Targeting ../cupti/CUpti_ActivityMemcpyPtoP4.java + + +// Targeting ../cupti/CUpti_ActivityMemset4.java + + +// Targeting ../cupti/CUpti_ActivityMemory.java + + +// Targeting ../cupti/CUpti_ActivityMemory4.java + + +// Targeting ../cupti/CUpti_ActivityMemoryPool2.java + + + +/** + * \brief The type of the CUDA kernel launch. + */ +/** enum CUpti_ActivityLaunchType */ +public static final int + /** + * The kernel was launched via a regular kernel call + */ + CUPTI_ACTIVITY_LAUNCH_TYPE_REGULAR = 0, + + /** + * The kernel was launched via API \ref cudaLaunchCooperativeKernel() or + * \ref cuLaunchCooperativeKernel() + */ + CUPTI_ACTIVITY_LAUNCH_TYPE_COOPERATIVE_SINGLE_DEVICE = 1, + + /** + * The kernel was launched via API \ref cudaLaunchCooperativeKernelMultiDevice() or + * \ref cuLaunchCooperativeKernelMultiDevice() + */ + CUPTI_ACTIVITY_LAUNCH_TYPE_COOPERATIVE_MULTI_DEVICE = 2, + + /** + * The kernel was launched as a CBL commandlist + */ + CUPTI_ACTIVITY_LAUNCH_TYPE_CBL_COMMANDLIST = 3; + +/** + * \brief The shared memory limit per block config for a kernel + * This should be used to set 'cudaOccFuncShmemConfig' field in occupancy calculator API + */ +/** enum CUpti_FuncShmemLimitConfig */ +public static final int + /** The shared memory limit config is default + */ + CUPTI_FUNC_SHMEM_LIMIT_DEFAULT = 0x00, + + /** User has opted for a higher dynamic shared memory limit using function attribute + * 'cudaFuncAttributeMaxDynamicSharedMemorySize' for runtime API or + * CU_FUNC_ATTRIBUTE_MAX_DYNAMIC_SHARED_SIZE_BYTES for driver API + */ + CUPTI_FUNC_SHMEM_LIMIT_OPTIN = 0x01, + + CUPTI_FUNC_SHMEM_LIMIT_FORCE_INT = 0x7fffffff; +// Targeting ../cupti/CUpti_ActivityKernel9.java + + +// Targeting ../cupti/CUpti_ActivityCdpKernel.java + + +// Targeting ../cupti/CUpti_ActivityPreemption.java + + +// Targeting ../cupti/CUpti_ActivityAPI.java + + +// Targeting ../cupti/CUpti_ActivityEvent.java + + +// Targeting ../cupti/CUpti_ActivityEventInstance.java + + +// Targeting ../cupti/CUpti_ActivityMetric.java + + +// Targeting ../cupti/CUpti_ActivityMetricInstance.java + + +// Targeting ../cupti/CUpti_ActivitySourceLocator.java + + +// Targeting ../cupti/CUpti_ActivityGlobalAccess3.java + + +// Targeting ../cupti/CUpti_ActivityBranch2.java + + +// Targeting ../cupti/CUpti_ActivityDevice5.java + + +// Targeting ../cupti/CUpti_ActivityDeviceAttribute.java + + +// Targeting ../cupti/CUpti_ActivityContext3.java + + +// Targeting ../cupti/CUpti_ActivityName.java + + +// Targeting ../cupti/CUpti_ActivityMarker2.java + + +// Targeting ../cupti/CUpti_ActivityMarkerData.java + + +// Targeting ../cupti/CUpti_ActivityOverhead3.java + + +// Targeting ../cupti/CUpti_ActivityEnvironment.java + + +// Targeting ../cupti/CUpti_ActivityInstructionExecution.java + + +// Targeting ../cupti/CUpti_ActivityPCSampling3.java + + +// Targeting ../cupti/CUpti_ActivityPCSamplingRecordInfo.java + + +// Targeting ../cupti/CUpti_ActivityUnifiedMemoryCounter2.java + + +// Targeting ../cupti/CUpti_ActivityFunction.java + + +// Targeting ../cupti/CUpti_ActivityModule.java + + +// Targeting ../cupti/CUpti_ActivitySharedAccess.java + + +// Targeting ../cupti/CUpti_ActivityCudaEvent.java + + +// Targeting ../cupti/CUpti_ActivityStream.java + + +// Targeting ../cupti/CUpti_ActivitySynchronization.java + + +// Targeting ../cupti/CUpti_ActivityInstructionCorrelation.java + + + +/** + * \brief The OpenAcc event kind for OpenAcc activity records. + * + * @see CUpti_ActivityKindOpenAcc + */ +/** enum CUpti_OpenAccEventKind */ +public static final int + CUPTI_OPENACC_EVENT_KIND_INVALID = 0, + CUPTI_OPENACC_EVENT_KIND_DEVICE_INIT = 1, + CUPTI_OPENACC_EVENT_KIND_DEVICE_SHUTDOWN = 2, + CUPTI_OPENACC_EVENT_KIND_RUNTIME_SHUTDOWN = 3, + CUPTI_OPENACC_EVENT_KIND_ENQUEUE_LAUNCH = 4, + CUPTI_OPENACC_EVENT_KIND_ENQUEUE_UPLOAD = 5, + CUPTI_OPENACC_EVENT_KIND_ENQUEUE_DOWNLOAD = 6, + CUPTI_OPENACC_EVENT_KIND_WAIT = 7, + CUPTI_OPENACC_EVENT_KIND_IMPLICIT_WAIT = 8, + CUPTI_OPENACC_EVENT_KIND_COMPUTE_CONSTRUCT = 9, + CUPTI_OPENACC_EVENT_KIND_UPDATE = 10, + CUPTI_OPENACC_EVENT_KIND_ENTER_DATA = 11, + CUPTI_OPENACC_EVENT_KIND_EXIT_DATA = 12, + CUPTI_OPENACC_EVENT_KIND_CREATE = 13, + CUPTI_OPENACC_EVENT_KIND_DELETE = 14, + CUPTI_OPENACC_EVENT_KIND_ALLOC = 15, + CUPTI_OPENACC_EVENT_KIND_FREE = 16, + CUPTI_OPENACC_EVENT_KIND_FORCE_INT = 0x7fffffff; + +/** + * \brief The OpenAcc parent construct kind for OpenAcc activity records. + */ +/** enum CUpti_OpenAccConstructKind */ +public static final int + CUPTI_OPENACC_CONSTRUCT_KIND_UNKNOWN = 0, + CUPTI_OPENACC_CONSTRUCT_KIND_PARALLEL = 1, + CUPTI_OPENACC_CONSTRUCT_KIND_KERNELS = 2, + CUPTI_OPENACC_CONSTRUCT_KIND_LOOP = 3, + CUPTI_OPENACC_CONSTRUCT_KIND_DATA = 4, + CUPTI_OPENACC_CONSTRUCT_KIND_ENTER_DATA = 5, + CUPTI_OPENACC_CONSTRUCT_KIND_EXIT_DATA = 6, + CUPTI_OPENACC_CONSTRUCT_KIND_HOST_DATA = 7, + CUPTI_OPENACC_CONSTRUCT_KIND_ATOMIC = 8, + CUPTI_OPENACC_CONSTRUCT_KIND_DECLARE = 9, + CUPTI_OPENACC_CONSTRUCT_KIND_INIT = 10, + CUPTI_OPENACC_CONSTRUCT_KIND_SHUTDOWN = 11, + CUPTI_OPENACC_CONSTRUCT_KIND_SET = 12, + CUPTI_OPENACC_CONSTRUCT_KIND_UPDATE = 13, + CUPTI_OPENACC_CONSTRUCT_KIND_ROUTINE = 14, + CUPTI_OPENACC_CONSTRUCT_KIND_WAIT = 15, + CUPTI_OPENACC_CONSTRUCT_KIND_RUNTIME_API = 16, + CUPTI_OPENACC_CONSTRUCT_KIND_FORCE_INT = 0x7fffffff; + +/** enum CUpti_OpenMpEventKind */ +public static final int + CUPTI_OPENMP_EVENT_KIND_INVALID = 0, + CUPTI_OPENMP_EVENT_KIND_PARALLEL = 1, + CUPTI_OPENMP_EVENT_KIND_TASK = 2, + CUPTI_OPENMP_EVENT_KIND_THREAD = 3, + CUPTI_OPENMP_EVENT_KIND_IDLE = 4, + CUPTI_OPENMP_EVENT_KIND_WAIT_BARRIER = 5, + CUPTI_OPENMP_EVENT_KIND_WAIT_TASKWAIT = 6, + CUPTI_OPENMP_EVENT_KIND_FORCE_INT = 0x7fffffff; +// Targeting ../cupti/CUpti_ActivityOpenAcc.java + + +// Targeting ../cupti/CUpti_ActivityOpenAccData.java + + +// Targeting ../cupti/CUpti_ActivityOpenAccLaunch.java + + +// Targeting ../cupti/CUpti_ActivityOpenAccOther.java + + +// Targeting ../cupti/CUpti_ActivityOpenMp.java + + + +/** + * \brief The kind of external APIs supported for correlation. + * + * Custom correlation kinds are reserved for usage in external tools. + * + * @see CUpti_ActivityExternalCorrelation + */ +/** enum CUpti_ExternalCorrelationKind */ +public static final int + CUPTI_EXTERNAL_CORRELATION_KIND_INVALID = 0, + + /** + * The external API is unknown to CUPTI + */ + CUPTI_EXTERNAL_CORRELATION_KIND_UNKNOWN = 1, + + /** + * The external API is OpenACC + */ + CUPTI_EXTERNAL_CORRELATION_KIND_OPENACC = 2, + + /** + * The external API is custom0 + */ + CUPTI_EXTERNAL_CORRELATION_KIND_CUSTOM0 = 3, + + /** + * The external API is custom1 + */ + CUPTI_EXTERNAL_CORRELATION_KIND_CUSTOM1 = 4, + + /** + * The external API is custom2 + */ + CUPTI_EXTERNAL_CORRELATION_KIND_CUSTOM2 = 5, + + /** + * Add new kinds before this line + */ + CUPTI_EXTERNAL_CORRELATION_KIND_SIZE = 6, + + CUPTI_EXTERNAL_CORRELATION_KIND_FORCE_INT = 0x7fffffff; +// Targeting ../cupti/CUpti_ActivityExternalCorrelation.java + + + +/** +* \brief The device type for device connected to NVLink. +*/ +/** enum CUpti_DevType */ +public static final int + CUPTI_DEV_TYPE_INVALID = 0, + + /** + * The device type is GPU. + */ + CUPTI_DEV_TYPE_GPU = 1, + + /** + * The device type is NVLink processing unit in CPU. + */ + CUPTI_DEV_TYPE_NPU = 2, + + CUPTI_DEV_TYPE_FORCE_INT = 0x7fffffff; +// Targeting ../cupti/CUpti_ActivityNvLink4.java + + + +public static final int CUPTI_MAX_GPUS = 32; +/** + * Field to differentiate whether PCIE Activity record + * is of a GPU or a PCI Bridge + */ +/** enum CUpti_PcieDeviceType */ +public static final int + /** + * PCIE GPU record + */ + CUPTI_PCIE_DEVICE_TYPE_GPU = 0, + + /** + * PCIE Bridge record + */ + CUPTI_PCIE_DEVICE_TYPE_BRIDGE = 1, + + CUPTI_PCIE_DEVICE_TYPE_FORCE_INT = 0x7fffffff; +// Targeting ../cupti/CUpti_ActivityPcie.java + + + +/** + * \brief PCIE Generation. + * + * Enumeration of PCIE Generation for + * pcie activity attribute pcieGeneration + */ +/** enum CUpti_PcieGen */ +public static final int + /** + * PCIE Generation 1 + */ + CUPTI_PCIE_GEN_GEN1 = 1, + + /** + * PCIE Generation 2 + */ + CUPTI_PCIE_GEN_GEN2 = 2, + + /** + * PCIE Generation 3 + */ + CUPTI_PCIE_GEN_GEN3 = 3, + + /** + * PCIE Generation 4 + */ + CUPTI_PCIE_GEN_GEN4 = 4, + + /** + * PCIE Generation 5 + */ + CUPTI_PCIE_GEN_GEN5 = 5, + + CUPTI_PCIE_GEN_FORCE_INT = 0x7fffffff; +// Targeting ../cupti/CUpti_ActivityInstantaneousEvent.java + + +// Targeting ../cupti/CUpti_ActivityInstantaneousEventInstance.java + + +// Targeting ../cupti/CUpti_ActivityInstantaneousMetric.java + + +// Targeting ../cupti/CUpti_ActivityInstantaneousMetricInstance.java + + + +/** + * \brief The types of JIT entry. + * + * To be used in CUpti_ActivityJit. + */ +/** enum CUpti_ActivityJitEntryType */ +public static final int + CUPTI_ACTIVITY_JIT_ENTRY_INVALID = 0, + + /** + * PTX to CUBIN. + */ + CUPTI_ACTIVITY_JIT_ENTRY_PTX_TO_CUBIN = 1, + + /** + * NVVM-IR to PTX + */ + CUPTI_ACTIVITY_JIT_ENTRY_NVVM_IR_TO_PTX = 2, + + CUPTI_ACTIVITY_JIT_ENTRY_TYPE_FORCE_INT = 0x7fffffff; + +/** + * \brief The types of JIT compilation operations. + * + * To be used in CUpti_ActivityJit. + */ + +/** enum CUpti_ActivityJitOperationType */ +public static final int + CUPTI_ACTIVITY_JIT_OPERATION_INVALID = 0, + /** + * Loaded from the compute cache. + */ + CUPTI_ACTIVITY_JIT_OPERATION_CACHE_LOAD = 1, + + /** + * Stored in the compute cache. + */ + CUPTI_ACTIVITY_JIT_OPERATION_CACHE_STORE = 2, + + /** + * JIT compilation. + */ + CUPTI_ACTIVITY_JIT_OPERATION_COMPILE = 3, + + CUPTI_ACTIVITY_JIT_OPERATION_TYPE_FORCE_INT = 0x7fffffff; +// Targeting ../cupti/CUpti_ActivityJit2.java + + +// Targeting ../cupti/CUpti_ActivityGraphTrace2.java + + + +/** enum CUpti_ActivityAttribute */ +public static final int + /** + * The device memory size (in bytes) reserved for storing profiling data for concurrent + * kernels (activity kind \ref CUPTI_ACTIVITY_KIND_CONCURRENT_KERNEL), memcopies and memsets + * for each buffer on a context. The value is a size_t. + * + * There is a limit on how many device buffers can be allocated per context. User + * can query and set this limit using the attribute + * \ref CUPTI_ACTIVITY_ATTR_DEVICE_BUFFER_POOL_LIMIT. + * CUPTI doesn't pre-allocate all the buffers, it pre-allocates only those many + * buffers as set by the attribute \ref CUPTI_ACTIVITY_ATTR_DEVICE_BUFFER_PRE_ALLOCATE_VALUE. + * When all of the data in a buffer is consumed, it is added in the reuse pool, and + * CUPTI picks a buffer from this pool when a new buffer is needed. Thus memory + * footprint does not scale with the kernel count. Applications with the high density + * of kernels, memcopies and memsets might result in having CUPTI to allocate more device buffers. + * CUPTI allocates another buffer only when it runs out of the buffers in the + * reuse pool. + * + * Since buffer allocation happens in the main application thread, this might result + * in stalls in the critical path. CUPTI pre-allocates 3 buffers of the same size to + * mitigate this issue. User can query and set the pre-allocation limit using the + * attribute \ref CUPTI_ACTIVITY_ATTR_DEVICE_BUFFER_PRE_ALLOCATE_VALUE. + * + * Having larger buffer size leaves less device memory for the application. + * Having smaller buffer size increases the risk of dropping timestamps for + * records if too many kernels or memcopies or memsets are launched at one time. + * + * This value only applies to new buffer allocations. Set this value before initializing + * CUDA or before creating a context to ensure it is considered for the following allocations. + * + * The default value is 3200000 (~3MB) which can accommodate profiling data + * up to 100,000 kernels, memcopies and memsets combined. + * + * Note: Starting with the CUDA 12.0 Update 1 release, CUPTI allocates profiling buffer in the + * device memory by default as this might help in improving the performance of the + * tracing run. Refer to the description of the attribute + * \ref CUPTI_ACTIVITY_ATTR_MEM_ALLOCATION_TYPE_HOST_PINNED for more details. + * Size of the memory and maximum number of pools are still controlled by the attributes + * \ref CUPTI_ACTIVITY_ATTR_DEVICE_BUFFER_SIZE and \ref CUPTI_ACTIVITY_ATTR_DEVICE_BUFFER_POOL_LIMIT. + * + * Note: The actual amount of device memory per buffer reserved by CUPTI might be larger. + */ + CUPTI_ACTIVITY_ATTR_DEVICE_BUFFER_SIZE = 0, + + /** + * The device memory size (in bytes) reserved for storing profiling + * data for CDP operations for each buffer on a context. The + * value is a size_t. + * + * Having larger buffer size means less flush operations but + * consumes more device memory. This value only applies to new + * allocations. + * + * Set this value before initializing CUDA or before creating a + * context to ensure it is considered for the following allocations. + * + * The default value is 8388608 (8MB). + * + * Note: The actual amount of device memory per context reserved by + * CUPTI might be larger. + */ + CUPTI_ACTIVITY_ATTR_DEVICE_BUFFER_SIZE_CDP = 1, + + /** + * The maximum number of device memory buffers per context. The value is a size_t. + * + * For an application with high rate of kernel launches, memcopies and memsets having a bigger pool + * limit helps in timestamp collection for all these activities at the expense of a larger memory footprint. + * Refer to the description of the attribute \ref CUPTI_ACTIVITY_ATTR_DEVICE_BUFFER_SIZE + * for more details. + * + * Setting this value will not modify the number of memory buffers + * currently stored. + * + * Set this value before initializing CUDA to ensure the limit is + * not exceeded. + * + * The default value is 250. + */ + CUPTI_ACTIVITY_ATTR_DEVICE_BUFFER_POOL_LIMIT = 2, + + /** + * This attribute is not supported starting with CUDA 12.3 + * CUPTI no longer uses profiling semaphore pool to store profiling data. + * + * There is a limit on how many semaphore pools can be allocated per context. User + * can query and set this limit using the attribute + * \ref CUPTI_ACTIVITY_ATTR_PROFILING_SEMAPHORE_POOL_LIMIT. + * CUPTI doesn't pre-allocate all the semaphore pools, it pre-allocates only those many + * semaphore pools as set by the attribute \ref CUPTI_ACTIVITY_ATTR_PROFILING_SEMAPHORE_PRE_ALLOCATE_VALUE. + * When all of the data in a semaphore pool is consumed, it is added in the reuse pool, and + * CUPTI picks a semaphore pool from the reuse pool when a new semaphore pool is needed. Thus memory + * footprint does not scale with the kernel count. Applications with the high density + * of kernels might result in having CUPTI to allocate more semaphore pools. + * CUPTI allocates another semaphore pool only when it runs out of the semaphore pools in the + * reuse pool. + * + * Since semaphore pool allocation happens in the main application thread, this might result + * in stalls in the critical path. CUPTI pre-allocates 3 semaphore pools of the same size to + * mitigate this issue. User can query and set the pre-allocation limit using the + * attribute \ref CUPTI_ACTIVITY_ATTR_PROFILING_SEMAPHORE_PRE_ALLOCATE_VALUE. + * + * Having larger semaphore pool size leaves less device memory for the application. + * Having smaller semaphore pool size increases the risk of dropping timestamps for + * kernel records if too many kernels are issued/launched at one time. + * + * This value only applies to new semaphore pool allocations. Set this value before initializing + * CUDA or before creating a context to ensure it is considered for the following allocations. + * + * The default value is 25000 which can accommodate profiling data for upto 25,000 kernels. + * + */ + CUPTI_ACTIVITY_ATTR_PROFILING_SEMAPHORE_POOL_SIZE = 3, + + /** + * This attribute is not supported starting with CUDA 12.3 + * CUPTI no longer uses profiling semaphore pool to store profiling data. + * + * The maximum number of profiling semaphore pools per context. The value is a size_t. + * + * Refer to the description of the attribute \ref CUPTI_ACTIVITY_ATTR_PROFILING_SEMAPHORE_POOL_SIZE + * for more details. + * + * Set this value before initializing CUDA to ensure the limit is not exceeded. + * + * The default value is 250. + */ + CUPTI_ACTIVITY_ATTR_PROFILING_SEMAPHORE_POOL_LIMIT = 4, + + /** + * The flag to indicate whether user should provide activity buffer of zero value. + * The value is a uint8_t. + * + * If the value of this attribute is non-zero, user should provide + * a zero value buffer in the \ref CUpti_BuffersCallbackRequestFunc. + * If the user does not provide a zero value buffer after setting this to non-zero, + * the activity buffer may contain some uninitialized values when CUPTI returns it in + * \ref CUpti_BuffersCallbackCompleteFunc + * + * If the value of this attribute is zero, CUPTI will initialize the user buffer + * received in the \ref CUpti_BuffersCallbackRequestFunc to zero before filling it. + * If the user sets this to zero, a few stalls may appear in critical path because CUPTI + * will zero out the buffer in the main thread. + * Set this value before returning from \ref CUpti_BuffersCallbackRequestFunc to + * ensure it is considered for all the subsequent user buffers. + * + * The default value is 0. + */ + CUPTI_ACTIVITY_ATTR_ZEROED_OUT_ACTIVITY_BUFFER = 5, + + /** + * Number of device buffers to pre-allocate for a context during the initialization phase. + * The value is a size_t. + * + * Refer to the description of the attribute \ref CUPTI_ACTIVITY_ATTR_DEVICE_BUFFER_SIZE + * for details. + * + * This value must be less than the maximum number of device buffers set using + * the attribute \ref CUPTI_ACTIVITY_ATTR_DEVICE_BUFFER_POOL_LIMIT + * + * Set this value before initializing CUDA or before creating a context to ensure it + * is considered by the CUPTI. + * + * The default value is set to 3 to ping pong between these buffers (if possible). + */ + CUPTI_ACTIVITY_ATTR_DEVICE_BUFFER_PRE_ALLOCATE_VALUE = 6, + + /** + * This attribute is not supported starting with CUDA 12.3 + * CUPTI no longer uses profiling semaphore pool to store profiling data. + * + * Number of profiling semaphore pools to pre-allocate for a context during the + * initialization phase. The value is a size_t. + * + * Refer to the description of the attribute \ref CUPTI_ACTIVITY_ATTR_PROFILING_SEMAPHORE_POOL_SIZE + * for details. + * + * This value must be less than the maximum number of profiling semaphore pools set + * using the attribute \ref CUPTI_ACTIVITY_ATTR_PROFILING_SEMAPHORE_POOL_LIMIT + * + * Set this value before initializing CUDA or before creating a context to ensure it + * is considered by the CUPTI. + * + * The default value is set to 3 to ping pong between these pools (if possible). + */ + CUPTI_ACTIVITY_ATTR_PROFILING_SEMAPHORE_PRE_ALLOCATE_VALUE = 7, + + /** + * Allocate page-locked (pinned) host memory for storing profiling data for concurrent + * kernels, memcopies and memsets for each buffer on a context. The value is a uint8_t. + * + * Starting with the CUDA 11.2 release, CUPTI allocates profiling buffer in the pinned host + * memory by default as this might help in improving the performance of the tracing run. + * Allocating excessive amounts of pinned memory may degrade system performance, since it + * reduces the amount of memory available to the system for paging. For this reason user + * might want to change the location from pinned host memory to device memory by setting + * value of this attribute to 0. + * + * Using page-locked (pinned) host memory buffers is not supported on confidential computing + * devices. On setting this attribute to 1, CUPTI will return CUPTI_ERROR_NOT_SUPPORTED. + * + * The default value is 1. + */ + CUPTI_ACTIVITY_ATTR_MEM_ALLOCATION_TYPE_HOST_PINNED = 8, + + /** + * Request activity buffers per-thread to store CUPTI activity records + * in the activity buffer on per-thread basis. The value is a uint8_t. + * + * The attribute should be set before registering the buffer callbacks using + * cuptiActivityRegisterCallbacks API and before any of the CUPTI activity kinds are enabled. + * This makes sure that all the records are stored in activity buffers allocated per-thread. + * Changing this attribute in the middle of the profiling session will result in undefined behavior. + * + * The default value is 0. + */ + CUPTI_ACTIVITY_ATTR_PER_THREAD_ACTIVITY_BUFFER = 9, + + + + CUPTI_ACTIVITY_ATTR_DEVICE_BUFFER_FORCE_INT = 0x7fffffff; + +/** + * \brief Thread-Id types. + * + * CUPTI uses different methods to obtain the thread-id depending on the + * support and the underlying platform. This enum documents these methods + * for each type. APIs \ref cuptiSetThreadIdType and \ref cuptiGetThreadIdType + * can be used to set and get the thread-id type. + */ +/** enum CUpti_ActivityThreadIdType */ +public static final int + /** + * Default type + * Windows uses API GetCurrentThreadId() + * Linux/Mac/Android/QNX use POSIX pthread API pthread_self() + */ + CUPTI_ACTIVITY_THREAD_ID_TYPE_DEFAULT = 0, + + /** + * This type is based on the system API available on the underlying platform + * and thread-id obtained is supposed to be unique for the process lifetime. + * Windows uses API GetCurrentThreadId() + * Linux uses syscall SYS_gettid + * Mac uses syscall SYS_thread_selfid + * Android/QNX use gettid() + */ + CUPTI_ACTIVITY_THREAD_ID_TYPE_SYSTEM = 1, + + /** + * Add new enums before this field. + */ + CUPTI_ACTIVITY_THREAD_ID_TYPE_SIZE = 2, + + CUPTI_ACTIVITY_THREAD_ID_TYPE_FORCE_INT = 0x7fffffff; + +/** + * \brief Get the CUPTI timestamp. + * + * Returns a timestamp normalized to correspond with the start and end + * timestamps reported in the CUPTI activity records. The timestamp is + * reported in nanoseconds. + * + * @param timestamp Returns the CUPTI timestamp + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p timestamp is NULL + */ +public static native @Cast("CUptiResult") int cuptiGetTimestamp(@Cast("uint64_t*") LongPointer timestamp); +public static native @Cast("CUptiResult") int cuptiGetTimestamp(@Cast("uint64_t*") LongBuffer timestamp); +public static native @Cast("CUptiResult") int cuptiGetTimestamp(@Cast("uint64_t*") long[] timestamp); + +/** + * \brief Get the ID of a context. + * + * Get the ID of a context. + * + * @param context The context + * @param contextId Returns a process-unique ID for the context + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_CONTEXT The context is NULL or not valid. + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p contextId is NULL + */ +public static native @Cast("CUptiResult") int cuptiGetContextId(CUctx_st context, @Cast("uint32_t*") IntPointer contextId); +public static native @Cast("CUptiResult") int cuptiGetContextId(CUctx_st context, @Cast("uint32_t*") IntBuffer contextId); +public static native @Cast("CUptiResult") int cuptiGetContextId(CUctx_st context, @Cast("uint32_t*") int[] contextId); + +/** + * \brief Get the ID of a stream. + * + * Get the ID of a stream. The stream ID is unique within a context + * (i.e. all streams within a context will have unique stream + * IDs). + * + * @param context If non-NULL then the stream is checked to ensure + * that it belongs to this context. Typically this parameter should be + * null. + * @param stream The stream + * @param streamId Returns a context-unique ID for the stream + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_STREAM if unable to get stream ID, or + * if \p context is non-NULL and \p stream does not belong to the + * context + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p streamId is NULL + * + * **DEPRECATED** This method is deprecated as of CUDA 8.0. + * Use method cuptiGetStreamIdEx instead. + */ +public static native @Cast("CUptiResult") int cuptiGetStreamId(CUctx_st context, CUstream_st stream, @Cast("uint32_t*") IntPointer streamId); +public static native @Cast("CUptiResult") int cuptiGetStreamId(CUctx_st context, CUstream_st stream, @Cast("uint32_t*") IntBuffer streamId); +public static native @Cast("CUptiResult") int cuptiGetStreamId(CUctx_st context, CUstream_st stream, @Cast("uint32_t*") int[] streamId); + +/** +* \brief Get the ID of a stream. +* +* Get the ID of a stream. The stream ID is unique within a context +* (i.e. all streams within a context will have unique stream +* IDs). +* +* @param context If non-NULL then the stream is checked to ensure +* that it belongs to this context. Typically this parameter should be +* null. +* @param stream The stream +* @param perThreadStream Flag to indicate if program is compiled for per-thread streams +* @param streamId Returns a context-unique ID for the stream +* +* \retval CUPTI_SUCCESS +* \retval CUPTI_ERROR_NOT_INITIALIZED +* \retval CUPTI_ERROR_INVALID_STREAM if unable to get stream ID, or +* if \p context is non-NULL and \p stream does not belong to the +* context +* \retval CUPTI_ERROR_INVALID_PARAMETER if \p streamId is NULL +*/ +public static native @Cast("CUptiResult") int cuptiGetStreamIdEx(CUctx_st context, CUstream_st stream, @Cast("uint8_t") byte perThreadStream, @Cast("uint32_t*") IntPointer streamId); +public static native @Cast("CUptiResult") int cuptiGetStreamIdEx(CUctx_st context, CUstream_st stream, @Cast("uint8_t") byte perThreadStream, @Cast("uint32_t*") IntBuffer streamId); +public static native @Cast("CUptiResult") int cuptiGetStreamIdEx(CUctx_st context, CUstream_st stream, @Cast("uint8_t") byte perThreadStream, @Cast("uint32_t*") int[] streamId); + +/** + * \brief Get the ID of a device + * + * If \p context is NULL, returns the ID of the device that contains + * the currently active context. If \p context is non-NULL, returns + * the ID of the device which contains that context. Operates in a + * similar manner to cudaGetDevice() or cuCtxGetDevice() but may be + * called from within callback functions. + * + * @param context The context, or NULL to indicate the current context. + * @param deviceId Returns the ID of the device that is current for + * the calling thread. + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_DEVICE if unable to get device ID + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p deviceId is NULL + */ +public static native @Cast("CUptiResult") int cuptiGetDeviceId(CUctx_st context, @Cast("uint32_t*") IntPointer deviceId); +public static native @Cast("CUptiResult") int cuptiGetDeviceId(CUctx_st context, @Cast("uint32_t*") IntBuffer deviceId); +public static native @Cast("CUptiResult") int cuptiGetDeviceId(CUctx_st context, @Cast("uint32_t*") int[] deviceId); + +/** + * \brief Get the unique ID of a graph node + * + * Returns the unique ID of the CUDA graph node. + * + * @param node The graph node. + * @param nodeId Returns the unique ID of the node + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p node is NULL + */ +public static native @Cast("CUptiResult") int cuptiGetGraphNodeId(CUgraphNode_st node, @Cast("uint64_t*") LongPointer nodeId); +public static native @Cast("CUptiResult") int cuptiGetGraphNodeId(CUgraphNode_st node, @Cast("uint64_t*") LongBuffer nodeId); +public static native @Cast("CUptiResult") int cuptiGetGraphNodeId(CUgraphNode_st node, @Cast("uint64_t*") long[] nodeId); + +/** + * \brief Get the unique ID of graph + * + * Returns the unique ID of CUDA graph. + * + * @param graph The graph. + * @param pId Returns the unique ID of the graph + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p graph is NULL + */ +public static native @Cast("CUptiResult") int cuptiGetGraphId(CUgraph_st graph, @Cast("uint32_t*") IntPointer pId); +public static native @Cast("CUptiResult") int cuptiGetGraphId(CUgraph_st graph, @Cast("uint32_t*") IntBuffer pId); +public static native @Cast("CUptiResult") int cuptiGetGraphId(CUgraph_st graph, @Cast("uint32_t*") int[] pId); + +/** + * \brief Get the unique ID of executable graph + * + * Returns the unique ID of executable CUDA graph. + * + * @param graphExec The executable graph. + * @param pId Returns the unique ID of the executable graph + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p graph is NULL + */ +public static native @Cast("CUptiResult") int cuptiGetGraphExecId(CUgraphExec_st graphExec, @Cast("uint32_t*") IntPointer pId); +public static native @Cast("CUptiResult") int cuptiGetGraphExecId(CUgraphExec_st graphExec, @Cast("uint32_t*") IntBuffer pId); +public static native @Cast("CUptiResult") int cuptiGetGraphExecId(CUgraphExec_st graphExec, @Cast("uint32_t*") int[] pId); + +/** + * \brief Enable collection of a specific kind of activity record. + * + * Enable collection of a specific kind of activity record. Multiple + * kinds can be enabled by calling this function multiple times. By + * default all activity kinds are disabled for collection. + * + * @param kind The kind of activity record to collect + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_NOT_COMPATIBLE if the activity kind cannot be enabled + * \retval CUPTI_ERROR_INVALID_KIND if the activity kind is not supported + */ +public static native @Cast("CUptiResult") int cuptiActivityEnable(@Cast("CUpti_ActivityKind") int kind); + +/** + * \brief Enable collection of a specific kind of activity record. For certain activity kinds + * it dumps existing records. + * + * In general, the behavior of this API is similar to the API \ref cuptiActivityEnable i.e. it + * enables the collection of a specific kind of activity record. + * Additionally, this API can help in dumping the records for activities which happened in + * the past before enabling the corresponding activity kind. + * The API allows to get records for the current resource allocations done in CUDA + * For CUPTI_ACTIVITY_KIND_DEVICE, existing device records are dumped + * For CUPTI_ACTIVITY_KIND_CONTEXT, existing context records are dumped + * For CUPTI_ACTIVITY_KIND_STREAM, existing stream records are dumped + * For CUPTI_ACTIVITY_KIND_ NVLINK, existing NVLINK records are dumped + * For CUPTI_ACTIVITY_KIND_PCIE, existing PCIE records are dumped + * For other activities, the behavior is similar to the API \ref cuptiActivityEnable + * + * Device records are emitted in CUPTI on CUDA driver initialization. Those records + * can only be retrieved by the user if CUPTI is attached before CUDA initialization. + * Context and stream records are emitted on context and stream creation. + * The use case of the API is to provide the records for CUDA resources + * (contexts/streams/devices) that are currently active if user late attaches CUPTI. + * + * Before calling this function, the user must register buffer callbacks + * to get the activity records by calling \ref cuptiActivityRegisterCallbacks. + * If the user does not register the buffers and calls API \ref cuptiActivityEnableAndDump, + * then CUPTI will enable the activity kind but not provide any records for that + * activity kind. + * + * @param kind The kind of activity record to collect + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_UNKNOWN if buffer is not initialized. + * \retval CUPTI_ERROR_NOT_COMPATIBLE if the activity kind cannot be enabled + * \retval CUPTI_ERROR_INVALID_KIND if the activity kind is not supported + */ +public static native @Cast("CUptiResult") int cuptiActivityEnableAndDump(@Cast("CUpti_ActivityKind") int kind); + +/** + * \brief Disable collection of a specific kind of activity record. + * + * Disable collection of a specific kind of activity record. Multiple + * kinds can be disabled by calling this function multiple times. By + * default all activity kinds are disabled for collection. + * + * @param kind The kind of activity record to stop collecting + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_KIND if the activity kind is not supported + */ +public static native @Cast("CUptiResult") int cuptiActivityDisable(@Cast("CUpti_ActivityKind") int kind); + +/** + * \brief Enable collection of a specific kind of activity record for + * a context. + * + * Enable collection of a specific kind of activity record for a + * context. This setting done by this API will supersede the global + * settings for activity records enabled by \ref cuptiActivityEnable. + * Multiple kinds can be enabled by calling this function multiple + * times. + * + * @param context The context for which activity is to be enabled + * @param kind The kind of activity record to collect + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_NOT_COMPATIBLE if the activity kind cannot be enabled + * \retval CUPTI_ERROR_INVALID_KIND if the activity kind is not supported + */ +public static native @Cast("CUptiResult") int cuptiActivityEnableContext(CUctx_st context, @Cast("CUpti_ActivityKind") int kind); + +/** + * \brief Disable collection of a specific kind of activity record for + * a context. + * + * Disable collection of a specific kind of activity record for a context. + * This setting done by this API will supersede the global settings + * for activity records. + * Multiple kinds can be enabled by calling this function multiple times. + * + * @param context The context for which activity is to be disabled + * @param kind The kind of activity record to stop collecting + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_KIND if the activity kind is not supported + */ +public static native @Cast("CUptiResult") int cuptiActivityDisableContext(CUctx_st context, @Cast("CUpti_ActivityKind") int kind); + +/** + * \brief Get the number of activity records that were dropped of + * insufficient buffer space. + * + * Get the number of records that were dropped because of insufficient + * buffer space. The dropped count includes records that could not be + * recorded because CUPTI did not have activity buffer space available + * for the record (because the CUpti_BuffersCallbackRequestFunc + * callback did not return an empty buffer of sufficient size) and + * also CDP records that could not be record because the device-size + * buffer was full (size is controlled by the + * CUPTI_ACTIVITY_ATTR_DEVICE_BUFFER_SIZE_CDP attribute). The dropped + * count maintained for the queue is reset to zero when this function + * is called. + * + * @param context The context, or NULL to get dropped count from global queue + * @param streamId The stream ID + * @param dropped The number of records that were dropped since the last call + * to this function. + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p dropped is NULL + */ +public static native @Cast("CUptiResult") int cuptiActivityGetNumDroppedRecords(CUctx_st context, @Cast("uint32_t") int streamId, + @Cast("size_t*") SizeTPointer dropped); + +/** + * \brief Iterate over the activity records in a buffer. + * + * This is a helper function to iterate over the activity records in a + * buffer. A buffer of activity records is typically obtained by + * receiving a CUpti_BuffersCallbackCompleteFunc callback. Stop iterating + * the buffer when an error occurs. + * + * An example of typical usage: + *

{@code
+ * CUpti_Activity *record = NULL;
+ * CUptiResult status = CUPTI_SUCCESS;
+ *   do {
+ *      status = cuptiActivityGetNextRecord(buffer, validSize, &record);
+ *      if(status == CUPTI_SUCCESS) {
+ *           // Use record here...
+ *      }
+ *      else if (status == CUPTI_ERROR_MAX_LIMIT_REACHED)
+ *          break;
+ *      else if (status == CUPTI_ERROR_INVALID_KIND)
+ *          break;
+ *      else {
+ *          goto Error;
+ *      }
+ *    } while (1);
+ * }
+ * + * @param buffer The buffer containing activity records + * @param record Inputs the previous record returned by + * cuptiActivityGetNextRecord and returns the next activity record + * from the buffer. If input value is NULL, returns the first activity + * record in the buffer. Records of certain kinds like CUPTI_ACTIVITY_KIND_CONCURRENT_KERNEL + * may contain invalid (0) timestamps, indicating that no timing information could + * be collected for lack of device memory. + * @param validBufferSizeBytes The number of valid bytes in the buffer. + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_MAX_LIMIT_REACHED if no more records in the buffer + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p buffer is NULL. + * \retval CUPTI_ERROR_INVALID_KIND if activity record is either incomplete or invalid + */ +public static native @Cast("CUptiResult") int cuptiActivityGetNextRecord(@Cast("uint8_t*") BytePointer buffer, @Cast("size_t") long validBufferSizeBytes, + @Cast("CUpti_Activity**") PointerPointer record); +public static native @Cast("CUptiResult") int cuptiActivityGetNextRecord(@Cast("uint8_t*") BytePointer buffer, @Cast("size_t") long validBufferSizeBytes, + @ByPtrPtr CUpti_Activity record); +public static native @Cast("CUptiResult") int cuptiActivityGetNextRecord(@Cast("uint8_t*") ByteBuffer buffer, @Cast("size_t") long validBufferSizeBytes, + @ByPtrPtr CUpti_Activity record); +public static native @Cast("CUptiResult") int cuptiActivityGetNextRecord(@Cast("uint8_t*") byte[] buffer, @Cast("size_t") long validBufferSizeBytes, + @ByPtrPtr CUpti_Activity record); +// Targeting ../cupti/CUpti_BuffersCallbackRequestFunc.java + + +// Targeting ../cupti/CUpti_BuffersCallbackCompleteFunc.java + + + +/** + * \brief Registers callback functions with CUPTI for activity buffer + * handling. + * + * This function registers two callback functions to be used in asynchronous + * buffer handling. If registered, activity record buffers are handled using + * asynchronous requested/completed callbacks from CUPTI. + * + * Registering these callbacks prevents the client from using CUPTI's + * blocking enqueue/dequeue functions. + * + * @param funcBufferRequested callback which is invoked when an empty + * buffer is requested by CUPTI + * @param funcBufferCompleted callback which is invoked when a buffer + * containing activity records is available from CUPTI + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_INVALID_PARAMETER if either \p + * funcBufferRequested or \p funcBufferCompleted is NULL + */ +public static native @Cast("CUptiResult") int cuptiActivityRegisterCallbacks(CUpti_BuffersCallbackRequestFunc funcBufferRequested, + CUpti_BuffersCallbackCompleteFunc funcBufferCompleted); + +/** + * \brief Wait for all activity records to be delivered via the + * completion callback. + * + * This function does not return until all activity records associated + * with the specified context/stream are returned to the CUPTI client + * using the callback registered in cuptiActivityRegisterCallbacks. To + * ensure that all activity records are complete, the requested + * stream(s), if any, are synchronized. + * + * If \p context is NULL, the global activity records (i.e. those not + * associated with a particular stream) are flushed (in this case no + * streams are synchronized). If \p context is a valid CUcontext and + * \p streamId is 0, the buffers of all streams of this context are + * flushed. Otherwise, the buffers of the specified stream in this + * context is flushed. + * + * Before calling this function, the buffer handling callback api + * must be activated by calling cuptiActivityRegisterCallbacks. + * + * @param context A valid CUcontext or NULL. + * @param streamId The stream ID. + * @param flag The flag can be set to indicate a forced flush. See CUpti_ActivityFlag + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_CUPTI_ERROR_INVALID_OPERATION if not preceded + * by a successful call to cuptiActivityRegisterCallbacks + * \retval CUPTI_ERROR_UNKNOWN an internal error occurred + * + * **DEPRECATED** This method is deprecated + * CONTEXT and STREAMID will be ignored. Use cuptiActivityFlushAll + * to flush all data. + */ +public static native @Cast("CUptiResult") int cuptiActivityFlush(CUctx_st context, @Cast("uint32_t") int streamId, @Cast("uint32_t") int flag); + +/** + * \brief Request to deliver activity records via the buffer completion callback. + * + * This function returns the activity records associated with all contexts/streams + * (and the global buffers not associated with any stream) to the CUPTI client + * using the callback registered in cuptiActivityRegisterCallbacks. + * + * This is a blocking call but it doesn't issue any CUDA synchronization calls + * implicitly thus it's not guaranteed that all activities are completed on the + * underlying devices. Activity record is considered as completed if it has all + * the information filled up including the timestamps if any. It is the client's + * responsibility to issue necessary CUDA synchronization calls before calling + * this function if all activity records with complete information are expected + * to be delivered. + * + * Behavior of the function based on the input flag: + * (-) ::For default flush i.e. when flag is set as 0, it returns all the + * activity buffers which have all the activity records completed, buffers need not + * to be full though. It doesn't return buffers which have one or more incomplete + * records. Default flush can be done at a regular interval in a separate thread. + * (-) ::For forced flush i.e. when flag CUPTI_ACTIVITY_FLAG_FLUSH_FORCED is passed + * to the function, it returns all the activity buffers including the ones which have + * one or more incomplete activity records. It's suggested for clients to do the + * force flush before the termination of the profiling session to allow remaining + * buffers to be delivered. In general, it can be done in the at-exit handler. + * + * Before calling this function, the buffer handling callback api must be activated + * by calling cuptiActivityRegisterCallbacks. + * + * @param flag The flag can be set to indicate a forced flush. See CUpti_ActivityFlag + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_OPERATION if not preceded by a + * successful call to cuptiActivityRegisterCallbacks + * \retval CUPTI_ERROR_UNKNOWN an internal error occurred + * + * @see cuptiActivityFlushPeriod + */ +public static native @Cast("CUptiResult") int cuptiActivityFlushAll(@Cast("uint32_t") int flag); + +/** + * \brief Read an activity API attribute. + * + * Read an activity API attribute and return it in \p *value. + * + * @param attr The attribute to read + * @param valueSize Size of buffer pointed by the value, and + * returns the number of bytes written to \p value + * @param value Returns the value of the attribute + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p valueSize or \p value is NULL, or + * if \p attr is not an activity attribute + * \retval CUPTI_ERROR_PARAMETER_SIZE_NOT_SUFFICIENT Indicates that + * the \p value buffer is too small to hold the attribute value. + */ +public static native @Cast("CUptiResult") int cuptiActivityGetAttribute(@Cast("CUpti_ActivityAttribute") int attr, + @Cast("size_t*") SizeTPointer valueSize, Pointer value); + +/** + * \brief Write an activity API attribute. + * + * Write an activity API attribute. + * + * @param attr The attribute to write + * @param valueSize The size, in bytes, of the value + * @param value The attribute value to write + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p valueSize or \p value is NULL, or + * if \p attr is not an activity attribute + * \retval CUPTI_ERROR_PARAMETER_SIZE_NOT_SUFFICIENT Indicates that + * the \p value buffer is too small to hold the attribute value. + */ +public static native @Cast("CUptiResult") int cuptiActivitySetAttribute(@Cast("CUpti_ActivityAttribute") int attr, + @Cast("size_t*") SizeTPointer valueSize, Pointer value); + + +/** + * \brief Set Unified Memory Counter configuration. + * + * @param config A pointer to \ref CUpti_ActivityUnifiedMemoryCounterConfig structures + * containing Unified Memory counter configuration. + * @param count Number of Unified Memory counter configuration structures + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p config is NULL or + * any parameter in the \p config structures is not a valid value + * \retval CUPTI_ERROR_UM_PROFILING_NOT_SUPPORTED One potential reason is that + * platform (OS/arch) does not support the unified memory counters + * \retval CUPTI_ERROR_UM_PROFILING_NOT_SUPPORTED_ON_DEVICE Indicates that the device + * does not support the unified memory counters + * \retval CUPTI_ERROR_UM_PROFILING_NOT_SUPPORTED_ON_NON_P2P_DEVICES Indicates that + * multi-GPU configuration without P2P support between any pair of devices + * does not support the unified memory counters + */ +public static native @Cast("CUptiResult") int cuptiActivityConfigureUnifiedMemoryCounter(CUpti_ActivityUnifiedMemoryCounterConfig config, @Cast("uint32_t") int count); + +/** + * \brief Get auto boost state + * + * The profiling results can be inconsistent in case auto boost is enabled. + * CUPTI tries to disable auto boost while profiling. It can fail to disable in + * cases where user does not have the permissions or CUDA_AUTO_BOOST env + * variable is set. The function can be used to query whether auto boost is + * enabled. + * + * @param context A valid CUcontext. + * @param state A pointer to \ref CUpti_ActivityAutoBoostState structure which + * contains the current state and the id of the process that has requested the + * current state + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p CUcontext or \p state is NULL + * \retval CUPTI_ERROR_NOT_SUPPORTED Indicates that the device does not support auto boost + * \retval CUPTI_ERROR_UNKNOWN an internal error occurred + */ +public static native @Cast("CUptiResult") int cuptiGetAutoBoostState(CUctx_st context, CUpti_ActivityAutoBoostState state); + +/** + * \brief Set PC sampling configuration. + * + * For Pascal and older GPU architectures this API must be called before enabling + * activity kind CUPTI_ACTIVITY_KIND_PC_SAMPLING. There is no such requirement + * for Volta and newer GPU architectures. + * + * For Volta and newer GPU architectures if this API is called in the middle of + * execution, PC sampling configuration will be updated for subsequent kernel launches. + * + * @param ctx The context + * @param config A pointer to \ref CUpti_ActivityPCSamplingConfig structure + * containing PC sampling configuration. + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_INVALID_OPERATION if this api is called while + * some valid event collection method is set. + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p config is NULL or + * any parameter in the \p config structures is not a valid value + * \retval CUPTI_ERROR_NOT_SUPPORTED Indicates that the system/device + * does not support the unified memory counters + */ +public static native @Cast("CUptiResult") int cuptiActivityConfigurePCSampling(CUctx_st ctx, CUpti_ActivityPCSamplingConfig config); + +/** + * \brief Returns the last error from a cupti call or callback + * + * Returns the last error that has been produced by any of the cupti api calls + * or the callback in the same host thread and resets it to CUPTI_SUCCESS. + */ +public static native @Cast("CUptiResult") int cuptiGetLastError(); + +/** + * \brief Set the thread-id type + * + * CUPTI uses the method corresponding to set type to generate the thread-id. + * See enum \ref CUpti_ActivityThreadIdType for the list of methods. + * Activity records having thread-id field contain the same value. + * Thread id type must not be changed during the profiling session to + * avoid thread-id value mismatch across activity records. + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_SUPPORTED if \p type is not supported on the platform + */ +public static native @Cast("CUptiResult") int cuptiSetThreadIdType(@Cast("CUpti_ActivityThreadIdType") int type); + +/** + * \brief Get the thread-id type + * + * Returns the thread-id type used in CUPTI + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p type is NULL + */ +public static native @Cast("CUptiResult") int cuptiGetThreadIdType(@Cast("CUpti_ActivityThreadIdType*") IntPointer type); +public static native @Cast("CUptiResult") int cuptiGetThreadIdType(@Cast("CUpti_ActivityThreadIdType*") IntBuffer type); +public static native @Cast("CUptiResult") int cuptiGetThreadIdType(@Cast("CUpti_ActivityThreadIdType*") int[] type); + +/** +* \brief Check support for a compute capability +* +* This function is used to check the support for a device based on +* it's compute capability. It sets the \p support when the compute +* capability is supported by the current version of CUPTI, and clears +* it otherwise. This version of CUPTI might not support all GPUs sharing +* the same compute capability. It is suggested to use API \ref +* cuptiDeviceSupported which provides correct information. +* +* @param major The major revision number of the compute capability +* @param minor The minor revision number of the compute capability +* @param support Pointer to an integer to return the support status +* +* \retval CUPTI_SUCCESS +* \retval CUPTI_ERROR_INVALID_PARAMETER if \p support is NULL +* +* @see ::cuptiDeviceSupported +*/ +public static native @Cast("CUptiResult") int cuptiComputeCapabilitySupported(int major, int minor, IntPointer support); +public static native @Cast("CUptiResult") int cuptiComputeCapabilitySupported(int major, int minor, IntBuffer support); +public static native @Cast("CUptiResult") int cuptiComputeCapabilitySupported(int major, int minor, int[] support); + +/** +* \brief Check support for a compute device +* +* This function is used to check the support for a compute device. +* It sets the \p support when the device is supported by the current +* version of CUPTI, and clears it otherwise. +* +* @param dev The device handle returned by CUDA Driver API cuDeviceGet +* @param support Pointer to an integer to return the support status +* +* \retval CUPTI_SUCCESS +* \retval CUPTI_ERROR_INVALID_PARAMETER if \p support is NULL +* \retval CUPTI_ERROR_INVALID_DEVICE if \p dev is not a valid device +* +* @see ::cuptiComputeCapabilitySupported +*/ +public static native @Cast("CUptiResult") int cuptiDeviceSupported(@Cast("CUdevice") int dev, IntPointer support); +public static native @Cast("CUptiResult") int cuptiDeviceSupported(@Cast("CUdevice") int dev, IntBuffer support); +public static native @Cast("CUptiResult") int cuptiDeviceSupported(@Cast("CUdevice") int dev, int[] support); + +/** + * This indicates the virtualization mode in which CUDA device is running + */ +/** enum CUpti_DeviceVirtualizationMode */ +public static final int + /** + * No virtualization mode is associated with the device + * i.e. it's a baremetal GPU + */ + CUPTI_DEVICE_VIRTUALIZATION_MODE_NONE = 0, + /** + * The device is associated with the pass-through GPU. + * In this mode, an entire physical GPU is directly assigned + * to one virtual machine (VM). + */ + CUPTI_DEVICE_VIRTUALIZATION_MODE_PASS_THROUGH = 1, + /** + * The device is associated with the virtual GPU (vGPU). + * In this mode multiple virtual machines (VMs) have simultaneous, + * direct access to a single physical GPU. + */ + CUPTI_DEVICE_VIRTUALIZATION_MODE_VIRTUAL_GPU = 2, + + CUPTI_DEVICE_VIRTUALIZATION_MODE_FORCE_INT = 0x7fffffff; + +/** + * \brief Query the virtualization mode of the device + * + * This function is used to query the virtualization mode of the CUDA device. + * + * @param dev The device handle returned by CUDA Driver API cuDeviceGet + * @param mode Pointer to an CUpti_DeviceVirtualizationMode to return the virtualization mode + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_INVALID_DEVICE if \p dev is not a valid device + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p mode is NULL + * + */ +public static native @Cast("CUptiResult") int cuptiDeviceVirtualizationMode(@Cast("CUdevice") int dev, @Cast("CUpti_DeviceVirtualizationMode*") IntPointer mode); +public static native @Cast("CUptiResult") int cuptiDeviceVirtualizationMode(@Cast("CUdevice") int dev, @Cast("CUpti_DeviceVirtualizationMode*") IntBuffer mode); +public static native @Cast("CUptiResult") int cuptiDeviceVirtualizationMode(@Cast("CUdevice") int dev, @Cast("CUpti_DeviceVirtualizationMode*") int[] mode); + +/** + * \brief Detach CUPTI from the running process + * + * This API detaches the CUPTI from the running process. It destroys and cleans up all the + * resources associated with CUPTI in the current process. After CUPTI detaches from the process, + * the process will keep on running with no CUPTI attached to it. + * For safe operation of the API, it is recommended this API is invoked from the exit callsite + * of any of the CUDA Driver or Runtime API. Otherwise CUPTI client needs to make sure that + * required CUDA synchronization and CUPTI activity buffer flush is done before calling the API. + * Sample code showing the usage of the API in the cupti callback handler code: + *
{@code
+  void CUPTIAPI
+  cuptiCallbackHandler(void *userdata, CUpti_CallbackDomain domain,
+      CUpti_CallbackId cbid, void *cbdata)
+  {
+    const CUpti_CallbackData *cbInfo = (CUpti_CallbackData *)cbdata;
+
+    // Take this code path when CUPTI detach is requested
+    if (detachCupti) {
+      switch(domain)
+      {
+        case CUPTI_CB_DOMAIN_RUNTIME_API:
+        case CUPTI_CB_DOMAIN_DRIVER_API:
+          if (cbInfo->callbackSite == CUPTI_API_EXIT) {
+              // call the CUPTI detach API
+              cuptiFinalize();
+          }
+          break;
+        default:
+          break;
+      }
+    }
+  }
+ }
+ */ +public static native @Cast("CUptiResult") int cuptiFinalize(); + +/** + * \brief Push an external correlation id for the calling thread + * + * This function notifies CUPTI that the calling thread is entering an external API region. + * When a CUPTI activity API record is created while within an external API region and + * CUPTI_ACTIVITY_KIND_EXTERNAL_CORRELATION is enabled, the activity API record will + * be preceded by a CUpti_ActivityExternalCorrelation record for each \ref CUpti_ExternalCorrelationKind. + * + * @param kind The kind of external API activities should be correlated with. + * @param id External correlation id. + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_INVALID_PARAMETER The external API kind is invalid + */ +public static native @Cast("CUptiResult") int cuptiActivityPushExternalCorrelationId(@Cast("CUpti_ExternalCorrelationKind") int kind, @Cast("uint64_t") long id); + +/** + * \brief Pop an external correlation id for the calling thread + * + * This function notifies CUPTI that the calling thread is leaving an external API region. + * + * @param kind The kind of external API activities should be correlated with. + * @param lastId If the function returns successful, contains the last external correlation id for this \p kind, can be NULL. + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_INVALID_PARAMETER The external API kind is invalid. + * \retval CUPTI_ERROR_QUEUE_EMPTY No external id is currently associated with \p kind. + */ +public static native @Cast("CUptiResult") int cuptiActivityPopExternalCorrelationId(@Cast("CUpti_ExternalCorrelationKind") int kind, @Cast("uint64_t*") LongPointer lastId); +public static native @Cast("CUptiResult") int cuptiActivityPopExternalCorrelationId(@Cast("CUpti_ExternalCorrelationKind") int kind, @Cast("uint64_t*") LongBuffer lastId); +public static native @Cast("CUptiResult") int cuptiActivityPopExternalCorrelationId(@Cast("CUpti_ExternalCorrelationKind") int kind, @Cast("uint64_t*") long[] lastId); + +/** + * \brief Controls the collection of queued and submitted timestamps for kernels. + * + * This API is used to control the collection of queued and submitted timestamps + * for kernels whose records are provided through the struct \ref CUpti_ActivityKernel9. + * Default value is 0, i.e. these timestamps are not collected. This API needs + * to be called before initialization of CUDA and this setting should not be + * changed during the profiling session. + * + * @param enable is a boolean, denoting whether these timestamps should be + * collected + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + */ +public static native @Cast("CUptiResult") int cuptiActivityEnableLatencyTimestamps(@Cast("uint8_t") byte enable); + +/** + * \brief Sets the flush period for the worker thread + * + * CUPTI creates a worker thread to minimize the perturbance for the application created + * threads. CUPTI offloads certain operations from the application threads to the worker + * thread, this includes synchronization of profiling resources between host and device, + * delivery of the activity buffers to the client using the callback registered in + * cuptiActivityRegisterCallbacks. For performance reasons, CUPTI wakes up the worker + * thread based on certain heuristics. + * + * This API is used to control the flush period of the worker thread. This setting will + * override the CUPTI heuristics. Setting time to zero disables the periodic flush and + * restores the default behavior. + * + * Periodic flush can return only those activity buffers which are full and have all the + * activity records completed. + * + * It's allowed to use the API \ref cuptiActivityFlushAll to flush the data on-demand, even + * when client sets the periodic flush. + * + * @param time flush period in milliseconds (ms) + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * + * @see cuptiActivityFlushAll + */ +public static native @Cast("CUptiResult") int cuptiActivityFlushPeriod(@Cast("uint32_t") int time); + +/** + * \brief Controls the collection of launch attributes for kernels. + * + * This API is used to control the collection of launch attributes for kernels whose + * records are provided through the struct \ref CUpti_ActivityKernel9. + * Default value is 0, i.e. these attributes are not collected. + * + * @param enable is a boolean denoting whether these launch attributes should be collected + */ +public static native @Cast("CUptiResult") int cuptiActivityEnableLaunchAttributes(@Cast("uint8_t") byte enable); +// Targeting ../cupti/CUpti_TimestampCallbackFunc.java + + + +/** + * \brief Registers callback function with CUPTI for providing timestamp. + * + * This function registers a callback function to obtain timestamp of user's + * choice instead of using CUPTI provided timestamp. + * By default CUPTI uses different methods, based on the underlying platform, + * to retrieve the timestamp + * Linux and Android use clock_gettime(CLOCK_REALTIME, ..) + * Windows uses QueryPerformanceCounter() + * Mac uses mach_absolute_time() + * QNX uses ClockCycles() + * Timestamps retrieved using these methods are converted to nanosecond if needed + * before usage. + * + * The registration of timestamp callback should be done before any of the CUPTI + * activity kinds are enabled to make sure that all the records report the timestamp using + * the callback function registered through cuptiActivityRegisterTimestampCallback API. + * + * Changing the timestamp callback function in CUPTI through + * cuptiActivityRegisterTimestampCallback API in the middle of the profiling + * session can cause records generated prior to the change to report + * timestamps through previous timestamp method. + * + * @param funcTimestamp callback which is invoked when a timestamp is + * needed by CUPTI + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p funcTimestamp is NULL + * \retval CUPTI_ERROR_NOT_INITIALIZED + */ +public static native @Cast("CUptiResult") int cuptiActivityRegisterTimestampCallback(CUpti_TimestampCallbackFunc funcTimestamp); + +/** + * \brief Controls the collection of records for device launched graphs. + * + * This API is used to control the collection of records for device launched graphs. + * Default value is 0, i.e. these records are not collected. This API needs + * to be called before initialization of CUDA and this setting should not be + * changed during the profiling session. + * + * @param enable is a boolean, denoting whether these records should be + * collected + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + */ +public static native @Cast("CUptiResult") int cuptiActivityEnableDeviceGraph(@Cast("uint8_t") byte enable); + +/** + * \brief Controls the collection of activity records for specific CUDA Driver APIs. + * + * Activity kind CUPTI_ACTIVITY_KIND_DRIVER controls the collection of either all + * CUDA Driver APIs or none. API cuptiActivityEnableDriverApi can be used for fine-grained + * control, it allows enabling/disabling tracing of a specific set of CUDA Driver APIs. + * To disable collection of a small set of CUDA Driver APIs, user can + * first enable the collection of all Driver APIs using the activity kind + * CUPTI_ACTIVITY_KIND_DRIVER and call this API to disable specific Driver APIs. + * And to enable the collection of a small set of CUDA Driver APIs, user can + * call this API without using the activity kind CUPTI_ACTIVITY_KIND_DRIVER. + * + * Note: Activity kind CUPTI_ACTIVITY_KIND_DRIVER overrides the settings done by this API + * if it is called after the API. + * + * @param cbid callback id of the CUDA Driver API. This can be found in the header cupti_driver_cbid.h. + * @param enable is a boolean, denoting whether to enable or disable the collection + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + */ +public static native @Cast("CUptiResult") int cuptiActivityEnableDriverApi(@Cast("CUpti_CallbackId") int cbid, @Cast("uint8_t") byte enable); + +/** + * \brief Controls the collection of activity records for specific CUDA Runtime APIs. + * + * Activity kind CUPTI_ACTIVITY_KIND_RUNTIME controls the collection of either all + * CUDA Runtime APIs or none. API cuptiActivityEnableRuntimeApi can be used for fine-grained + * control, it allows enabling/disabling tracing of a specific set of CUDA Runtime APIs. + * To disable collection of a small set of CUDA Runtime APIs, user can + * first enable the collection of all Runtime APIs using the activity kind + * CUPTI_ACTIVITY_KIND_RUNTIME and call this API to disable specific Runtime APIs. + * And to enable the collection of a small set of CUDA Runtime APIs, user can + * call this API without using the activity kind CUPTI_ACTIVITY_KIND_RUNTIME. + * + * Note: Activity kind CUPTI_ACTIVITY_KIND_RUNTIME overrides the settings done by this API + * if it is called after the API. + * + * @param cbid callback id of the CUDA Runtime API. This can be found in the header cupti_runtime_cbid.h. + * @param enable is a boolean, denoting whether to enable or disable the collection + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + */ +public static native @Cast("CUptiResult") int cuptiActivityEnableRuntimeApi(@Cast("CUpti_CallbackId") int cbid, @Cast("uint8_t") byte enable); + + + +/** + * \brief Enables tracking the source library for memory allocation requests. + * + * This API is used to control whether or not we track the source library of + * memory allocation requests. Default value is 0, i.e. it is not tracked. The + * activity kind CUPTI_ACTIVITY_KIND_MEMORY2 needs to be enabled, and if this flag is + * set, we get the full path of the shared object responsible for the GPU memory allocation + * request in the member source in the CUpti_ActivityMemory4 records. Also note that this feature + * adds runtime overhead. + * + * @param enable is a boolean, denoting whether the source library of the memory allocation + * request needs to be tracked + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED +*/ +public static native @Cast("CUptiResult") int cuptiActivityEnableAllocationSource(@Cast("uint8_t") byte enable); +/** \} */ /* END CUPTI_ACTIVITY_API */ + +// #if defined(__GNUC__) && defined(CUPTI_LIB) +// #pragma GCC visibility pop +// #endif + +// #if defined(__cplusplus) +// #endif + +// Including deprecated structures of CUPTI_ACTIVITY_API +// #include "cupti_activity_deprecated.h" + +// #endif /*_CUPTI_ACTIVITY_H_*/ + + +// Parsed from cupti_callbacks.h + +/* + * Copyright 2010-2023 NVIDIA Corporation. All rights reserved. + * + * NOTICE TO LICENSEE: + * + * This source code and/or documentation ("Licensed Deliverables") are + * subject to NVIDIA intellectual property rights under U.S. and + * international Copyright laws. + * + * These Licensed Deliverables contained herein is PROPRIETARY and + * CONFIDENTIAL to NVIDIA and is being provided under the terms and + * conditions of a form of NVIDIA software license agreement by and + * between NVIDIA and Licensee ("License Agreement") or electronically + * accepted by Licensee. Notwithstanding any terms or conditions to + * the contrary in the License Agreement, reproduction or disclosure + * of the Licensed Deliverables to any third party without the express + * written consent of NVIDIA is prohibited. + * + * NOTWITHSTANDING ANY TERMS OR CONDITIONS TO THE CONTRARY IN THE + * LICENSE AGREEMENT, NVIDIA MAKES NO REPRESENTATION ABOUT THE + * SUITABILITY OF THESE LICENSED DELIVERABLES FOR ANY PURPOSE. IT IS + * PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY OF ANY KIND. + * NVIDIA DISCLAIMS ALL WARRANTIES WITH REGARD TO THESE LICENSED + * DELIVERABLES, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY, + * NONINFRINGEMENT, AND FITNESS FOR A PARTICULAR PURPOSE. + * NOTWITHSTANDING ANY TERMS OR CONDITIONS TO THE CONTRARY IN THE + * LICENSE AGREEMENT, IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY + * SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, OR ANY + * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, + * WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS + * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE + * OF THESE LICENSED DELIVERABLES. + * + * U.S. Government End Users. These Licensed Deliverables are a + * "commercial item" as that term is defined at 48 C.F.R. 2.101 (OCT + * 1995), consisting of "commercial computer software" and "commercial + * computer software documentation" as such terms are used in 48 + * C.F.R. 12.212 (SEPT 1995) and is provided to the U.S. Government + * only as a commercial end item. Consistent with 48 C.F.R.12.212 and + * 48 C.F.R. 227.7202-1 through 227.7202-4 (JUNE 1995), all + * U.S. Government End Users acquire the Licensed Deliverables with + * only those rights set forth herein. + * + * Any use of the Licensed Deliverables in individual and commercial + * software must include, in the user documentation and internal + * comments to the code, the above Disclaimer and U.S. Government End + * Users Notice. + */ + +// #if !defined(__CUPTI_CALLBACKS_H__) +// #define __CUPTI_CALLBACKS_H__ + +// #include +// #include +// #include +// #include +// #include + +// #ifndef CUPTIAPI +// #ifdef _WIN32 +// #define CUPTIAPI __stdcall +// #else +// #define CUPTIAPI +// #endif +// #endif + +// #if defined(__cplusplus) +// #endif + +// #if defined(__GNUC__) && defined(CUPTI_LIB) +// #pragma GCC visibility push(default) +// #endif + +/** + * \defgroup CUPTI_CALLBACK_API CUPTI Callback API + * Functions, types, and enums that implement the CUPTI Callback API. + * \{ + */ + +/** + * \brief Specifies the point in an API call that a callback is issued. + * + * Specifies the point in an API call that a callback is issued. This + * value is communicated to the callback function via \ref + * CUpti_CallbackData::callbackSite. + */ +/** enum CUpti_ApiCallbackSite */ +public static final int + /** + * The callback is at the entry of the API call. + */ + CUPTI_API_ENTER = 0, + /** + * The callback is at the exit of the API call. + */ + CUPTI_API_EXIT = 1, + CUPTI_API_CBSITE_FORCE_INT = 0x7fffffff; + +/** + * \brief Callback domains. + * + * Callback domains. Each domain represents callback points for a + * group of related API functions or CUDA driver activity. + */ +/** enum CUpti_CallbackDomain */ +public static final int + /** + * Invalid domain. + */ + CUPTI_CB_DOMAIN_INVALID = 0, + /** + * Domain containing callback points for all driver API functions. + */ + CUPTI_CB_DOMAIN_DRIVER_API = 1, + /** + * Domain containing callback points for all runtime API + * functions. + */ + CUPTI_CB_DOMAIN_RUNTIME_API = 2, + /** + * Domain containing callback points for CUDA resource tracking. + */ + CUPTI_CB_DOMAIN_RESOURCE = 3, + /** + * Domain containing callback points for CUDA synchronization. + */ + CUPTI_CB_DOMAIN_SYNCHRONIZE = 4, + /** + * Domain containing callback points for NVTX API functions. + */ + CUPTI_CB_DOMAIN_NVTX = 5, + /** + * Domain containing callback points for various states. + */ + CUPTI_CB_DOMAIN_STATE = 6, + + CUPTI_CB_DOMAIN_SIZE = 7, + + CUPTI_CB_DOMAIN_FORCE_INT = 0x7fffffff; + +/** + * \brief Callback IDs for resource domain. + * + * Callback IDs for resource domain, CUPTI_CB_DOMAIN_RESOURCE. This + * value is communicated to the callback function via the \p cbid + * parameter. + */ +/** enum CUpti_CallbackIdResource */ +public static final int + /** + * Invalid resource callback ID. + */ + CUPTI_CBID_RESOURCE_INVALID = 0, + /** + * A new context has been created. + */ + CUPTI_CBID_RESOURCE_CONTEXT_CREATED = 1, + /** + * A context is about to be destroyed. + */ + CUPTI_CBID_RESOURCE_CONTEXT_DESTROY_STARTING = 2, + /** + * A new stream has been created. + */ + CUPTI_CBID_RESOURCE_STREAM_CREATED = 3, + /** + * A stream is about to be destroyed. + */ + CUPTI_CBID_RESOURCE_STREAM_DESTROY_STARTING = 4, + /** + * The driver has finished initializing. + */ + CUPTI_CBID_RESOURCE_CU_INIT_FINISHED = 5, + /** + * A module has been loaded. + */ + CUPTI_CBID_RESOURCE_MODULE_LOADED = 6, + /** + * A module is about to be unloaded. + */ + CUPTI_CBID_RESOURCE_MODULE_UNLOAD_STARTING = 7, + /** + * The current module which is being profiled. + */ + CUPTI_CBID_RESOURCE_MODULE_PROFILED = 8, + /** + * CUDA graph has been created. + */ + CUPTI_CBID_RESOURCE_GRAPH_CREATED = 9, + /** + * CUDA graph is about to be destroyed. + */ + CUPTI_CBID_RESOURCE_GRAPH_DESTROY_STARTING = 10, + /** + * CUDA graph is cloned. + */ + CUPTI_CBID_RESOURCE_GRAPH_CLONED = 11, + /** + * CUDA graph node is about to be created + */ + CUPTI_CBID_RESOURCE_GRAPHNODE_CREATE_STARTING = 12, + /** + * CUDA graph node is created. + */ + CUPTI_CBID_RESOURCE_GRAPHNODE_CREATED = 13, + /** + * CUDA graph node is about to be destroyed. + */ + CUPTI_CBID_RESOURCE_GRAPHNODE_DESTROY_STARTING = 14, + /** + * Dependency on a CUDA graph node is created. + */ + CUPTI_CBID_RESOURCE_GRAPHNODE_DEPENDENCY_CREATED = 15, + /** + * Dependency on a CUDA graph node is destroyed. + */ + CUPTI_CBID_RESOURCE_GRAPHNODE_DEPENDENCY_DESTROY_STARTING = 16, + /** + * An executable CUDA graph is about to be created. + */ + CUPTI_CBID_RESOURCE_GRAPHEXEC_CREATE_STARTING = 17, + /** + * An executable CUDA graph is created. + */ + CUPTI_CBID_RESOURCE_GRAPHEXEC_CREATED = 18, + /** + * An executable CUDA graph is about to be destroyed. + */ + CUPTI_CBID_RESOURCE_GRAPHEXEC_DESTROY_STARTING = 19, + /** + * CUDA graph node is cloned. + */ + CUPTI_CBID_RESOURCE_GRAPHNODE_CLONED = 20, + /** + * CUDA stream attribute is changed. + */ + CUPTI_CBID_RESOURCE_STREAM_ATTRIBUTE_CHANGED = 21, + + CUPTI_CBID_RESOURCE_SIZE = 22, + CUPTI_CBID_RESOURCE_FORCE_INT = 0x7fffffff; + +/** + * \brief Callback IDs for synchronization domain. + * + * Callback IDs for synchronization domain, + * CUPTI_CB_DOMAIN_SYNCHRONIZE. This value is communicated to the + * callback function via the \p cbid parameter. + */ +/** enum CUpti_CallbackIdSync */ +public static final int + /** + * Invalid synchronize callback ID. + */ + CUPTI_CBID_SYNCHRONIZE_INVALID = 0, + /** + * Stream synchronization has completed for the stream. + */ + CUPTI_CBID_SYNCHRONIZE_STREAM_SYNCHRONIZED = 1, + /** + * Context synchronization has completed for the context. + */ + CUPTI_CBID_SYNCHRONIZE_CONTEXT_SYNCHRONIZED = 2, + CUPTI_CBID_SYNCHRONIZE_SIZE = 3, + CUPTI_CBID_SYNCHRONIZE_FORCE_INT = 0x7fffffff; + + +/** + * \brief Callback IDs for state domain. + * + * Callback IDs for state domain, + * CUPTI_CB_DOMAIN_STATE. This value is communicated to the + * callback function via the \p cbid parameter. + */ +/** enum CUpti_CallbackIdState */ +public static final int + /** + * Invalid state callback ID. + */ + CUPTI_CBID_STATE_INVALID = 0, + /** + * Notification of fatal errors - high impact, non-recoverable + * When encountered, CUPTI automatically invokes cuptiFinalize() + * User can control behavior of the application in future from + * receiving this callback - such as continuing without profiling, or + * terminating the whole application. + */ + CUPTI_CBID_STATE_FATAL_ERROR = 1, + /** + * Notification of non fatal errors - high impact, but recoverable + * This notification is not issued in the current release. + */ + CUPTI_CBID_STATE_ERROR = 2, + /** + * Notification of warnings - low impact, recoverable + * This notification is not issued in the current release. + */ + CUPTI_CBID_STATE_WARNING = 3, + + CUPTI_CBID_STATE_SIZE = 4, + CUPTI_CBID_STATE_FORCE_INT = 0x7fffffff; +// Targeting ../cupti/CUpti_CallbackData.java + + +// Targeting ../cupti/CUpti_ResourceData.java + + +// Targeting ../cupti/CUpti_ModuleResourceData.java + + +// Targeting ../cupti/CUpti_GraphData.java + + +// Targeting ../cupti/CUpti_SynchronizeData.java + + +// Targeting ../cupti/CUpti_NvtxData.java + + +// Targeting ../cupti/CUpti_StreamAttrData.java + + +// Targeting ../cupti/CUpti_StateData.java + + +/** + * \brief An ID for a driver API, runtime API, resource or + * synchronization callback. + * + * An ID for a driver API, runtime API, resource or synchronization + * callback. Within a driver API callback this should be interpreted + * as a CUpti_driver_api_trace_cbid value (these values are defined in + * cupti_driver_cbid.h). Within a runtime API callback this should be + * interpreted as a CUpti_runtime_api_trace_cbid value (these values + * are defined in cupti_runtime_cbid.h). Within a resource API + * callback this should be interpreted as a \ref + * CUpti_CallbackIdResource value. Within a synchronize API callback + * this should be interpreted as a \ref CUpti_CallbackIdSync value. + */ +// Targeting ../cupti/CUpti_CallbackFunc.java + + +// Targeting ../cupti/CUpti_Subscriber_st.java + + + +/** + * \brief Pointer to an array of callback domains. + */ + +/** + * \brief Get the available callback domains. + * + * Returns in \p *domainTable an array of size \p *domainCount of all + * the available callback domains. + * \note \b Thread-safety: this function is thread safe. + * + * @param domainCount Returns number of callback domains + * @param domainTable Returns pointer to array of available callback domains + * + * \retval CUPTI_SUCCESS on success + * \retval CUPTI_ERROR_NOT_INITIALIZED if unable to initialize CUPTI + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p domainCount or \p domainTable are NULL + */ +public static native @Cast("CUptiResult") int cuptiSupportedDomains(@Cast("size_t*") SizeTPointer domainCount, + @Cast("CUpti_DomainTable*") IntPointer domainTable); +public static native @Cast("CUptiResult") int cuptiSupportedDomains(@Cast("size_t*") SizeTPointer domainCount, + @Cast("CUpti_DomainTable*") IntBuffer domainTable); +public static native @Cast("CUptiResult") int cuptiSupportedDomains(@Cast("size_t*") SizeTPointer domainCount, + @Cast("CUpti_DomainTable*") int[] domainTable); + +/** + * \brief Initialize a callback subscriber with a callback function + * and user data. + * + * Initializes a callback subscriber with a callback function and + * (optionally) a pointer to user data. The returned subscriber handle + * can be used to enable and disable the callback for specific domains + * and callback IDs. + * \note Only a single subscriber can be registered at a time. To ensure + * that no other CUPTI client interrupts the profiling session, it's the + * responsibility of all the CUPTI clients to call this function before + * starting the profling session. In case profiling session is already + * started by another CUPTI client, this function returns the error code + * CUPTI_ERROR_MULTIPLE_SUBSCRIBERS_NOT_SUPPORTED. + * Note that this function returns the same error when application is + * launched using NVIDIA tools like nvprof, Visual Profiler, Nsight Systems, + * Nsight Compute, cuda-gdb and cuda-memcheck. + * \note This function does not enable any callbacks. + * \note \b Thread-safety: this function is thread safe. + * + * @param subscriber Returns handle to initialize subscriber + * @param callback The callback function + * @param userdata A pointer to user data. This data will be passed to + * the callback function via the \p userdata parameter. + * + * \retval CUPTI_SUCCESS on success + * \retval CUPTI_ERROR_NOT_INITIALIZED if unable to initialize CUPTI + * \retval CUPTI_ERROR_MULTIPLE_SUBSCRIBERS_NOT_SUPPORTED if there is already a CUPTI subscriber + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p subscriber is NULL + */ +public static native @Cast("CUptiResult") int cuptiSubscribe(@ByPtrPtr CUpti_Subscriber_st subscriber, + CUpti_CallbackFunc callback, + Pointer userdata); + +/** + * \brief Unregister a callback subscriber. + * + * Removes a callback subscriber so that no future callbacks will be + * issued to that subscriber. + * \note \b Thread-safety: this function is thread safe. + * + * @param subscriber Handle to the initialize subscriber + * + * \retval CUPTI_SUCCESS on success + * \retval CUPTI_ERROR_NOT_INITIALIZED if unable to initialized CUPTI + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p subscriber is NULL or not initialized + */ +public static native @Cast("CUptiResult") int cuptiUnsubscribe(@ByPtr CUpti_Subscriber_st subscriber); + +/** + * \brief Get the current enabled/disabled state of a callback for a specific + * domain and function ID. + * + * Returns non-zero in \p *enable if the callback for a domain and + * callback ID is enabled, and zero if not enabled. + * + * \note \b Thread-safety: a subscriber must serialize access to + * cuptiGetCallbackState, cuptiEnableCallback, cuptiEnableDomain, and + * cuptiEnableAllDomains. For example, if cuptiGetCallbackState(sub, + * d, c) and cuptiEnableCallback(sub, d, c) are called concurrently, + * the results are undefined. + * + * @param enable Returns non-zero if callback enabled, zero if not enabled + * @param subscriber Handle to the initialize subscriber + * @param domain The domain of the callback + * @param cbid The ID of the callback + * + * \retval CUPTI_SUCCESS on success + * \retval CUPTI_ERROR_NOT_INITIALIZED if unable to initialized CUPTI + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p enabled is NULL, or if \p + * subscriber, \p domain or \p cbid is invalid. + */ +public static native @Cast("CUptiResult") int cuptiGetCallbackState(@Cast("uint32_t*") IntPointer enable, + @ByPtr CUpti_Subscriber_st subscriber, + @Cast("CUpti_CallbackDomain") int domain, + @Cast("CUpti_CallbackId") int cbid); +public static native @Cast("CUptiResult") int cuptiGetCallbackState(@Cast("uint32_t*") IntBuffer enable, + @ByPtr CUpti_Subscriber_st subscriber, + @Cast("CUpti_CallbackDomain") int domain, + @Cast("CUpti_CallbackId") int cbid); +public static native @Cast("CUptiResult") int cuptiGetCallbackState(@Cast("uint32_t*") int[] enable, + @ByPtr CUpti_Subscriber_st subscriber, + @Cast("CUpti_CallbackDomain") int domain, + @Cast("CUpti_CallbackId") int cbid); + +/** + * \brief Enable or disabled callbacks for a specific domain and + * callback ID. + * + * Enable or disabled callbacks for a subscriber for a specific domain + * and callback ID. + * + * \note \b Thread-safety: a subscriber must serialize access to + * cuptiGetCallbackState, cuptiEnableCallback, cuptiEnableDomain, and + * cuptiEnableAllDomains. For example, if cuptiGetCallbackState(sub, + * d, c) and cuptiEnableCallback(sub, d, c) are called concurrently, + * the results are undefined. + * + * @param enable New enable state for the callback. Zero disables the + * callback, non-zero enables the callback. + * @param subscriber - Handle to callback subscription + * @param domain The domain of the callback + * @param cbid The ID of the callback + * + * \retval CUPTI_SUCCESS on success + * \retval CUPTI_ERROR_NOT_INITIALIZED if unable to initialized CUPTI + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p subscriber, \p domain or \p + * cbid is invalid. + */ +public static native @Cast("CUptiResult") int cuptiEnableCallback(@Cast("uint32_t") int enable, + @ByPtr CUpti_Subscriber_st subscriber, + @Cast("CUpti_CallbackDomain") int domain, + @Cast("CUpti_CallbackId") int cbid); + +/** + * \brief Enable or disabled all callbacks for a specific domain. + * + * Enable or disabled all callbacks for a specific domain. + * + * \note \b Thread-safety: a subscriber must serialize access to + * cuptiGetCallbackState, cuptiEnableCallback, cuptiEnableDomain, and + * cuptiEnableAllDomains. For example, if cuptiGetCallbackEnabled(sub, + * d, *) and cuptiEnableDomain(sub, d) are called concurrently, the + * results are undefined. + * + * @param enable New enable state for all callbacks in the + * domain. Zero disables all callbacks, non-zero enables all + * callbacks. + * @param subscriber - Handle to callback subscription + * @param domain The domain of the callback + * + * \retval CUPTI_SUCCESS on success + * \retval CUPTI_ERROR_NOT_INITIALIZED if unable to initialized CUPTI + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p subscriber or \p domain is invalid + */ +public static native @Cast("CUptiResult") int cuptiEnableDomain(@Cast("uint32_t") int enable, + @ByPtr CUpti_Subscriber_st subscriber, + @Cast("CUpti_CallbackDomain") int domain); + +/** + * \brief Enable or disable all callbacks in all domains. + * + * Enable or disable all callbacks in all domains. + * + * \note \b Thread-safety: a subscriber must serialize access to + * cuptiGetCallbackState, cuptiEnableCallback, cuptiEnableDomain, and + * cuptiEnableAllDomains. For example, if cuptiGetCallbackState(sub, + * d, *) and cuptiEnableAllDomains(sub) are called concurrently, the + * results are undefined. + * + * @param enable New enable state for all callbacks in all + * domain. Zero disables all callbacks, non-zero enables all + * callbacks. + * @param subscriber - Handle to callback subscription + * + * \retval CUPTI_SUCCESS on success + * \retval CUPTI_ERROR_NOT_INITIALIZED if unable to initialized CUPTI + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p subscriber is invalid + */ +public static native @Cast("CUptiResult") int cuptiEnableAllDomains(@Cast("uint32_t") int enable, + @ByPtr CUpti_Subscriber_st subscriber); + +/** + * \brief Get the name of a callback for a specific domain and callback ID. + * + * Returns a pointer to the name c_string in \p **name. + * + * \note \b Names are available only for the DRIVER and RUNTIME domains. + * + * @param domain The domain of the callback + * @param cbid The ID of the callback + * @param name Returns pointer to the name string on success, NULL otherwise + * + * \retval CUPTI_SUCCESS on success + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p name is NULL, or if + * \p domain or \p cbid is invalid. + */ +public static native @Cast("CUptiResult") int cuptiGetCallbackName(@Cast("CUpti_CallbackDomain") int domain, + @Cast("uint32_t") int cbid, + @Cast("const char**") PointerPointer name); +public static native @Cast("CUptiResult") int cuptiGetCallbackName(@Cast("CUpti_CallbackDomain") int domain, + @Cast("uint32_t") int cbid, + @Cast("const char**") @ByPtrPtr BytePointer name); +public static native @Cast("CUptiResult") int cuptiGetCallbackName(@Cast("CUpti_CallbackDomain") int domain, + @Cast("uint32_t") int cbid, + @Cast("const char**") @ByPtrPtr ByteBuffer name); +public static native @Cast("CUptiResult") int cuptiGetCallbackName(@Cast("CUpti_CallbackDomain") int domain, + @Cast("uint32_t") int cbid, + @Cast("const char**") @ByPtrPtr byte[] name); + +/** \} */ /* END CUPTI_CALLBACK_API */ + +// #if defined(__GNUC__) && defined(CUPTI_LIB) +// #pragma GCC visibility pop +// #endif + +// #if defined(__cplusplus) +// #endif + +// #endif // file guard + + + +// Parsed from cupti_events.h + +/* + * Copyright 2010-2021 NVIDIA Corporation. All rights reserved. + * + * NOTICE TO LICENSEE: + * + * This source code and/or documentation ("Licensed Deliverables") are + * subject to NVIDIA intellectual property rights under U.S. and + * international Copyright laws. + * + * These Licensed Deliverables contained herein is PROPRIETARY and + * CONFIDENTIAL to NVIDIA and is being provided under the terms and + * conditions of a form of NVIDIA software license agreement by and + * between NVIDIA and Licensee ("License Agreement") or electronically + * accepted by Licensee. Notwithstanding any terms or conditions to + * the contrary in the License Agreement, reproduction or disclosure + * of the Licensed Deliverables to any third party without the express + * written consent of NVIDIA is prohibited. + * + * NOTWITHSTANDING ANY TERMS OR CONDITIONS TO THE CONTRARY IN THE + * LICENSE AGREEMENT, NVIDIA MAKES NO REPRESENTATION ABOUT THE + * SUITABILITY OF THESE LICENSED DELIVERABLES FOR ANY PURPOSE. IT IS + * PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY OF ANY KIND. + * NVIDIA DISCLAIMS ALL WARRANTIES WITH REGARD TO THESE LICENSED + * DELIVERABLES, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY, + * NONINFRINGEMENT, AND FITNESS FOR A PARTICULAR PURPOSE. + * NOTWITHSTANDING ANY TERMS OR CONDITIONS TO THE CONTRARY IN THE + * LICENSE AGREEMENT, IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY + * SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, OR ANY + * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, + * WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS + * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE + * OF THESE LICENSED DELIVERABLES. + * + * U.S. Government End Users. These Licensed Deliverables are a + * "commercial item" as that term is defined at 48 C.F.R. 2.101 (OCT + * 1995), consisting of "commercial computer software" and "commercial + * computer software documentation" as such terms are used in 48 + * C.F.R. 12.212 (SEPT 1995) and is provided to the U.S. Government + * only as a commercial end item. Consistent with 48 C.F.R.12.212 and + * 48 C.F.R. 227.7202-1 through 227.7202-4 (JUNE 1995), all + * U.S. Government End Users acquire the Licensed Deliverables with + * only those rights set forth herein. + * + * Any use of the Licensed Deliverables in individual and commercial + * software must include, in the user documentation and internal + * comments to the code, the above Disclaimer and U.S. Government End + * Users Notice. + */ + +// #if !defined(_CUPTI_EVENTS_H_) +// #define _CUPTI_EVENTS_H_ + +// #include +// #include +// #include +// #include + +// #ifndef CUPTIAPI +// #ifdef _WIN32 +// #define CUPTIAPI __stdcall +// #else +// #define CUPTIAPI +// #endif +// #endif + +// #if defined(__cplusplus) +// #endif + +// #if defined(__GNUC__) && defined(CUPTI_LIB) +// #pragma GCC visibility push(default) +// #endif + +/** + * \defgroup CUPTI_EVENT_API CUPTI Event API + * Functions, types, and enums that implement the CUPTI Event API. + * + * \note CUPTI event API from the header cupti_events.h are not supported on devices + * with compute capability 7.5 and higher (i.e. Turing and later GPU architectures). + * These API will be deprecated in a future CUDA release. These are replaced by + * Profiling API in the header cupti_profiler_target.h and Perfworks metrics API + * in the headers nvperf_host.h and nvperf_target.h which are supported on + * devices with compute capability 7.0 and higher (i.e. Volta and later GPU + * architectures). + * + * \{ + */ + +/** + * \brief ID for an event. + * + * An event represents a countable activity, action, or occurrence on + * the device. + */ + +/** + * \brief ID for an event domain. + * + * ID for an event domain. An event domain represents a group of + * related events. A device may have multiple instances of a domain, + * indicating that the device can simultaneously record multiple + * instances of each event within that domain. + */ +// Targeting ../cupti/CUpti_EventGroup.java + + + +/** + * \brief Device class. + * + * Enumeration of device classes for device attribute + * CUPTI_DEVICE_ATTR_DEVICE_CLASS. + */ +/** enum CUpti_DeviceAttributeDeviceClass */ +public static final int + CUPTI_DEVICE_ATTR_DEVICE_CLASS_TESLA = 0, + CUPTI_DEVICE_ATTR_DEVICE_CLASS_QUADRO = 1, + CUPTI_DEVICE_ATTR_DEVICE_CLASS_GEFORCE = 2, + CUPTI_DEVICE_ATTR_DEVICE_CLASS_TEGRA = 3; + +/** + * \brief Device attributes. + * + * CUPTI device attributes. These attributes can be read using \ref + * cuptiDeviceGetAttribute. + */ +/** enum CUpti_DeviceAttribute */ +public static final int + /** + * Number of event IDs for a device. Value is a uint32_t. + */ + CUPTI_DEVICE_ATTR_MAX_EVENT_ID = 1, + /** + * Number of event domain IDs for a device. Value is a uint32_t. + */ + CUPTI_DEVICE_ATTR_MAX_EVENT_DOMAIN_ID = 2, + /** + * Get global memory bandwidth in Kbytes/sec. Value is a uint64_t. + */ + CUPTI_DEVICE_ATTR_GLOBAL_MEMORY_BANDWIDTH = 3, + /** + * Get theoretical maximum number of instructions per cycle. Value + * is a uint32_t. + */ + CUPTI_DEVICE_ATTR_INSTRUCTION_PER_CYCLE = 4, + /** + * Get theoretical maximum number of single precision instructions + * that can be executed per second. Value is a uint64_t. + */ + CUPTI_DEVICE_ATTR_INSTRUCTION_THROUGHPUT_SINGLE_PRECISION = 5, + /** + * Get number of frame buffers for device. Value is a uint64_t. + */ + CUPTI_DEVICE_ATTR_MAX_FRAME_BUFFERS = 6, + /** + * Get PCIE link rate in Mega bits/sec for device. Return 0 if bus-type + * is non-PCIE. Value is a uint64_t. + */ + CUPTI_DEVICE_ATTR_PCIE_LINK_RATE = 7, + /** + * Get PCIE link width for device. Return 0 if bus-type + * is non-PCIE. Value is a uint64_t. + */ + CUPTI_DEVICE_ATTR_PCIE_LINK_WIDTH = 8, + /** + * Get PCIE generation for device. Return 0 if bus-type + * is non-PCIE. Value is a uint64_t. + */ + CUPTI_DEVICE_ATTR_PCIE_GEN = 9, + /** + * Get the class for the device. Value is a + * CUpti_DeviceAttributeDeviceClass. + */ + CUPTI_DEVICE_ATTR_DEVICE_CLASS = 10, + /** + * Get the peak single precision flop per cycle. Value is a uint64_t. + */ + CUPTI_DEVICE_ATTR_FLOP_SP_PER_CYCLE = 11, + /** + * Get the peak double precision flop per cycle. Value is a uint64_t. + */ + CUPTI_DEVICE_ATTR_FLOP_DP_PER_CYCLE = 12, + /** + * Get number of L2 units. Value is a uint64_t. + */ + CUPTI_DEVICE_ATTR_MAX_L2_UNITS = 13, + /** + * Get the maximum shared memory for the CU_FUNC_CACHE_PREFER_SHARED + * preference. Value is a uint64_t. + */ + CUPTI_DEVICE_ATTR_MAX_SHARED_MEMORY_CACHE_CONFIG_PREFER_SHARED = 14, + /** + * Get the maximum shared memory for the CU_FUNC_CACHE_PREFER_L1 + * preference. Value is a uint64_t. + */ + CUPTI_DEVICE_ATTR_MAX_SHARED_MEMORY_CACHE_CONFIG_PREFER_L1 = 15, + /** + * Get the maximum shared memory for the CU_FUNC_CACHE_PREFER_EQUAL + * preference. Value is a uint64_t. + */ + CUPTI_DEVICE_ATTR_MAX_SHARED_MEMORY_CACHE_CONFIG_PREFER_EQUAL = 16, + /** + * Get the peak half precision flop per cycle. Value is a uint64_t. + */ + CUPTI_DEVICE_ATTR_FLOP_HP_PER_CYCLE = 17, + /** + * Check if Nvlink is connected to device. Returns 1, if at least one + * Nvlink is connected to the device, returns 0 otherwise. + * Value is a uint32_t. + */ + CUPTI_DEVICE_ATTR_NVLINK_PRESENT = 18, + /** + * Check if Nvlink is present between GPU and CPU. Returns Bandwidth, + * in Bytes/sec, if Nvlink is present, returns 0 otherwise. + * Value is a uint64_t. + */ + CUPTI_DEVICE_ATTR_GPU_CPU_NVLINK_BW = 19, + /** + * Check if NVSwitch is present in the underlying topology. + * Returns 1, if present, returns 0 otherwise. + * Value is a uint32_t. + */ + CUPTI_DEVICE_ATTR_NVSWITCH_PRESENT = 20, + CUPTI_DEVICE_ATTR_FORCE_INT = 0x7fffffff; + +/** + * \brief Event domain attributes. + * + * Event domain attributes. Except where noted, all the attributes can + * be read using either \ref cuptiDeviceGetEventDomainAttribute or + * \ref cuptiEventDomainGetAttribute. + */ +/** enum CUpti_EventDomainAttribute */ +public static final int + /** + * Event domain name. Value is a null terminated const c-string. + */ + CUPTI_EVENT_DOMAIN_ATTR_NAME = 0, + /** + * Number of instances of the domain for which event counts will be + * collected. The domain may have additional instances that cannot + * be profiled (see CUPTI_EVENT_DOMAIN_ATTR_TOTAL_INSTANCE_COUNT). + * Can be read only with \ref + * cuptiDeviceGetEventDomainAttribute. Value is a uint32_t. + */ + CUPTI_EVENT_DOMAIN_ATTR_INSTANCE_COUNT = 1, + /** + * Total number of instances of the domain, including instances that + * cannot be profiled. Use CUPTI_EVENT_DOMAIN_ATTR_INSTANCE_COUNT + * to get the number of instances that can be profiled. Can be read + * only with \ref cuptiDeviceGetEventDomainAttribute. Value is a + * uint32_t. + */ + CUPTI_EVENT_DOMAIN_ATTR_TOTAL_INSTANCE_COUNT = 3, + /** + * Collection method used for events contained in the event domain. + * Value is a \ref CUpti_EventCollectionMethod. + */ + CUPTI_EVENT_DOMAIN_ATTR_COLLECTION_METHOD = 4, + + CUPTI_EVENT_DOMAIN_ATTR_FORCE_INT = 0x7fffffff; + +/** + * \brief The collection method used for an event. + * + * The collection method indicates how an event is collected. + */ +/** enum CUpti_EventCollectionMethod */ +public static final int + /** + * Event is collected using a hardware global performance monitor. + */ + CUPTI_EVENT_COLLECTION_METHOD_PM = 0, + /** + * Event is collected using a hardware SM performance monitor. + */ + CUPTI_EVENT_COLLECTION_METHOD_SM = 1, + /** + * Event is collected using software instrumentation. + */ + CUPTI_EVENT_COLLECTION_METHOD_INSTRUMENTED = 2, + /** + * Event is collected using NvLink throughput counter method. + */ + CUPTI_EVENT_COLLECTION_METHOD_NVLINK_TC = 3, + CUPTI_EVENT_COLLECTION_METHOD_FORCE_INT = 0x7fffffff; + +/** + * \brief Event group attributes. + * + * Event group attributes. These attributes can be read using \ref + * cuptiEventGroupGetAttribute. Attributes marked [rw] can also be + * written using \ref cuptiEventGroupSetAttribute. + */ +/** enum CUpti_EventGroupAttribute */ +public static final int + /** + * The domain to which the event group is bound. This attribute is + * set when the first event is added to the group. Value is a + * CUpti_EventDomainID. + */ + CUPTI_EVENT_GROUP_ATTR_EVENT_DOMAIN_ID = 0, + /** + * [rw] Profile all the instances of the domain for this + * eventgroup. This feature can be used to get load balancing + * across all instances of a domain. Value is an integer. + */ + CUPTI_EVENT_GROUP_ATTR_PROFILE_ALL_DOMAIN_INSTANCES = 1, + /** + * [rw] Reserved for user data. + */ + CUPTI_EVENT_GROUP_ATTR_USER_DATA = 2, + /** + * Number of events in the group. Value is a uint32_t. + */ + CUPTI_EVENT_GROUP_ATTR_NUM_EVENTS = 3, + /** + * Enumerates events in the group. Value is a pointer to buffer of + * size sizeof(CUpti_EventID) * num_of_events in the eventgroup. + * num_of_events can be queried using + * CUPTI_EVENT_GROUP_ATTR_NUM_EVENTS. + */ + CUPTI_EVENT_GROUP_ATTR_EVENTS = 4, + /** + * Number of instances of the domain bound to this event group that + * will be counted. Value is a uint32_t. + */ + CUPTI_EVENT_GROUP_ATTR_INSTANCE_COUNT = 5, + /** + * Event group scope can be set to CUPTI_EVENT_PROFILING_SCOPE_DEVICE or + * CUPTI_EVENT_PROFILING_SCOPE_CONTEXT for an eventGroup, before + * adding any event. + * Sets the scope of eventgroup as CUPTI_EVENT_PROFILING_SCOPE_DEVICE or + * CUPTI_EVENT_PROFILING_SCOPE_CONTEXT when the scope of the events + * that will be added is CUPTI_EVENT_PROFILING_SCOPE_BOTH. + * If profiling scope of event is either + * CUPTI_EVENT_PROFILING_SCOPE_DEVICE or CUPTI_EVENT_PROFILING_SCOPE_CONTEXT + * then setting this attribute will not affect the default scope. + * It is not allowed to add events of different scope to same eventgroup. + * Value is a uint32_t. + */ + CUPTI_EVENT_GROUP_ATTR_PROFILING_SCOPE = 6, + CUPTI_EVENT_GROUP_ATTR_FORCE_INT = 0x7fffffff; + +/** +* \brief Profiling scope for event. +* +* Profiling scope of event indicates if the event can be collected at context +* scope or device scope or both i.e. it can be collected at any of context or +* device scope. +*/ +/** enum CUpti_EventProfilingScope */ +public static final int + /** + * Event is collected at context scope. + */ + CUPTI_EVENT_PROFILING_SCOPE_CONTEXT = 0, + /** + * Event is collected at device scope. + */ + CUPTI_EVENT_PROFILING_SCOPE_DEVICE = 1, + /** + * Event can be collected at device or context scope. + * The scope can be set using \ref cuptiEventGroupSetAttribute API. + */ + CUPTI_EVENT_PROFILING_SCOPE_BOTH = 2, + CUPTI_EVENT_PROFILING_SCOPE_FORCE_INT = 0x7fffffff; + +/** + * \brief Event attributes. + * + * Event attributes. These attributes can be read using \ref + * cuptiEventGetAttribute. + */ +/** enum CUpti_EventAttribute */ +public static final int + /** + * Event name. Value is a null terminated const c-string. + */ + CUPTI_EVENT_ATTR_NAME = 0, + /** + * Short description of event. Value is a null terminated const + * c-string. + */ + CUPTI_EVENT_ATTR_SHORT_DESCRIPTION = 1, + /** + * Long description of event. Value is a null terminated const + * c-string. + */ + CUPTI_EVENT_ATTR_LONG_DESCRIPTION = 2, + /** + * Category of event. Value is CUpti_EventCategory. + */ + CUPTI_EVENT_ATTR_CATEGORY = 3, + /** + * Profiling scope of the events. It can be either device or context or both. + * Value is a \ref CUpti_EventProfilingScope. + */ + CUPTI_EVENT_ATTR_PROFILING_SCOPE = 5, + + CUPTI_EVENT_ATTR_FORCE_INT = 0x7fffffff; + +/** + * \brief Event collection modes. + * + * The event collection mode determines the period over which the + * events within the enabled event groups will be collected. + */ +/** enum CUpti_EventCollectionMode */ +public static final int + /** + * Events are collected for the entire duration between the + * cuptiEventGroupEnable and cuptiEventGroupDisable calls. + * Event values are reset when the events are read. + * For CUDA toolkit v6.0 and older this was the default mode. + */ + CUPTI_EVENT_COLLECTION_MODE_CONTINUOUS = 0, + /** + * Events are collected only for the durations of kernel executions + * that occur between the cuptiEventGroupEnable and + * cuptiEventGroupDisable calls. Event collection begins when a + * kernel execution begins, and stops when kernel execution + * completes. Event values are reset to zero when each kernel + * execution begins. If multiple kernel executions occur between the + * cuptiEventGroupEnable and cuptiEventGroupDisable calls then the + * event values must be read after each kernel launch if those + * events need to be associated with the specific kernel launch. + * Note that collection in this mode may significantly change the + * overall performance characteristics of the application because + * kernel executions that occur between the cuptiEventGroupEnable and + * cuptiEventGroupDisable calls are serialized on the GPU. + * This is the default mode from CUDA toolkit v6.5 + */ + CUPTI_EVENT_COLLECTION_MODE_KERNEL = 1, + CUPTI_EVENT_COLLECTION_MODE_FORCE_INT = 0x7fffffff; + +/** + * \brief An event category. + * + * Each event is assigned to a category that represents the general + * type of the event. A event's category is accessed using \ref + * cuptiEventGetAttribute and the CUPTI_EVENT_ATTR_CATEGORY attribute. + */ +/** enum CUpti_EventCategory */ +public static final int + /** + * An instruction related event. + */ + CUPTI_EVENT_CATEGORY_INSTRUCTION = 0, + /** + * A memory related event. + */ + CUPTI_EVENT_CATEGORY_MEMORY = 1, + /** + * A cache related event. + */ + CUPTI_EVENT_CATEGORY_CACHE = 2, + /** + * A profile-trigger event. + */ + CUPTI_EVENT_CATEGORY_PROFILE_TRIGGER = 3, + /** + * A system event. + */ + CUPTI_EVENT_CATEGORY_SYSTEM = 4, + CUPTI_EVENT_CATEGORY_FORCE_INT = 0x7fffffff; + +/** + * \brief The overflow value for a CUPTI event. + * + * The CUPTI event value that indicates an overflow. + */ +public static final long CUPTI_EVENT_OVERFLOW = ((long)0xFFFFFFFFFFFFFFFFL); + +/** + * \brief The value that indicates the event value is invalid + */ +public static final long CUPTI_EVENT_INVALID = ((long)0xFFFFFFFFFFFFFFFEL); + +/** + * \brief Flags for cuptiEventGroupReadEvent an + * cuptiEventGroupReadAllEvents. + * + * Flags for \ref cuptiEventGroupReadEvent an \ref + * cuptiEventGroupReadAllEvents. + */ +/** enum CUpti_ReadEventFlags */ +public static final int + /** + * No flags. + */ + CUPTI_EVENT_READ_FLAG_NONE = 0, + CUPTI_EVENT_READ_FLAG_FORCE_INT = 0x7fffffff; +// Targeting ../cupti/CUpti_EventGroupSet.java + + +// Targeting ../cupti/CUpti_EventGroupSets.java + + + +/** + * \brief Set the event collection mode. + * + * Set the event collection mode for a \p context. The \p mode + * controls the event collection behavior of all events in event + * groups created in the \p context. This API is invalid in kernel + * replay mode. + * \note \b Thread-safety: this function is thread safe. + * + * @param context The context + * @param mode The event collection mode + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_CONTEXT + * \retval CUPTI_ERROR_INVALID_OPERATION if called when replay mode is enabled + * \retval CUPTI_ERROR_NOT_SUPPORTED if mode is not supported on the device + */ + +public static native @Cast("CUptiResult") int cuptiSetEventCollectionMode(CUctx_st context, + @Cast("CUpti_EventCollectionMode") int mode); + +/** + * \brief Read a device attribute. + * + * Read a device attribute and return it in \p *value. + * \note \b Thread-safety: this function is thread safe. + * + * @param device The CUDA device + * @param attrib The attribute to read + * @param valueSize Size of buffer pointed by the value, and + * returns the number of bytes written to \p value + * @param value Returns the value of the attribute + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_DEVICE + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p valueSize or \p value + * is NULL, or if \p attrib is not a device attribute + * \retval CUPTI_ERROR_PARAMETER_SIZE_NOT_SUFFICIENT For non-c-string + * attribute values, indicates that the \p value buffer is too small + * to hold the attribute value. + */ +public static native @Cast("CUptiResult") int cuptiDeviceGetAttribute(@Cast("CUdevice") int device, + @Cast("CUpti_DeviceAttribute") int attrib, + @Cast("size_t*") SizeTPointer valueSize, + Pointer value); + +/** + * \brief Get the number of domains for a device. + * + * Returns the number of domains in \p numDomains for a device. + * \note \b Thread-safety: this function is thread safe. + * + * @param device The CUDA device + * @param numDomains Returns the number of domains + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_DEVICE + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p numDomains is NULL + */ +public static native @Cast("CUptiResult") int cuptiDeviceGetNumEventDomains(@Cast("CUdevice") int device, + @Cast("uint32_t*") IntPointer numDomains); +public static native @Cast("CUptiResult") int cuptiDeviceGetNumEventDomains(@Cast("CUdevice") int device, + @Cast("uint32_t*") IntBuffer numDomains); +public static native @Cast("CUptiResult") int cuptiDeviceGetNumEventDomains(@Cast("CUdevice") int device, + @Cast("uint32_t*") int[] numDomains); + +/** + * \brief Get the event domains for a device. + * + * Returns the event domains IDs in \p domainArray for a device. The + * size of the \p domainArray buffer is given by \p + * *arraySizeBytes. The size of the \p domainArray buffer must be at + * least \p numdomains * sizeof(CUpti_EventDomainID) or else all + * domains will not be returned. The value returned in \p + * *arraySizeBytes contains the number of bytes returned in \p + * domainArray. + * \note \b Thread-safety: this function is thread safe. + * + * @param device The CUDA device + * @param arraySizeBytes The size of \p domainArray in bytes, and + * returns the number of bytes written to \p domainArray + * @param domainArray Returns the IDs of the event domains for the device + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_DEVICE + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p arraySizeBytes or + * \p domainArray are NULL + */ +public static native @Cast("CUptiResult") int cuptiDeviceEnumEventDomains(@Cast("CUdevice") int device, + @Cast("size_t*") SizeTPointer arraySizeBytes, + @Cast("CUpti_EventDomainID*") IntPointer domainArray); +public static native @Cast("CUptiResult") int cuptiDeviceEnumEventDomains(@Cast("CUdevice") int device, + @Cast("size_t*") SizeTPointer arraySizeBytes, + @Cast("CUpti_EventDomainID*") int[] domainArray); + +/** + * \brief Read an event domain attribute. + * + * Returns an event domain attribute in \p *value. The size of the \p + * value buffer is given by \p *valueSize. The value returned in \p + * *valueSize contains the number of bytes returned in \p value. + * + * If the attribute value is a c-string that is longer than \p + * *valueSize, then only the first \p *valueSize characters will be + * returned and there will be no terminating null byte. + * \note \b Thread-safety: this function is thread safe. + * + * @param device The CUDA device + * @param eventDomain ID of the event domain + * @param attrib The event domain attribute to read + * @param valueSize The size of the \p value buffer in bytes, and + * returns the number of bytes written to \p value + * @param value Returns the attribute's value + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_DEVICE + * \retval CUPTI_ERROR_INVALID_EVENT_DOMAIN_ID + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p valueSize or \p value + * is NULL, or if \p attrib is not an event domain attribute + * \retval CUPTI_ERROR_PARAMETER_SIZE_NOT_SUFFICIENT For non-c-string + * attribute values, indicates that the \p value buffer is too small + * to hold the attribute value. + */ +public static native @Cast("CUptiResult") int cuptiDeviceGetEventDomainAttribute(@Cast("CUdevice") int device, + @Cast("CUpti_EventDomainID") int eventDomain, + @Cast("CUpti_EventDomainAttribute") int attrib, + @Cast("size_t*") SizeTPointer valueSize, + Pointer value); + +/** + * \brief Get the number of event domains available on any device. + * + * Returns the total number of event domains available on any + * CUDA-capable device. + * \note \b Thread-safety: this function is thread safe. + * + * @param numDomains Returns the number of domains + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p numDomains is NULL + */ +public static native @Cast("CUptiResult") int cuptiGetNumEventDomains(@Cast("uint32_t*") IntPointer numDomains); +public static native @Cast("CUptiResult") int cuptiGetNumEventDomains(@Cast("uint32_t*") IntBuffer numDomains); +public static native @Cast("CUptiResult") int cuptiGetNumEventDomains(@Cast("uint32_t*") int[] numDomains); + +/** + * \brief Get the event domains available on any device. + * + * Returns all the event domains available on any CUDA-capable device. + * Event domain IDs are returned in \p domainArray. The size of the \p + * domainArray buffer is given by \p *arraySizeBytes. The size of the + * \p domainArray buffer must be at least \p numDomains * + * sizeof(CUpti_EventDomainID) or all domains will not be + * returned. The value returned in \p *arraySizeBytes contains the + * number of bytes returned in \p domainArray. + * \note \b Thread-safety: this function is thread safe. + * + * @param arraySizeBytes The size of \p domainArray in bytes, and + * returns the number of bytes written to \p domainArray + * @param domainArray Returns all the event domains + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p arraySizeBytes or + * \p domainArray are NULL + */ +public static native @Cast("CUptiResult") int cuptiEnumEventDomains(@Cast("size_t*") SizeTPointer arraySizeBytes, + @Cast("CUpti_EventDomainID*") IntPointer domainArray); +public static native @Cast("CUptiResult") int cuptiEnumEventDomains(@Cast("size_t*") SizeTPointer arraySizeBytes, + @Cast("CUpti_EventDomainID*") int[] domainArray); + +/** + * \brief Read an event domain attribute. + * + * Returns an event domain attribute in \p *value. The size of the \p + * value buffer is given by \p *valueSize. The value returned in \p + * *valueSize contains the number of bytes returned in \p value. + * + * If the attribute value is a c-string that is longer than \p + * *valueSize, then only the first \p *valueSize characters will be + * returned and there will be no terminating null byte. + * \note \b Thread-safety: this function is thread safe. + * + * @param eventDomain ID of the event domain + * @param attrib The event domain attribute to read + * @param valueSize The size of the \p value buffer in bytes, and + * returns the number of bytes written to \p value + * @param value Returns the attribute's value + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_EVENT_DOMAIN_ID + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p valueSize or \p value + * is NULL, or if \p attrib is not an event domain attribute + * \retval CUPTI_ERROR_PARAMETER_SIZE_NOT_SUFFICIENT For non-c-string + * attribute values, indicates that the \p value buffer is too small + * to hold the attribute value. + */ +public static native @Cast("CUptiResult") int cuptiEventDomainGetAttribute(@Cast("CUpti_EventDomainID") int eventDomain, + @Cast("CUpti_EventDomainAttribute") int attrib, + @Cast("size_t*") SizeTPointer valueSize, + Pointer value); + +/** + * \brief Get number of events in a domain. + * + * Returns the number of events in \p numEvents for a domain. + * \note \b Thread-safety: this function is thread safe. + * + * @param eventDomain ID of the event domain + * @param numEvents Returns the number of events in the domain + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_EVENT_DOMAIN_ID + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p numEvents is NULL + */ +public static native @Cast("CUptiResult") int cuptiEventDomainGetNumEvents(@Cast("CUpti_EventDomainID") int eventDomain, + @Cast("uint32_t*") IntPointer numEvents); +public static native @Cast("CUptiResult") int cuptiEventDomainGetNumEvents(@Cast("CUpti_EventDomainID") int eventDomain, + @Cast("uint32_t*") IntBuffer numEvents); +public static native @Cast("CUptiResult") int cuptiEventDomainGetNumEvents(@Cast("CUpti_EventDomainID") int eventDomain, + @Cast("uint32_t*") int[] numEvents); + +/** + * \brief Get the events in a domain. + * + * Returns the event IDs in \p eventArray for a domain. The size of + * the \p eventArray buffer is given by \p *arraySizeBytes. The size + * of the \p eventArray buffer must be at least \p numdomainevents * + * sizeof(CUpti_EventID) or else all events will not be returned. The + * value returned in \p *arraySizeBytes contains the number of bytes + * returned in \p eventArray. + * \note \b Thread-safety: this function is thread safe. + * + * @param eventDomain ID of the event domain + * @param arraySizeBytes The size of \p eventArray in bytes, and + * returns the number of bytes written to \p eventArray + * @param eventArray Returns the IDs of the events in the domain + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_EVENT_DOMAIN_ID + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p arraySizeBytes or \p + * eventArray are NULL + */ +public static native @Cast("CUptiResult") int cuptiEventDomainEnumEvents(@Cast("CUpti_EventDomainID") int eventDomain, + @Cast("size_t*") SizeTPointer arraySizeBytes, + @Cast("CUpti_EventID*") IntPointer eventArray); +public static native @Cast("CUptiResult") int cuptiEventDomainEnumEvents(@Cast("CUpti_EventDomainID") int eventDomain, + @Cast("size_t*") SizeTPointer arraySizeBytes, + @Cast("CUpti_EventID*") int[] eventArray); + +/** + * \brief Get an event attribute. + * + * Returns an event attribute in \p *value. The size of the \p + * value buffer is given by \p *valueSize. The value returned in \p + * *valueSize contains the number of bytes returned in \p value. + * + * If the attribute value is a c-string that is longer than \p + * *valueSize, then only the first \p *valueSize characters will be + * returned and there will be no terminating null byte. + * \note \b Thread-safety: this function is thread safe. + * + * @param event ID of the event + * @param attrib The event attribute to read + * @param valueSize The size of the \p value buffer in bytes, and + * returns the number of bytes written to \p value + * @param value Returns the attribute's value + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_EVENT_ID + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p valueSize or \p value + * is NULL, or if \p attrib is not an event attribute + * \retval CUPTI_ERROR_PARAMETER_SIZE_NOT_SUFFICIENT For non-c-string + * attribute values, indicates that the \p value buffer is too small + * to hold the attribute value. + */ +public static native @Cast("CUptiResult") int cuptiEventGetAttribute(@Cast("CUpti_EventID") int event, + @Cast("CUpti_EventAttribute") int attrib, + @Cast("size_t*") SizeTPointer valueSize, + Pointer value); + +/** + * \brief Find an event by name. + * + * Find an event by name and return the event ID in \p *event. + * \note \b Thread-safety: this function is thread safe. + * + * @param device The CUDA device + * @param eventName The name of the event to find + * @param event Returns the ID of the found event or undefined if + * unable to find the event + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_DEVICE + * \retval CUPTI_ERROR_INVALID_EVENT_NAME if unable to find an event + * with name \p eventName. In this case \p *event is undefined + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p eventName or \p event are NULL + */ +public static native @Cast("CUptiResult") int cuptiEventGetIdFromName(@Cast("CUdevice") int device, + @Cast("const char*") BytePointer eventName, + @Cast("CUpti_EventID*") IntPointer event); +public static native @Cast("CUptiResult") int cuptiEventGetIdFromName(@Cast("CUdevice") int device, + String eventName, + @Cast("CUpti_EventID*") int[] event); + +/** + * \brief Create a new event group for a context. + * + * Creates a new event group for \p context and returns the new group + * in \p *eventGroup. + * \note \p flags are reserved for future use and should be set to zero. + * \note \b Thread-safety: this function is thread safe. + * + * @param context The context for the event group + * @param eventGroup Returns the new event group + * @param flags Reserved - must be zero + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_CONTEXT + * \retval CUPTI_ERROR_OUT_OF_MEMORY + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p eventGroup is NULL + */ +public static native @Cast("CUptiResult") int cuptiEventGroupCreate(CUctx_st context, + @ByPtrPtr CUpti_EventGroup eventGroup, + @Cast("uint32_t") int flags); + +/** + * \brief Destroy an event group. + * + * Destroy an \p eventGroup and free its resources. An event group + * cannot be destroyed if it is enabled. + * \note \b Thread-safety: this function is thread safe. + * + * @param eventGroup The event group to destroy + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_OPERATION if the event group is enabled + * \retval CUPTI_ERROR_INVALID_PARAMETER if eventGroup is NULL + */ +public static native @Cast("CUptiResult") int cuptiEventGroupDestroy(CUpti_EventGroup eventGroup); + +/** + * \brief Read an event group attribute. + * + * Read an event group attribute and return it in \p *value. + * \note \b Thread-safety: this function is thread safe but client + * must guard against simultaneous destruction or modification of \p + * eventGroup (for example, client must guard against simultaneous + * calls to \ref cuptiEventGroupDestroy, \ref cuptiEventGroupAddEvent, + * etc.), and must guard against simultaneous destruction of the + * context in which \p eventGroup was created (for example, client + * must guard against simultaneous calls to cudaDeviceReset, + * cuCtxDestroy, etc.). + * + * @param eventGroup The event group + * @param attrib The attribute to read + * @param valueSize Size of buffer pointed by the value, and + * returns the number of bytes written to \p value + * @param value Returns the value of the attribute + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p valueSize or \p value + * is NULL, or if \p attrib is not an eventgroup attribute + * \retval CUPTI_ERROR_PARAMETER_SIZE_NOT_SUFFICIENT For non-c-string + * attribute values, indicates that the \p value buffer is too small + * to hold the attribute value. + */ +public static native @Cast("CUptiResult") int cuptiEventGroupGetAttribute(CUpti_EventGroup eventGroup, + @Cast("CUpti_EventGroupAttribute") int attrib, + @Cast("size_t*") SizeTPointer valueSize, + Pointer value); + +/** + * \brief Write an event group attribute. + * + * Write an event group attribute. + * \note \b Thread-safety: this function is thread safe. + * + * @param eventGroup The event group + * @param attrib The attribute to write + * @param valueSize The size, in bytes, of the value + * @param value The attribute value to write + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p valueSize or \p value + * is NULL, or if \p attrib is not an event group attribute, or if + * \p attrib is not a writable attribute + * \retval CUPTI_ERROR_PARAMETER_SIZE_NOT_SUFFICIENT Indicates that + * the \p value buffer is too small to hold the attribute value. + */ +public static native @Cast("CUptiResult") int cuptiEventGroupSetAttribute(CUpti_EventGroup eventGroup, + @Cast("CUpti_EventGroupAttribute") int attrib, + @Cast("size_t") long valueSize, + Pointer value); + +/** + * \brief Add an event to an event group. + * + * Add an event to an event group. The event add can fail for a number of reasons: + * \li The event group is enabled + * \li The event does not belong to the same event domain as the + * events that are already in the event group + * \li Device limitations on the events that can belong to the same group + * \li The event group is full + * + * \note \b Thread-safety: this function is thread safe. + * + * @param eventGroup The event group + * @param event The event to add to the group + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_EVENT_ID + * \retval CUPTI_ERROR_OUT_OF_MEMORY + * \retval CUPTI_ERROR_INVALID_OPERATION if \p eventGroup is enabled + * \retval CUPTI_ERROR_NOT_COMPATIBLE if \p event belongs to a + * different event domain than the events already in \p eventGroup, or + * if a device limitation prevents \p event from being collected at + * the same time as the events already in \p eventGroup + * \retval CUPTI_ERROR_MAX_LIMIT_REACHED if \p eventGroup is full + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p eventGroup is NULL + */ +public static native @Cast("CUptiResult") int cuptiEventGroupAddEvent(CUpti_EventGroup eventGroup, + @Cast("CUpti_EventID") int event); + +/** + * \brief Remove an event from an event group. + * + * Remove \p event from the an event group. The event cannot be + * removed if the event group is enabled. + * \note \b Thread-safety: this function is thread safe. + * + * @param eventGroup The event group + * @param event The event to remove from the group + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_EVENT_ID + * \retval CUPTI_ERROR_INVALID_OPERATION if \p eventGroup is enabled + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p eventGroup is NULL + */ +public static native @Cast("CUptiResult") int cuptiEventGroupRemoveEvent(CUpti_EventGroup eventGroup, + @Cast("CUpti_EventID") int event); + +/** + * \brief Remove all events from an event group. + * + * Remove all events from an event group. Events cannot be removed if + * the event group is enabled. + * \note \b Thread-safety: this function is thread safe. + * + * @param eventGroup The event group + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_OPERATION if \p eventGroup is enabled + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p eventGroup is NULL + */ +public static native @Cast("CUptiResult") int cuptiEventGroupRemoveAllEvents(CUpti_EventGroup eventGroup); + +/** + * \brief Zero all the event counts in an event group. + * + * Zero all the event counts in an event group. + * \note \b Thread-safety: this function is thread safe but client + * must guard against simultaneous destruction or modification of \p + * eventGroup (for example, client must guard against simultaneous + * calls to \ref cuptiEventGroupDestroy, \ref cuptiEventGroupAddEvent, + * etc.), and must guard against simultaneous destruction of the + * context in which \p eventGroup was created (for example, client + * must guard against simultaneous calls to cudaDeviceReset, + * cuCtxDestroy, etc.). + * + * @param eventGroup The event group + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_HARDWARE + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p eventGroup is NULL + */ +public static native @Cast("CUptiResult") int cuptiEventGroupResetAllEvents(CUpti_EventGroup eventGroup); + +/** + * \brief Enable an event group. + * + * Enable an event group. Enabling an event group zeros the value of + * all the events in the group and then starts collection of those + * events. + * \note \b Thread-safety: this function is thread safe. + * + * @param eventGroup The event group + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_HARDWARE + * \retval CUPTI_ERROR_NOT_READY if \p eventGroup does not contain any events + * \retval CUPTI_ERROR_NOT_COMPATIBLE if \p eventGroup cannot be + * enabled due to other already enabled event groups + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p eventGroup is NULL + * \retval CUPTI_ERROR_HARDWARE_BUSY if another client is profiling + * and hardware is busy + */ +public static native @Cast("CUptiResult") int cuptiEventGroupEnable(CUpti_EventGroup eventGroup); + +/** + * \brief Disable an event group. + * + * Disable an event group. Disabling an event group stops collection + * of events contained in the group. + * \note \b Thread-safety: this function is thread safe. + * + * @param eventGroup The event group + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_HARDWARE + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p eventGroup is NULL + */ +public static native @Cast("CUptiResult") int cuptiEventGroupDisable(CUpti_EventGroup eventGroup); + +/** + * \brief Read the value for an event in an event group. + * + * Read the value for an event in an event group. The event value is + * returned in the \p eventValueBuffer buffer. \p + * eventValueBufferSizeBytes indicates the size of the \p + * eventValueBuffer buffer. The buffer must be at least sizeof(uint64) + * if ::CUPTI_EVENT_GROUP_ATTR_PROFILE_ALL_DOMAIN_INSTANCES is not set + * on the group containing the event. The buffer must be at least + * (sizeof(uint64) * number of domain instances) if + * ::CUPTI_EVENT_GROUP_ATTR_PROFILE_ALL_DOMAIN_INSTANCES is set on the + * group. + * + * If any instance of an event counter overflows, the value returned + * for that event instance will be ::CUPTI_EVENT_OVERFLOW. + * + * The only allowed value for \p flags is ::CUPTI_EVENT_READ_FLAG_NONE. + * + * Reading an event from a disabled event group is not allowed. After + * being read, an event's value is reset to zero. + * \note \b Thread-safety: this function is thread safe but client + * must guard against simultaneous destruction or modification of \p + * eventGroup (for example, client must guard against simultaneous + * calls to \ref cuptiEventGroupDestroy, \ref cuptiEventGroupAddEvent, + * etc.), and must guard against simultaneous destruction of the + * context in which \p eventGroup was created (for example, client + * must guard against simultaneous calls to cudaDeviceReset, + * cuCtxDestroy, etc.). If \ref cuptiEventGroupResetAllEvents is + * called simultaneously with this function, then returned event + * values are undefined. + * + * @param eventGroup The event group + * @param flags Flags controlling the reading mode + * @param event The event to read + * @param eventValueBufferSizeBytes The size of \p eventValueBuffer + * in bytes, and returns the number of bytes written to \p + * eventValueBuffer + * @param eventValueBuffer Returns the event value(s) + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_EVENT_ID + * \retval CUPTI_ERROR_HARDWARE + * \retval CUPTI_ERROR_INVALID_OPERATION if \p eventGroup is disabled + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p eventGroup, \p + * eventValueBufferSizeBytes or \p eventValueBuffer is NULL + * \retval CUPTI_ERROR_PARAMETER_SIZE_NOT_SUFFICIENT if size of \p eventValueBuffer + * is not sufficient + */ +public static native @Cast("CUptiResult") int cuptiEventGroupReadEvent(CUpti_EventGroup eventGroup, + @Cast("CUpti_ReadEventFlags") int flags, + @Cast("CUpti_EventID") int event, + @Cast("size_t*") SizeTPointer eventValueBufferSizeBytes, + @Cast("uint64_t*") LongPointer eventValueBuffer); +public static native @Cast("CUptiResult") int cuptiEventGroupReadEvent(CUpti_EventGroup eventGroup, + @Cast("CUpti_ReadEventFlags") int flags, + @Cast("CUpti_EventID") int event, + @Cast("size_t*") SizeTPointer eventValueBufferSizeBytes, + @Cast("uint64_t*") LongBuffer eventValueBuffer); +public static native @Cast("CUptiResult") int cuptiEventGroupReadEvent(CUpti_EventGroup eventGroup, + @Cast("CUpti_ReadEventFlags") int flags, + @Cast("CUpti_EventID") int event, + @Cast("size_t*") SizeTPointer eventValueBufferSizeBytes, + @Cast("uint64_t*") long[] eventValueBuffer); + +/** + * \brief Read the values for all the events in an event group. + * + * Read the values for all the events in an event group. The event + * values are returned in the \p eventValueBuffer buffer. \p + * eventValueBufferSizeBytes indicates the size of \p + * eventValueBuffer. The buffer must be at least (sizeof(uint64) * + * number of events in group) if + * ::CUPTI_EVENT_GROUP_ATTR_PROFILE_ALL_DOMAIN_INSTANCES is not set on + * the group containing the events. The buffer must be at least + * (sizeof(uint64) * number of domain instances * number of events in + * group) if ::CUPTI_EVENT_GROUP_ATTR_PROFILE_ALL_DOMAIN_INSTANCES is + * set on the group. + * + * The data format returned in \p eventValueBuffer is: + * - domain instance 0: event0 event1 ... eventN + * - domain instance 1: event0 event1 ... eventN + * - ... + * - domain instance M: event0 event1 ... eventN + * + * The event order in \p eventValueBuffer is returned in \p + * eventIdArray. The size of \p eventIdArray is specified in \p + * eventIdArraySizeBytes. The size should be at least + * (sizeof(CUpti_EventID) * number of events in group). + * + * If any instance of any event counter overflows, the value returned + * for that event instance will be ::CUPTI_EVENT_OVERFLOW. + * + * The only allowed value for \p flags is ::CUPTI_EVENT_READ_FLAG_NONE. + * + * Reading events from a disabled event group is not allowed. After + * being read, an event's value is reset to zero. + * \note \b Thread-safety: this function is thread safe but client + * must guard against simultaneous destruction or modification of \p + * eventGroup (for example, client must guard against simultaneous + * calls to \ref cuptiEventGroupDestroy, \ref cuptiEventGroupAddEvent, + * etc.), and must guard against simultaneous destruction of the + * context in which \p eventGroup was created (for example, client + * must guard against simultaneous calls to cudaDeviceReset, + * cuCtxDestroy, etc.). If \ref cuptiEventGroupResetAllEvents is + * called simultaneously with this function, then returned event + * values are undefined. + * + * @param eventGroup The event group + * @param flags Flags controlling the reading mode + * @param eventValueBufferSizeBytes The size of \p eventValueBuffer in + * bytes, and returns the number of bytes written to \p + * eventValueBuffer + * @param eventValueBuffer Returns the event values + * @param eventIdArraySizeBytes The size of \p eventIdArray in bytes, + * and returns the number of bytes written to \p eventIdArray + * @param eventIdArray Returns the IDs of the events in the same order + * as the values return in eventValueBuffer. + * @param numEventIdsRead Returns the number of event IDs returned + * in \p eventIdArray + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_HARDWARE + * \retval CUPTI_ERROR_INVALID_OPERATION if \p eventGroup is disabled + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p eventGroup, \p + * eventValueBufferSizeBytes, \p eventValueBuffer, \p + * eventIdArraySizeBytes, \p eventIdArray or \p numEventIdsRead is + * NULL + * \retval CUPTI_ERROR_PARAMETER_SIZE_NOT_SUFFICIENT if size of \p eventValueBuffer + * or \p eventIdArray is not sufficient + */ +public static native @Cast("CUptiResult") int cuptiEventGroupReadAllEvents(CUpti_EventGroup eventGroup, + @Cast("CUpti_ReadEventFlags") int flags, + @Cast("size_t*") SizeTPointer eventValueBufferSizeBytes, + @Cast("uint64_t*") LongPointer eventValueBuffer, + @Cast("size_t*") SizeTPointer eventIdArraySizeBytes, + @Cast("CUpti_EventID*") IntPointer eventIdArray, + @Cast("size_t*") SizeTPointer numEventIdsRead); +public static native @Cast("CUptiResult") int cuptiEventGroupReadAllEvents(CUpti_EventGroup eventGroup, + @Cast("CUpti_ReadEventFlags") int flags, + @Cast("size_t*") SizeTPointer eventValueBufferSizeBytes, + @Cast("uint64_t*") LongBuffer eventValueBuffer, + @Cast("size_t*") SizeTPointer eventIdArraySizeBytes, + @Cast("CUpti_EventID*") int[] eventIdArray, + @Cast("size_t*") SizeTPointer numEventIdsRead); +public static native @Cast("CUptiResult") int cuptiEventGroupReadAllEvents(CUpti_EventGroup eventGroup, + @Cast("CUpti_ReadEventFlags") int flags, + @Cast("size_t*") SizeTPointer eventValueBufferSizeBytes, + @Cast("uint64_t*") long[] eventValueBuffer, + @Cast("size_t*") SizeTPointer eventIdArraySizeBytes, + @Cast("CUpti_EventID*") IntPointer eventIdArray, + @Cast("size_t*") SizeTPointer numEventIdsRead); +public static native @Cast("CUptiResult") int cuptiEventGroupReadAllEvents(CUpti_EventGroup eventGroup, + @Cast("CUpti_ReadEventFlags") int flags, + @Cast("size_t*") SizeTPointer eventValueBufferSizeBytes, + @Cast("uint64_t*") LongPointer eventValueBuffer, + @Cast("size_t*") SizeTPointer eventIdArraySizeBytes, + @Cast("CUpti_EventID*") int[] eventIdArray, + @Cast("size_t*") SizeTPointer numEventIdsRead); +public static native @Cast("CUptiResult") int cuptiEventGroupReadAllEvents(CUpti_EventGroup eventGroup, + @Cast("CUpti_ReadEventFlags") int flags, + @Cast("size_t*") SizeTPointer eventValueBufferSizeBytes, + @Cast("uint64_t*") LongBuffer eventValueBuffer, + @Cast("size_t*") SizeTPointer eventIdArraySizeBytes, + @Cast("CUpti_EventID*") IntPointer eventIdArray, + @Cast("size_t*") SizeTPointer numEventIdsRead); +public static native @Cast("CUptiResult") int cuptiEventGroupReadAllEvents(CUpti_EventGroup eventGroup, + @Cast("CUpti_ReadEventFlags") int flags, + @Cast("size_t*") SizeTPointer eventValueBufferSizeBytes, + @Cast("uint64_t*") long[] eventValueBuffer, + @Cast("size_t*") SizeTPointer eventIdArraySizeBytes, + @Cast("CUpti_EventID*") int[] eventIdArray, + @Cast("size_t*") SizeTPointer numEventIdsRead); + +/** + * \brief For a set of events, get the grouping that indicates the + * number of passes and the event groups necessary to collect the + * events. + * + * The number of events that can be collected simultaneously varies by + * device and by the type of the events. When events can be collected + * simultaneously, they may need to be grouped into multiple event + * groups because they are from different event domains. This function + * takes a set of events and determines how many passes are required + * to collect all those events, and which events can be collected + * simultaneously in each pass. + * + * The CUpti_EventGroupSets returned in \p eventGroupPasses indicates + * how many passes are required to collect the events with the \p + * numSets field. Within each event group set, the \p sets array + * indicates the event groups that should be collected on each pass. + * \note \b Thread-safety: this function is thread safe, but client + * must guard against another thread simultaneously destroying \p + * context. + * + * @param context The context for event collection + * @param eventIdArraySizeBytes Size of \p eventIdArray in bytes + * @param eventIdArray Array of event IDs that need to be grouped + * @param eventGroupPasses Returns a CUpti_EventGroupSets object that + * indicates the number of passes required to collect the events and + * the events to collect on each pass + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_CONTEXT + * \retval CUPTI_ERROR_INVALID_EVENT_ID + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p eventIdArray or + * \p eventGroupPasses is NULL + */ +public static native @Cast("CUptiResult") int cuptiEventGroupSetsCreate(CUctx_st context, + @Cast("size_t") long eventIdArraySizeBytes, + @Cast("CUpti_EventID*") IntPointer eventIdArray, + @Cast("CUpti_EventGroupSets**") PointerPointer eventGroupPasses); +public static native @Cast("CUptiResult") int cuptiEventGroupSetsCreate(CUctx_st context, + @Cast("size_t") long eventIdArraySizeBytes, + @Cast("CUpti_EventID*") IntPointer eventIdArray, + @ByPtrPtr CUpti_EventGroupSets eventGroupPasses); +public static native @Cast("CUptiResult") int cuptiEventGroupSetsCreate(CUctx_st context, + @Cast("size_t") long eventIdArraySizeBytes, + @Cast("CUpti_EventID*") int[] eventIdArray, + @ByPtrPtr CUpti_EventGroupSets eventGroupPasses); + +/** + * \brief Destroy a event group sets object. + * + * Destroy a CUpti_EventGroupSets object. + * \note \b Thread-safety: this function is thread safe. + * + * @param eventGroupSets The object to destroy + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_OPERATION if any of the event groups + * contained in the sets is enabled + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p eventGroupSets is NULL + */ +public static native @Cast("CUptiResult") int cuptiEventGroupSetsDestroy(CUpti_EventGroupSets eventGroupSets); + + +/** + * \brief Enable an event group set. + * + * Enable a set of event groups. Enabling a set of event groups zeros the value of + * all the events in all the groups and then starts collection of those events. + * \note \b Thread-safety: this function is thread safe. + * + * @param eventGroupSet The pointer to the event group set + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_HARDWARE + * \retval CUPTI_ERROR_NOT_READY if \p eventGroup does not contain any events + * \retval CUPTI_ERROR_NOT_COMPATIBLE if \p eventGroup cannot be + * enabled due to other already enabled event groups + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p eventGroupSet is NULL + * \retval CUPTI_ERROR_HARDWARE_BUSY if other client is profiling and hardware is + * busy + */ +public static native @Cast("CUptiResult") int cuptiEventGroupSetEnable(CUpti_EventGroupSet eventGroupSet); + +/** + * \brief Disable an event group set. + * + * Disable a set of event groups. Disabling a set of event groups + * stops collection of events contained in the groups. + * \note \b Thread-safety: this function is thread safe. + * \note \b If this call fails, some of the event groups in the set may be disabled + * and other event groups may remain enabled. + * + * @param eventGroupSet The pointer to the event group set + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_HARDWARE + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p eventGroupSet is NULL + */ +public static native @Cast("CUptiResult") int cuptiEventGroupSetDisable(CUpti_EventGroupSet eventGroupSet); + +/** + * \brief Enable kernel replay mode. + * + * Set profiling mode for the context to replay mode. In this mode, + * any number of events can be collected in one run of the kernel. The + * event collection mode will automatically switch to + * CUPTI_EVENT_COLLECTION_MODE_KERNEL. In this mode, \ref + * cuptiSetEventCollectionMode will return + * CUPTI_ERROR_INVALID_OPERATION. + * \note \b Kernels might take longer to run if many events are enabled. + * \note \b Thread-safety: this function is thread safe. + * + * @param context The context + * \retval CUPTI_SUCCESS + */ +public static native @Cast("CUptiResult") int cuptiEnableKernelReplayMode(CUctx_st context); + +/** + * \brief Disable kernel replay mode. + * + * Set profiling mode for the context to non-replay (default) + * mode. Event collection mode will be set to + * CUPTI_EVENT_COLLECTION_MODE_KERNEL. All previously enabled + * event groups and event group sets will be disabled. + * \note \b Thread-safety: this function is thread safe. + * + * @param context The context + * \retval CUPTI_SUCCESS + */ +public static native @Cast("CUptiResult") int cuptiDisableKernelReplayMode(CUctx_st context); +// Targeting ../cupti/CUpti_KernelReplayUpdateFunc.java + + + +/** + * \brief Subscribe to kernel replay updates. + * + * When subscribed, the function pointer passed in will be called each time a + * kernel run is finished during kernel replay. Previously subscribed function + * pointer will be replaced. Pass in NULL as the function pointer unsubscribes + * the update. + * + * @param updateFunc The update function pointer + * @param customData Pointer to any custom data + * \retval CUPTI_SUCCESS + */ +public static native @Cast("CUptiResult") int cuptiKernelReplaySubscribeUpdate(CUpti_KernelReplayUpdateFunc updateFunc, Pointer customData); + +/** \} */ /* END CUPTI_EVENT_API */ + +// #if defined(__GNUC__) && defined(CUPTI_LIB) +// #pragma GCC visibility pop +// #endif + +// #if defined(__cplusplus) +// #endif + +// #endif /*_CUPTI_EVENTS_H_*/ + + + + +// Parsed from cupti_metrics.h + +/* + * Copyright 2011-2020 NVIDIA Corporation. All rights reserved. + * + * NOTICE TO LICENSEE: + * + * This source code and/or documentation ("Licensed Deliverables") are + * subject to NVIDIA intellectual property rights under U.S. and + * international Copyright laws. + * + * These Licensed Deliverables contained herein is PROPRIETARY and + * CONFIDENTIAL to NVIDIA and is being provided under the terms and + * conditions of a form of NVIDIA software license agreement by and + * between NVIDIA and Licensee ("License Agreement") or electronically + * accepted by Licensee. Notwithstanding any terms or conditions to + * the contrary in the License Agreement, reproduction or disclosure + * of the Licensed Deliverables to any third party without the express + * written consent of NVIDIA is prohibited. + * + * NOTWITHSTANDING ANY TERMS OR CONDITIONS TO THE CONTRARY IN THE + * LICENSE AGREEMENT, NVIDIA MAKES NO REPRESENTATION ABOUT THE + * SUITABILITY OF THESE LICENSED DELIVERABLES FOR ANY PURPOSE. IT IS + * PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY OF ANY KIND. + * NVIDIA DISCLAIMS ALL WARRANTIES WITH REGARD TO THESE LICENSED + * DELIVERABLES, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY, + * NONINFRINGEMENT, AND FITNESS FOR A PARTICULAR PURPOSE. + * NOTWITHSTANDING ANY TERMS OR CONDITIONS TO THE CONTRARY IN THE + * LICENSE AGREEMENT, IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY + * SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, OR ANY + * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, + * WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS + * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE + * OF THESE LICENSED DELIVERABLES. + * + * U.S. Government End Users. These Licensed Deliverables are a + * "commercial item" as that term is defined at 48 C.F.R. 2.101 (OCT + * 1995), consisting of "commercial computer software" and "commercial + * computer software documentation" as such terms are used in 48 + * C.F.R. 12.212 (SEPT 1995) and is provided to the U.S. Government + * only as a commercial end item. Consistent with 48 C.F.R.12.212 and + * 48 C.F.R. 227.7202-1 through 227.7202-4 (JUNE 1995), all + * U.S. Government End Users acquire the Licensed Deliverables with + * only those rights set forth herein. + * + * Any use of the Licensed Deliverables in individual and commercial + * software must include, in the user documentation and internal + * comments to the code, the above Disclaimer and U.S. Government End + * Users Notice. + */ + +// #if !defined(_CUPTI_METRIC_H_) +// #define _CUPTI_METRIC_H_ + +// #include +// #include +// #include +// #include + +// #ifndef CUPTIAPI +// #ifdef _WIN32 +// #define CUPTIAPI __stdcall +// #else +// #define CUPTIAPI +// #endif +// #endif + +// #if defined(__cplusplus) +// #endif + +// #if defined(__GNUC__) && defined(CUPTI_LIB) +// #pragma GCC visibility push(default) +// #endif + +/** + * \defgroup CUPTI_METRIC_API CUPTI Metric API + * Functions, types, and enums that implement the CUPTI Metric API. + * + * \note CUPTI metric API from the header cupti_metrics.h are not supported on devices + * with compute capability 7.5 and higher (i.e. Turing and later GPU architectures). + * These API will be deprecated in a future CUDA release. These are replaced by + * Profiling API in the header cupti_profiler_target.h and Perfworks metrics API + * in the headers nvperf_host.h and nvperf_target.h which are supported on + * devices with compute capability 7.0 and higher (i.e. Volta and later GPU + * architectures). + * + * \{ + */ + +/** + * \brief ID for a metric. + * + * A metric provides a measure of some aspect of the device. + */ + +/** + * \brief A metric category. + * + * Each metric is assigned to a category that represents the general + * type of the metric. A metric's category is accessed using \ref + * cuptiMetricGetAttribute and the CUPTI_METRIC_ATTR_CATEGORY + * attribute. + */ +/** enum CUpti_MetricCategory */ +public static final int + /** + * A memory related metric. + */ + CUPTI_METRIC_CATEGORY_MEMORY = 0, + /** + * An instruction related metric. + */ + CUPTI_METRIC_CATEGORY_INSTRUCTION = 1, + /** + * A multiprocessor related metric. + */ + CUPTI_METRIC_CATEGORY_MULTIPROCESSOR = 2, + /** + * A cache related metric. + */ + CUPTI_METRIC_CATEGORY_CACHE = 3, + /** + * A texture related metric. + */ + CUPTI_METRIC_CATEGORY_TEXTURE = 4, + /** + *A Nvlink related metric. + */ + CUPTI_METRIC_CATEGORY_NVLINK = 5, + /** + *A PCIe related metric. + */ + CUPTI_METRIC_CATEGORY_PCIE = 6, + CUPTI_METRIC_CATEGORY_FORCE_INT = 0x7fffffff; + +/** + * \brief A metric evaluation mode. + * + * A metric can be evaluated per hardware instance to know the load balancing + * across instances of a domain or the metric can be evaluated in aggregate mode + * when the events involved in metric evaluation are from different event + * domains. It might be possible to evaluate some metrics in both + * modes for convenience. A metric's evaluation mode is accessed using \ref + * CUpti_MetricEvaluationMode and the CUPTI_METRIC_ATTR_EVALUATION_MODE + * attribute. + */ +/** enum CUpti_MetricEvaluationMode */ +public static final int + /** + * If this bit is set, the metric can be profiled for each instance of the + * domain. The event values passed to \ref cuptiMetricGetValue can contain + * values for one instance of the domain. And \ref cuptiMetricGetValue can + * be called for each instance. + */ + CUPTI_METRIC_EVALUATION_MODE_PER_INSTANCE = 1, + /** + * If this bit is set, the metric can be profiled over all instances. The + * event values passed to \ref cuptiMetricGetValue can be aggregated values + * of events for all instances of the domain. + */ + CUPTI_METRIC_EVALUATION_MODE_AGGREGATE = 1 << 1, + CUPTI_METRIC_EVALUATION_MODE_FORCE_INT = 0x7fffffff; + +/** + * \brief Kinds of metric values. + * + * Metric values can be one of several different kinds. Corresponding + * to each kind is a member of the CUpti_MetricValue union. The metric + * value returned by \ref cuptiMetricGetValue should be accessed using + * the appropriate member of that union based on its value kind. + */ +/** enum CUpti_MetricValueKind */ +public static final int + /** + * The metric value is a 64-bit double. + */ + CUPTI_METRIC_VALUE_KIND_DOUBLE = 0, + /** + * The metric value is a 64-bit unsigned integer. + */ + CUPTI_METRIC_VALUE_KIND_UINT64 = 1, + /** + * The metric value is a percentage represented by a 64-bit + * double. For example, 57.5% is represented by the value 57.5. + */ + CUPTI_METRIC_VALUE_KIND_PERCENT = 2, + /** + * The metric value is a throughput represented by a 64-bit + * integer. The unit for throughput values is bytes/second. + */ + CUPTI_METRIC_VALUE_KIND_THROUGHPUT = 3, + /** + * The metric value is a 64-bit signed integer. + */ + CUPTI_METRIC_VALUE_KIND_INT64 = 4, + /** + * The metric value is a utilization level, as represented by + * CUpti_MetricValueUtilizationLevel. + */ + CUPTI_METRIC_VALUE_KIND_UTILIZATION_LEVEL = 5, + + CUPTI_METRIC_VALUE_KIND_FORCE_INT = 0x7fffffff; + +/** + * \brief Enumeration of utilization levels for metrics values of kind + * CUPTI_METRIC_VALUE_KIND_UTILIZATION_LEVEL. Utilization values can + * vary from IDLE (0) to MAX (10) but the enumeration only provides + * specific names for a few values. + */ +/** enum CUpti_MetricValueUtilizationLevel */ +public static final int + CUPTI_METRIC_VALUE_UTILIZATION_IDLE = 0, + CUPTI_METRIC_VALUE_UTILIZATION_LOW = 2, + CUPTI_METRIC_VALUE_UTILIZATION_MID = 5, + CUPTI_METRIC_VALUE_UTILIZATION_HIGH = 8, + CUPTI_METRIC_VALUE_UTILIZATION_MAX = 10, + CUPTI_METRIC_VALUE_UTILIZATION_FORCE_INT = 0x7fffffff; + +/** + * \brief Metric attributes. + * + * Metric attributes describe properties of a metric. These attributes + * can be read using \ref cuptiMetricGetAttribute. + */ +/** enum CUpti_MetricAttribute */ +public static final int + /** + * Metric name. Value is a null terminated const c-string. + */ + CUPTI_METRIC_ATTR_NAME = 0, + /** + * Short description of metric. Value is a null terminated const c-string. + */ + CUPTI_METRIC_ATTR_SHORT_DESCRIPTION = 1, + /** + * Long description of metric. Value is a null terminated const c-string. + */ + CUPTI_METRIC_ATTR_LONG_DESCRIPTION = 2, + /** + * Category of the metric. Value is of type CUpti_MetricCategory. + */ + CUPTI_METRIC_ATTR_CATEGORY = 3, + /** + * Value type of the metric. Value is of type CUpti_MetricValueKind. + */ + CUPTI_METRIC_ATTR_VALUE_KIND = 4, + /** + * Metric evaluation mode. Value is of type CUpti_MetricEvaluationMode. + */ + CUPTI_METRIC_ATTR_EVALUATION_MODE = 5, + CUPTI_METRIC_ATTR_FORCE_INT = 0x7fffffff; +// Targeting ../cupti/CUpti_MetricValue.java + + + +/** + * \brief Device class. + * + * Enumeration of device classes for metric property + * CUPTI_METRIC_PROPERTY_DEVICE_CLASS. + */ +/** enum CUpti_MetricPropertyDeviceClass */ +public static final int + CUPTI_METRIC_PROPERTY_DEVICE_CLASS_TESLA = 0, + CUPTI_METRIC_PROPERTY_DEVICE_CLASS_QUADRO = 1, + CUPTI_METRIC_PROPERTY_DEVICE_CLASS_GEFORCE = 2, + CUPTI_METRIC_PROPERTY_DEVICE_CLASS_TEGRA = 3; + +/** + * \brief Metric device properties. + * + * Metric device properties describe device properties which are needed for a metric. + * Some of these properties can be collected using cuDeviceGetAttribute. + */ +/** enum CUpti_MetricPropertyID */ +public static final int + /* + * Number of multiprocessors on a device. This can be collected + * using value of \param CU_DEVICE_ATTRIBUTE_MULTIPROCESSOR_COUNT of + * cuDeviceGetAttribute. + */ + CUPTI_METRIC_PROPERTY_MULTIPROCESSOR_COUNT = 0, + /* + * Maximum number of warps on a multiprocessor. This can be + * collected using ratio of value of \param + * CU_DEVICE_ATTRIBUTE_MAX_THREADS_PER_MULTIPROCESSOR and \param + * CU_DEVICE_ATTRIBUTE_WARP_SIZE of cuDeviceGetAttribute. + */ + CUPTI_METRIC_PROPERTY_WARPS_PER_MULTIPROCESSOR = 1, + /* + * GPU Time for kernel in ns. This should be profiled using CUPTI + * Activity API. + */ + CUPTI_METRIC_PROPERTY_KERNEL_GPU_TIME = 2, + /* + * Clock rate for device in KHz. This should be collected using + * value of \param CU_DEVICE_ATTRIBUTE_CLOCK_RATE of + * cuDeviceGetAttribute. + */ + CUPTI_METRIC_PROPERTY_CLOCK_RATE = 3, + /* + * Number of Frame buffer units for device. This should be collected + * using value of \param CUPTI_DEVICE_ATTRIBUTE_MAX_FRAME_BUFFERS of + * cuptiDeviceGetAttribute. + */ + CUPTI_METRIC_PROPERTY_FRAME_BUFFER_COUNT = 4, + /* + * Global memory bandwidth in KBytes/sec. This should be collected + * using value of \param CUPTI_DEVICE_ATTR_GLOBAL_MEMORY_BANDWIDTH + * of cuptiDeviceGetAttribute. + */ + CUPTI_METRIC_PROPERTY_GLOBAL_MEMORY_BANDWIDTH = 5, + /* + * PCIE link rate in Mega bits/sec. This should be collected using + * value of \param CUPTI_DEVICE_ATTR_PCIE_LINK_RATE of + * cuptiDeviceGetAttribute. + */ + CUPTI_METRIC_PROPERTY_PCIE_LINK_RATE = 6, + /* + * PCIE link width for device. This should be collected using + * value of \param CUPTI_DEVICE_ATTR_PCIE_LINK_WIDTH of + * cuptiDeviceGetAttribute. + */ + CUPTI_METRIC_PROPERTY_PCIE_LINK_WIDTH = 7, + /* + * PCIE generation for device. This should be collected using + * value of \param CUPTI_DEVICE_ATTR_PCIE_GEN of + * cuptiDeviceGetAttribute. + */ + CUPTI_METRIC_PROPERTY_PCIE_GEN = 8, + /* + * The device class. This should be collected using + * value of \param CUPTI_DEVICE_ATTR_DEVICE_CLASS of + * cuptiDeviceGetAttribute. + */ + CUPTI_METRIC_PROPERTY_DEVICE_CLASS = 9, + /* + * Peak single precision floating point operations that + * can be performed in one cycle by the device. + * This should be collected using value of + * \param CUPTI_DEVICE_ATTR_FLOP_SP_PER_CYCLE of + * cuptiDeviceGetAttribute. + */ + CUPTI_METRIC_PROPERTY_FLOP_SP_PER_CYCLE = 10, + /* + * Peak double precision floating point operations that + * can be performed in one cycle by the device. + * This should be collected using value of + * \param CUPTI_DEVICE_ATTR_FLOP_DP_PER_CYCLE of + * cuptiDeviceGetAttribute. + */ + CUPTI_METRIC_PROPERTY_FLOP_DP_PER_CYCLE = 11, + /* + * Number of L2 units on a device. This can be collected + * using value of \param CUPTI_DEVICE_ATTR_MAX_L2_UNITS of + * cuDeviceGetAttribute. + */ + CUPTI_METRIC_PROPERTY_L2_UNITS = 12, + /* + * Whether ECC support is enabled on the device. This can be + * collected using value of \param CU_DEVICE_ATTRIBUTE_ECC_ENABLED of + * cuDeviceGetAttribute. + */ + CUPTI_METRIC_PROPERTY_ECC_ENABLED = 13, + /* + * Peak half precision floating point operations that + * can be performed in one cycle by the device. + * This should be collected using value of + * \param CUPTI_DEVICE_ATTR_FLOP_HP_PER_CYCLE of + * cuptiDeviceGetAttribute. + */ + CUPTI_METRIC_PROPERTY_FLOP_HP_PER_CYCLE = 14, + /* + * NVLINK Bandwitdh for device. This should be collected + * using value of \param CUPTI_DEVICE_ATTR_GPU_CPU_NVLINK_BW of + * cuptiDeviceGetAttribute. + */ + CUPTI_METRIC_PROPERTY_GPU_CPU_NVLINK_BANDWIDTH = 15; + +/** + * \brief Get the total number of metrics available on any device. + * + * Returns the total number of metrics available on any CUDA-capable + * devices. + * + * @param numMetrics Returns the number of metrics + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p numMetrics is NULL +*/ +public static native @Cast("CUptiResult") int cuptiGetNumMetrics(@Cast("uint32_t*") IntPointer numMetrics); +public static native @Cast("CUptiResult") int cuptiGetNumMetrics(@Cast("uint32_t*") IntBuffer numMetrics); +public static native @Cast("CUptiResult") int cuptiGetNumMetrics(@Cast("uint32_t*") int[] numMetrics); + +/** + * \brief Get all the metrics available on any device. + * + * Returns the metric IDs in \p metricArray for all CUDA-capable + * devices. The size of the \p metricArray buffer is given by \p + * *arraySizeBytes. The size of the \p metricArray buffer must be at + * least \p numMetrics * sizeof(CUpti_MetricID) or all metric IDs will + * not be returned. The value returned in \p *arraySizeBytes contains + * the number of bytes returned in \p metricArray. + * + * @param arraySizeBytes The size of \p metricArray in bytes, and + * returns the number of bytes written to \p metricArray + * @param metricArray Returns the IDs of the metrics + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p arraySizeBytes or + * \p metricArray are NULL +*/ +public static native @Cast("CUptiResult") int cuptiEnumMetrics(@Cast("size_t*") SizeTPointer arraySizeBytes, + @Cast("CUpti_MetricID*") IntPointer metricArray); +public static native @Cast("CUptiResult") int cuptiEnumMetrics(@Cast("size_t*") SizeTPointer arraySizeBytes, + @Cast("CUpti_MetricID*") int[] metricArray); + +/** + * \brief Get the number of metrics for a device. + * + * Returns the number of metrics available for a device. + * + * @param device The CUDA device + * @param numMetrics Returns the number of metrics available for the + * device + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_DEVICE + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p numMetrics is NULL + */ +public static native @Cast("CUptiResult") int cuptiDeviceGetNumMetrics(@Cast("CUdevice") int device, + @Cast("uint32_t*") IntPointer numMetrics); +public static native @Cast("CUptiResult") int cuptiDeviceGetNumMetrics(@Cast("CUdevice") int device, + @Cast("uint32_t*") IntBuffer numMetrics); +public static native @Cast("CUptiResult") int cuptiDeviceGetNumMetrics(@Cast("CUdevice") int device, + @Cast("uint32_t*") int[] numMetrics); + +/** + * \brief Get the metrics for a device. + * + * Returns the metric IDs in \p metricArray for a device. The size of + * the \p metricArray buffer is given by \p *arraySizeBytes. The size + * of the \p metricArray buffer must be at least \p numMetrics * + * sizeof(CUpti_MetricID) or else all metric IDs will not be + * returned. The value returned in \p *arraySizeBytes contains the + * number of bytes returned in \p metricArray. + * + * @param device The CUDA device + * @param arraySizeBytes The size of \p metricArray in bytes, and + * returns the number of bytes written to \p metricArray + * @param metricArray Returns the IDs of the metrics for the device + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_DEVICE + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p arraySizeBytes or + * \p metricArray are NULL + */ +public static native @Cast("CUptiResult") int cuptiDeviceEnumMetrics(@Cast("CUdevice") int device, + @Cast("size_t*") SizeTPointer arraySizeBytes, + @Cast("CUpti_MetricID*") IntPointer metricArray); +public static native @Cast("CUptiResult") int cuptiDeviceEnumMetrics(@Cast("CUdevice") int device, + @Cast("size_t*") SizeTPointer arraySizeBytes, + @Cast("CUpti_MetricID*") int[] metricArray); + +/** + * \brief Get a metric attribute. + * + * Returns a metric attribute in \p *value. The size of the \p + * value buffer is given by \p *valueSize. The value returned in \p + * *valueSize contains the number of bytes returned in \p value. + * + * If the attribute value is a c-string that is longer than \p + * *valueSize, then only the first \p *valueSize characters will be + * returned and there will be no terminating null byte. + * + * @param metric ID of the metric + * @param attrib The metric attribute to read + * @param valueSize The size of the \p value buffer in bytes, and + * returns the number of bytes written to \p value + * @param value Returns the attribute's value + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_METRIC_ID + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p valueSize or \p value + * is NULL, or if \p attrib is not a metric attribute + * \retval CUPTI_ERROR_PARAMETER_SIZE_NOT_SUFFICIENT For non-c-string + * attribute values, indicates that the \p value buffer is too small + * to hold the attribute value. + */ +public static native @Cast("CUptiResult") int cuptiMetricGetAttribute(@Cast("CUpti_MetricID") int metric, + @Cast("CUpti_MetricAttribute") int attrib, + @Cast("size_t*") SizeTPointer valueSize, + Pointer value); + +/** + * \brief Find an metric by name. + * + * Find a metric by name and return the metric ID in \p *metric. + * + * @param device The CUDA device + * @param metricName The name of metric to find + * @param metric Returns the ID of the found metric or undefined if + * unable to find the metric + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_DEVICE + * \retval CUPTI_ERROR_INVALID_METRIC_NAME if unable to find a metric + * with name \p metricName. In this case \p *metric is undefined + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p metricName or \p + * metric are NULL. + */ +public static native @Cast("CUptiResult") int cuptiMetricGetIdFromName(@Cast("CUdevice") int device, + @Cast("const char*") BytePointer metricName, + @Cast("CUpti_MetricID*") IntPointer metric); +public static native @Cast("CUptiResult") int cuptiMetricGetIdFromName(@Cast("CUdevice") int device, + String metricName, + @Cast("CUpti_MetricID*") int[] metric); + +/** + * \brief Get number of events required to calculate a metric. + * + * Returns the number of events in \p numEvents that are required to + * calculate a metric. + * + * @param metric ID of the metric + * @param numEvents Returns the number of events required for the metric + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_METRIC_ID + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p numEvents is NULL + */ +public static native @Cast("CUptiResult") int cuptiMetricGetNumEvents(@Cast("CUpti_MetricID") int metric, + @Cast("uint32_t*") IntPointer numEvents); +public static native @Cast("CUptiResult") int cuptiMetricGetNumEvents(@Cast("CUpti_MetricID") int metric, + @Cast("uint32_t*") IntBuffer numEvents); +public static native @Cast("CUptiResult") int cuptiMetricGetNumEvents(@Cast("CUpti_MetricID") int metric, + @Cast("uint32_t*") int[] numEvents); + +/** + * \brief Get the events required to calculating a metric. + * + * Gets the event IDs in \p eventIdArray required to calculate a \p + * metric. The size of the \p eventIdArray buffer is given by \p + * *eventIdArraySizeBytes and must be at least \p numEvents * + * sizeof(CUpti_EventID) or all events will not be returned. The value + * returned in \p *eventIdArraySizeBytes contains the number of bytes + * returned in \p eventIdArray. + * + * @param metric ID of the metric + * @param eventIdArraySizeBytes The size of \p eventIdArray in bytes, + * and returns the number of bytes written to \p eventIdArray + * @param eventIdArray Returns the IDs of the events required to + * calculate \p metric + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_METRIC_ID + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p eventIdArraySizeBytes or \p + * eventIdArray are NULL. + */ +public static native @Cast("CUptiResult") int cuptiMetricEnumEvents(@Cast("CUpti_MetricID") int metric, + @Cast("size_t*") SizeTPointer eventIdArraySizeBytes, + @Cast("CUpti_EventID*") IntPointer eventIdArray); +public static native @Cast("CUptiResult") int cuptiMetricEnumEvents(@Cast("CUpti_MetricID") int metric, + @Cast("size_t*") SizeTPointer eventIdArraySizeBytes, + @Cast("CUpti_EventID*") int[] eventIdArray); + +/** + * \brief Get number of properties required to calculate a metric. + * + * Returns the number of properties in \p numProp that are required to + * calculate a metric. + * + * @param metric ID of the metric + * @param numProp Returns the number of properties required for the + * metric + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_METRIC_ID + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p numProp is NULL + */ +public static native @Cast("CUptiResult") int cuptiMetricGetNumProperties(@Cast("CUpti_MetricID") int metric, + @Cast("uint32_t*") IntPointer numProp); +public static native @Cast("CUptiResult") int cuptiMetricGetNumProperties(@Cast("CUpti_MetricID") int metric, + @Cast("uint32_t*") IntBuffer numProp); +public static native @Cast("CUptiResult") int cuptiMetricGetNumProperties(@Cast("CUpti_MetricID") int metric, + @Cast("uint32_t*") int[] numProp); + +/** + * \brief Get the properties required to calculating a metric. + * + * Gets the property IDs in \p propIdArray required to calculate a \p + * metric. The size of the \p propIdArray buffer is given by \p + * *propIdArraySizeBytes and must be at least \p numProp * + * sizeof(CUpti_DeviceAttribute) or all properties will not be + * returned. The value returned in \p *propIdArraySizeBytes contains + * the number of bytes returned in \p propIdArray. + * + * @param metric ID of the metric + * @param propIdArraySizeBytes The size of \p propIdArray in bytes, + * and returns the number of bytes written to \p propIdArray + * @param propIdArray Returns the IDs of the properties required to + * calculate \p metric + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_METRIC_ID + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p propIdArraySizeBytes or \p + * propIdArray are NULL. + */ +public static native @Cast("CUptiResult") int cuptiMetricEnumProperties(@Cast("CUpti_MetricID") int metric, + @Cast("size_t*") SizeTPointer propIdArraySizeBytes, + @Cast("CUpti_MetricPropertyID*") IntPointer propIdArray); +public static native @Cast("CUptiResult") int cuptiMetricEnumProperties(@Cast("CUpti_MetricID") int metric, + @Cast("size_t*") SizeTPointer propIdArraySizeBytes, + @Cast("CUpti_MetricPropertyID*") IntBuffer propIdArray); +public static native @Cast("CUptiResult") int cuptiMetricEnumProperties(@Cast("CUpti_MetricID") int metric, + @Cast("size_t*") SizeTPointer propIdArraySizeBytes, + @Cast("CUpti_MetricPropertyID*") int[] propIdArray); + + +/** + * \brief For a metric get the groups of events that must be collected + * in the same pass. + * + * For a metric get the groups of events that must be collected in the + * same pass to ensure that the metric is calculated correctly. If the + * events are not collected as specified then the metric value may be + * inaccurate. + * + * The function returns NULL if a metric does not have any required + * event group. In this case the events needed for the metric can be + * grouped in any manner for collection. + * + * @param context The context for event collection + * @param metric The metric ID + * @param eventGroupSets Returns a CUpti_EventGroupSets object that + * indicates the events that must be collected in the same pass to + * ensure the metric is calculated correctly. Returns NULL if no + * grouping is required for metric + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_METRIC_ID + */ +public static native @Cast("CUptiResult") int cuptiMetricGetRequiredEventGroupSets(CUctx_st context, + @Cast("CUpti_MetricID") int metric, + @Cast("CUpti_EventGroupSets**") PointerPointer eventGroupSets); +public static native @Cast("CUptiResult") int cuptiMetricGetRequiredEventGroupSets(CUctx_st context, + @Cast("CUpti_MetricID") int metric, + @ByPtrPtr CUpti_EventGroupSets eventGroupSets); + +/** + * \brief For a set of metrics, get the grouping that indicates the + * number of passes and the event groups necessary to collect the + * events required for those metrics. + * + * For a set of metrics, get the grouping that indicates the number of + * passes and the event groups necessary to collect the events + * required for those metrics. + * + * @see cuptiEventGroupSetsCreate for details on event group set + * creation. + * + * @param context The context for event collection + * @param metricIdArraySizeBytes Size of the metricIdArray in bytes + * @param metricIdArray Array of metric IDs + * @param eventGroupPasses Returns a CUpti_EventGroupSets object that + * indicates the number of passes required to collect the events and + * the events to collect on each pass + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_CONTEXT + * \retval CUPTI_ERROR_INVALID_METRIC_ID + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p metricIdArray or + * \p eventGroupPasses is NULL + */ +public static native @Cast("CUptiResult") int cuptiMetricCreateEventGroupSets(CUctx_st context, + @Cast("size_t") long metricIdArraySizeBytes, + @Cast("CUpti_MetricID*") IntPointer metricIdArray, + @Cast("CUpti_EventGroupSets**") PointerPointer eventGroupPasses); +public static native @Cast("CUptiResult") int cuptiMetricCreateEventGroupSets(CUctx_st context, + @Cast("size_t") long metricIdArraySizeBytes, + @Cast("CUpti_MetricID*") IntPointer metricIdArray, + @ByPtrPtr CUpti_EventGroupSets eventGroupPasses); +public static native @Cast("CUptiResult") int cuptiMetricCreateEventGroupSets(CUctx_st context, + @Cast("size_t") long metricIdArraySizeBytes, + @Cast("CUpti_MetricID*") int[] metricIdArray, + @ByPtrPtr CUpti_EventGroupSets eventGroupPasses); + +/** + * \brief Calculate the value for a metric. + * + * Use the events collected for a metric to calculate the metric + * value. Metric value evaluation depends on the evaluation mode + * \ref CUpti_MetricEvaluationMode that the metric supports. + * If a metric has evaluation mode as CUPTI_METRIC_EVALUATION_MODE_PER_INSTANCE, + * then it assumes that the input event value is for one domain instance. + * If a metric has evaluation mode as CUPTI_METRIC_EVALUATION_MODE_AGGREGATE, + * it assumes that input event values are + * normalized to represent all domain instances on a device. For the + * most accurate metric collection, the events required for the metric + * should be collected for all profiled domain instances. For example, + * to collect all instances of an event, set the + * CUPTI_EVENT_GROUP_ATTR_PROFILE_ALL_DOMAIN_INSTANCES attribute on + * the group containing the event to 1. The normalized value for the + * event is then: (\p sum_event_values * \p totalInstanceCount) / \p + * instanceCount, where \p sum_event_values is the summation of the + * event values across all profiled domain instances, \p + * totalInstanceCount is obtained from querying + * CUPTI_EVENT_DOMAIN_ATTR_TOTAL_INSTANCE_COUNT and \p instanceCount + * is obtained from querying CUPTI_EVENT_GROUP_ATTR_INSTANCE_COUNT (or + * CUPTI_EVENT_DOMAIN_ATTR_INSTANCE_COUNT). + * + * @param device The CUDA device that the metric is being calculated for + * @param metric The metric ID + * @param eventIdArraySizeBytes The size of \p eventIdArray in bytes + * @param eventIdArray The event IDs required to calculate \p metric + * @param eventValueArraySizeBytes The size of \p eventValueArray in bytes + * @param eventValueArray The normalized event values required to + * calculate \p metric. The values must be order to match the order of + * events in \p eventIdArray + * @param timeDuration The duration over which the events were + * collected, in ns + * @param metricValue Returns the value for the metric + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_METRIC_ID + * \retval CUPTI_ERROR_INVALID_OPERATION + * \retval CUPTI_ERROR_PARAMETER_SIZE_NOT_SUFFICIENT if the + * eventIdArray does not contain all the events needed for metric + * \retval CUPTI_ERROR_INVALID_EVENT_VALUE if any of the + * event values required for the metric is CUPTI_EVENT_OVERFLOW + * \retval CUPTI_ERROR_INVALID_METRIC_VALUE if the computed metric value + * cannot be represented in the metric's value type. For example, + * if the metric value type is unsigned and the computed metric value is negative + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p metricValue, + * \p eventIdArray or \p eventValueArray is NULL + */ +public static native @Cast("CUptiResult") int cuptiMetricGetValue(@Cast("CUdevice") int device, + @Cast("CUpti_MetricID") int metric, + @Cast("size_t") long eventIdArraySizeBytes, + @Cast("CUpti_EventID*") IntPointer eventIdArray, + @Cast("size_t") long eventValueArraySizeBytes, + @Cast("uint64_t*") LongPointer eventValueArray, + @Cast("uint64_t") long timeDuration, + CUpti_MetricValue metricValue); +public static native @Cast("CUptiResult") int cuptiMetricGetValue(@Cast("CUdevice") int device, + @Cast("CUpti_MetricID") int metric, + @Cast("size_t") long eventIdArraySizeBytes, + @Cast("CUpti_EventID*") int[] eventIdArray, + @Cast("size_t") long eventValueArraySizeBytes, + @Cast("uint64_t*") LongBuffer eventValueArray, + @Cast("uint64_t") long timeDuration, + CUpti_MetricValue metricValue); +public static native @Cast("CUptiResult") int cuptiMetricGetValue(@Cast("CUdevice") int device, + @Cast("CUpti_MetricID") int metric, + @Cast("size_t") long eventIdArraySizeBytes, + @Cast("CUpti_EventID*") IntPointer eventIdArray, + @Cast("size_t") long eventValueArraySizeBytes, + @Cast("uint64_t*") long[] eventValueArray, + @Cast("uint64_t") long timeDuration, + CUpti_MetricValue metricValue); +public static native @Cast("CUptiResult") int cuptiMetricGetValue(@Cast("CUdevice") int device, + @Cast("CUpti_MetricID") int metric, + @Cast("size_t") long eventIdArraySizeBytes, + @Cast("CUpti_EventID*") int[] eventIdArray, + @Cast("size_t") long eventValueArraySizeBytes, + @Cast("uint64_t*") LongPointer eventValueArray, + @Cast("uint64_t") long timeDuration, + CUpti_MetricValue metricValue); +public static native @Cast("CUptiResult") int cuptiMetricGetValue(@Cast("CUdevice") int device, + @Cast("CUpti_MetricID") int metric, + @Cast("size_t") long eventIdArraySizeBytes, + @Cast("CUpti_EventID*") IntPointer eventIdArray, + @Cast("size_t") long eventValueArraySizeBytes, + @Cast("uint64_t*") LongBuffer eventValueArray, + @Cast("uint64_t") long timeDuration, + CUpti_MetricValue metricValue); +public static native @Cast("CUptiResult") int cuptiMetricGetValue(@Cast("CUdevice") int device, + @Cast("CUpti_MetricID") int metric, + @Cast("size_t") long eventIdArraySizeBytes, + @Cast("CUpti_EventID*") int[] eventIdArray, + @Cast("size_t") long eventValueArraySizeBytes, + @Cast("uint64_t*") long[] eventValueArray, + @Cast("uint64_t") long timeDuration, + CUpti_MetricValue metricValue); + +/** + * \brief Calculate the value for a metric. + * + * Use the events and properties collected for a metric to calculate + * the metric value. Metric value evaluation depends on the evaluation + * mode \ref CUpti_MetricEvaluationMode that the metric supports. If + * a metric has evaluation mode as + * CUPTI_METRIC_EVALUATION_MODE_PER_INSTANCE, then it assumes that the + * input event value is for one domain instance. If a metric has + * evaluation mode as CUPTI_METRIC_EVALUATION_MODE_AGGREGATE, it + * assumes that input event values are normalized to represent all + * domain instances on a device. For the most accurate metric + * collection, the events required for the metric should be collected + * for all profiled domain instances. For example, to collect all + * instances of an event, set the + * CUPTI_EVENT_GROUP_ATTR_PROFILE_ALL_DOMAIN_INSTANCES attribute on + * the group containing the event to 1. The normalized value for the + * event is then: (\p sum_event_values * \p totalInstanceCount) / \p + * instanceCount, where \p sum_event_values is the summation of the + * event values across all profiled domain instances, \p + * totalInstanceCount is obtained from querying + * CUPTI_EVENT_DOMAIN_ATTR_TOTAL_INSTANCE_COUNT and \p instanceCount + * is obtained from querying CUPTI_EVENT_GROUP_ATTR_INSTANCE_COUNT (or + * CUPTI_EVENT_DOMAIN_ATTR_INSTANCE_COUNT). + * + * @param metric The metric ID + * @param eventIdArraySizeBytes The size of \p eventIdArray in bytes + * @param eventIdArray The event IDs required to calculate \p metric + * @param eventValueArraySizeBytes The size of \p eventValueArray in bytes + * @param eventValueArray The normalized event values required to + * calculate \p metric. The values must be order to match the order of + * events in \p eventIdArray + * @param propIdArraySizeBytes The size of \p propIdArray in bytes + * @param propIdArray The metric property IDs required to calculate \p metric + * @param propValueArraySizeBytes The size of \p propValueArray in bytes + * @param propValueArray The metric property values required to + * calculate \p metric. The values must be order to match the order of + * metric properties in \p propIdArray + * @param metricValue Returns the value for the metric + * + * \retval CUPTI_SUCCESS + * \retval CUPTI_ERROR_NOT_INITIALIZED + * \retval CUPTI_ERROR_INVALID_METRIC_ID + * \retval CUPTI_ERROR_INVALID_OPERATION + * \retval CUPTI_ERROR_PARAMETER_SIZE_NOT_SUFFICIENT if the + * eventIdArray does not contain all the events needed for metric + * \retval CUPTI_ERROR_INVALID_EVENT_VALUE if any of the + * event values required for the metric is CUPTI_EVENT_OVERFLOW + * \retval CUPTI_ERROR_NOT_COMPATIBLE if the computed metric value + * cannot be represented in the metric's value type. For example, + * if the metric value type is unsigned and the computed metric value is negative + * \retval CUPTI_ERROR_INVALID_PARAMETER if \p metricValue, + * \p eventIdArray or \p eventValueArray is NULL + */ +public static native @Cast("CUptiResult") int cuptiMetricGetValue2(@Cast("CUpti_MetricID") int metric, + @Cast("size_t") long eventIdArraySizeBytes, + @Cast("CUpti_EventID*") IntPointer eventIdArray, + @Cast("size_t") long eventValueArraySizeBytes, + @Cast("uint64_t*") LongPointer eventValueArray, + @Cast("size_t") long propIdArraySizeBytes, + @Cast("CUpti_MetricPropertyID*") IntPointer propIdArray, + @Cast("size_t") long propValueArraySizeBytes, + @Cast("uint64_t*") LongPointer propValueArray, + CUpti_MetricValue metricValue); +public static native @Cast("CUptiResult") int cuptiMetricGetValue2(@Cast("CUpti_MetricID") int metric, + @Cast("size_t") long eventIdArraySizeBytes, + @Cast("CUpti_EventID*") int[] eventIdArray, + @Cast("size_t") long eventValueArraySizeBytes, + @Cast("uint64_t*") LongBuffer eventValueArray, + @Cast("size_t") long propIdArraySizeBytes, + @Cast("CUpti_MetricPropertyID*") IntBuffer propIdArray, + @Cast("size_t") long propValueArraySizeBytes, + @Cast("uint64_t*") LongBuffer propValueArray, + CUpti_MetricValue metricValue); +public static native @Cast("CUptiResult") int cuptiMetricGetValue2(@Cast("CUpti_MetricID") int metric, + @Cast("size_t") long eventIdArraySizeBytes, + @Cast("CUpti_EventID*") IntPointer eventIdArray, + @Cast("size_t") long eventValueArraySizeBytes, + @Cast("uint64_t*") long[] eventValueArray, + @Cast("size_t") long propIdArraySizeBytes, + @Cast("CUpti_MetricPropertyID*") int[] propIdArray, + @Cast("size_t") long propValueArraySizeBytes, + @Cast("uint64_t*") long[] propValueArray, + CUpti_MetricValue metricValue); +public static native @Cast("CUptiResult") int cuptiMetricGetValue2(@Cast("CUpti_MetricID") int metric, + @Cast("size_t") long eventIdArraySizeBytes, + @Cast("CUpti_EventID*") int[] eventIdArray, + @Cast("size_t") long eventValueArraySizeBytes, + @Cast("uint64_t*") LongPointer eventValueArray, + @Cast("size_t") long propIdArraySizeBytes, + @Cast("CUpti_MetricPropertyID*") IntPointer propIdArray, + @Cast("size_t") long propValueArraySizeBytes, + @Cast("uint64_t*") LongPointer propValueArray, + CUpti_MetricValue metricValue); +public static native @Cast("CUptiResult") int cuptiMetricGetValue2(@Cast("CUpti_MetricID") int metric, + @Cast("size_t") long eventIdArraySizeBytes, + @Cast("CUpti_EventID*") IntPointer eventIdArray, + @Cast("size_t") long eventValueArraySizeBytes, + @Cast("uint64_t*") LongBuffer eventValueArray, + @Cast("size_t") long propIdArraySizeBytes, + @Cast("CUpti_MetricPropertyID*") IntBuffer propIdArray, + @Cast("size_t") long propValueArraySizeBytes, + @Cast("uint64_t*") LongBuffer propValueArray, + CUpti_MetricValue metricValue); +public static native @Cast("CUptiResult") int cuptiMetricGetValue2(@Cast("CUpti_MetricID") int metric, + @Cast("size_t") long eventIdArraySizeBytes, + @Cast("CUpti_EventID*") int[] eventIdArray, + @Cast("size_t") long eventValueArraySizeBytes, + @Cast("uint64_t*") long[] eventValueArray, + @Cast("size_t") long propIdArraySizeBytes, + @Cast("CUpti_MetricPropertyID*") int[] propIdArray, + @Cast("size_t") long propValueArraySizeBytes, + @Cast("uint64_t*") long[] propValueArray, + CUpti_MetricValue metricValue); + +/** \} */ /* END CUPTI_METRIC_API */ + +// #if defined(__GNUC__) && defined(CUPTI_LIB) +// #pragma GCC visibility pop +// #endif + +// #if defined(__cplusplus) +// #endif + +// #endif /*_CUPTI_METRIC_H_*/ + + + + +// Parsed from cupti_driver_cbid.h + + +// ************************************************************************* +// Definitions of indices for API functions, unique across entire API +// ************************************************************************* + +// This file is generated. Any changes you make will be lost during the next clean build. +// CUDA public interface, for type definitions and cu* function prototypes + +// #if !defined(_CUPTI_DRIVER_CBID_H_) +// #define _CUPTI_DRIVER_CBID_H_ + +/** enum CUpti_driver_api_trace_cbid */ +public static final int + CUPTI_DRIVER_TRACE_CBID_INVALID = 0, + CUPTI_DRIVER_TRACE_CBID_cuInit = 1, + CUPTI_DRIVER_TRACE_CBID_cuDriverGetVersion = 2, + CUPTI_DRIVER_TRACE_CBID_cuDeviceGet = 3, + CUPTI_DRIVER_TRACE_CBID_cuDeviceGetCount = 4, + CUPTI_DRIVER_TRACE_CBID_cuDeviceGetName = 5, + CUPTI_DRIVER_TRACE_CBID_cuDeviceComputeCapability = 6, + CUPTI_DRIVER_TRACE_CBID_cuDeviceTotalMem = 7, + CUPTI_DRIVER_TRACE_CBID_cuDeviceGetProperties = 8, + CUPTI_DRIVER_TRACE_CBID_cuDeviceGetAttribute = 9, + CUPTI_DRIVER_TRACE_CBID_cuCtxCreate = 10, + CUPTI_DRIVER_TRACE_CBID_cuCtxDestroy = 11, + CUPTI_DRIVER_TRACE_CBID_cuCtxAttach = 12, + CUPTI_DRIVER_TRACE_CBID_cuCtxDetach = 13, + CUPTI_DRIVER_TRACE_CBID_cuCtxPushCurrent = 14, + CUPTI_DRIVER_TRACE_CBID_cuCtxPopCurrent = 15, + CUPTI_DRIVER_TRACE_CBID_cuCtxGetDevice = 16, + CUPTI_DRIVER_TRACE_CBID_cuCtxSynchronize = 17, + CUPTI_DRIVER_TRACE_CBID_cuModuleLoad = 18, + CUPTI_DRIVER_TRACE_CBID_cuModuleLoadData = 19, + CUPTI_DRIVER_TRACE_CBID_cuModuleLoadDataEx = 20, + CUPTI_DRIVER_TRACE_CBID_cuModuleLoadFatBinary = 21, + CUPTI_DRIVER_TRACE_CBID_cuModuleUnload = 22, + CUPTI_DRIVER_TRACE_CBID_cuModuleGetFunction = 23, + CUPTI_DRIVER_TRACE_CBID_cuModuleGetGlobal = 24, + CUPTI_DRIVER_TRACE_CBID_cu64ModuleGetGlobal = 25, + CUPTI_DRIVER_TRACE_CBID_cuModuleGetTexRef = 26, + CUPTI_DRIVER_TRACE_CBID_cuMemGetInfo = 27, + CUPTI_DRIVER_TRACE_CBID_cu64MemGetInfo = 28, + CUPTI_DRIVER_TRACE_CBID_cuMemAlloc = 29, + CUPTI_DRIVER_TRACE_CBID_cu64MemAlloc = 30, + CUPTI_DRIVER_TRACE_CBID_cuMemAllocPitch = 31, + CUPTI_DRIVER_TRACE_CBID_cu64MemAllocPitch = 32, + CUPTI_DRIVER_TRACE_CBID_cuMemFree = 33, + CUPTI_DRIVER_TRACE_CBID_cu64MemFree = 34, + CUPTI_DRIVER_TRACE_CBID_cuMemGetAddressRange = 35, + CUPTI_DRIVER_TRACE_CBID_cu64MemGetAddressRange = 36, + CUPTI_DRIVER_TRACE_CBID_cuMemAllocHost = 37, + CUPTI_DRIVER_TRACE_CBID_cuMemFreeHost = 38, + CUPTI_DRIVER_TRACE_CBID_cuMemHostAlloc = 39, + CUPTI_DRIVER_TRACE_CBID_cuMemHostGetDevicePointer = 40, + CUPTI_DRIVER_TRACE_CBID_cu64MemHostGetDevicePointer = 41, + CUPTI_DRIVER_TRACE_CBID_cuMemHostGetFlags = 42, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyHtoD = 43, + CUPTI_DRIVER_TRACE_CBID_cu64MemcpyHtoD = 44, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyDtoH = 45, + CUPTI_DRIVER_TRACE_CBID_cu64MemcpyDtoH = 46, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyDtoD = 47, + CUPTI_DRIVER_TRACE_CBID_cu64MemcpyDtoD = 48, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyDtoA = 49, + CUPTI_DRIVER_TRACE_CBID_cu64MemcpyDtoA = 50, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyAtoD = 51, + CUPTI_DRIVER_TRACE_CBID_cu64MemcpyAtoD = 52, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyHtoA = 53, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyAtoH = 54, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyAtoA = 55, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy2D = 56, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy2DUnaligned = 57, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy3D = 58, + CUPTI_DRIVER_TRACE_CBID_cu64Memcpy3D = 59, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyHtoDAsync = 60, + CUPTI_DRIVER_TRACE_CBID_cu64MemcpyHtoDAsync = 61, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyDtoHAsync = 62, + CUPTI_DRIVER_TRACE_CBID_cu64MemcpyDtoHAsync = 63, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyDtoDAsync = 64, + CUPTI_DRIVER_TRACE_CBID_cu64MemcpyDtoDAsync = 65, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyHtoAAsync = 66, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyAtoHAsync = 67, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy2DAsync = 68, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy3DAsync = 69, + CUPTI_DRIVER_TRACE_CBID_cu64Memcpy3DAsync = 70, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD8 = 71, + CUPTI_DRIVER_TRACE_CBID_cu64MemsetD8 = 72, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD16 = 73, + CUPTI_DRIVER_TRACE_CBID_cu64MemsetD16 = 74, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD32 = 75, + CUPTI_DRIVER_TRACE_CBID_cu64MemsetD32 = 76, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD2D8 = 77, + CUPTI_DRIVER_TRACE_CBID_cu64MemsetD2D8 = 78, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD2D16 = 79, + CUPTI_DRIVER_TRACE_CBID_cu64MemsetD2D16 = 80, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD2D32 = 81, + CUPTI_DRIVER_TRACE_CBID_cu64MemsetD2D32 = 82, + CUPTI_DRIVER_TRACE_CBID_cuFuncSetBlockShape = 83, + CUPTI_DRIVER_TRACE_CBID_cuFuncSetSharedSize = 84, + CUPTI_DRIVER_TRACE_CBID_cuFuncGetAttribute = 85, + CUPTI_DRIVER_TRACE_CBID_cuFuncSetCacheConfig = 86, + CUPTI_DRIVER_TRACE_CBID_cuArrayCreate = 87, + CUPTI_DRIVER_TRACE_CBID_cuArrayGetDescriptor = 88, + CUPTI_DRIVER_TRACE_CBID_cuArrayDestroy = 89, + CUPTI_DRIVER_TRACE_CBID_cuArray3DCreate = 90, + CUPTI_DRIVER_TRACE_CBID_cuArray3DGetDescriptor = 91, + CUPTI_DRIVER_TRACE_CBID_cuTexRefCreate = 92, + CUPTI_DRIVER_TRACE_CBID_cuTexRefDestroy = 93, + CUPTI_DRIVER_TRACE_CBID_cuTexRefSetArray = 94, + CUPTI_DRIVER_TRACE_CBID_cuTexRefSetAddress = 95, + CUPTI_DRIVER_TRACE_CBID_cu64TexRefSetAddress = 96, + CUPTI_DRIVER_TRACE_CBID_cuTexRefSetAddress2D = 97, + CUPTI_DRIVER_TRACE_CBID_cu64TexRefSetAddress2D = 98, + CUPTI_DRIVER_TRACE_CBID_cuTexRefSetFormat = 99, + CUPTI_DRIVER_TRACE_CBID_cuTexRefSetAddressMode = 100, + CUPTI_DRIVER_TRACE_CBID_cuTexRefSetFilterMode = 101, + CUPTI_DRIVER_TRACE_CBID_cuTexRefSetFlags = 102, + CUPTI_DRIVER_TRACE_CBID_cuTexRefGetAddress = 103, + CUPTI_DRIVER_TRACE_CBID_cu64TexRefGetAddress = 104, + CUPTI_DRIVER_TRACE_CBID_cuTexRefGetArray = 105, + CUPTI_DRIVER_TRACE_CBID_cuTexRefGetAddressMode = 106, + CUPTI_DRIVER_TRACE_CBID_cuTexRefGetFilterMode = 107, + CUPTI_DRIVER_TRACE_CBID_cuTexRefGetFormat = 108, + CUPTI_DRIVER_TRACE_CBID_cuTexRefGetFlags = 109, + CUPTI_DRIVER_TRACE_CBID_cuParamSetSize = 110, + CUPTI_DRIVER_TRACE_CBID_cuParamSeti = 111, + CUPTI_DRIVER_TRACE_CBID_cuParamSetf = 112, + CUPTI_DRIVER_TRACE_CBID_cuParamSetv = 113, + CUPTI_DRIVER_TRACE_CBID_cuParamSetTexRef = 114, + CUPTI_DRIVER_TRACE_CBID_cuLaunch = 115, + CUPTI_DRIVER_TRACE_CBID_cuLaunchGrid = 116, + CUPTI_DRIVER_TRACE_CBID_cuLaunchGridAsync = 117, + CUPTI_DRIVER_TRACE_CBID_cuEventCreate = 118, + CUPTI_DRIVER_TRACE_CBID_cuEventRecord = 119, + CUPTI_DRIVER_TRACE_CBID_cuEventQuery = 120, + CUPTI_DRIVER_TRACE_CBID_cuEventSynchronize = 121, + CUPTI_DRIVER_TRACE_CBID_cuEventDestroy = 122, + CUPTI_DRIVER_TRACE_CBID_cuEventElapsedTime = 123, + CUPTI_DRIVER_TRACE_CBID_cuStreamCreate = 124, + CUPTI_DRIVER_TRACE_CBID_cuStreamQuery = 125, + CUPTI_DRIVER_TRACE_CBID_cuStreamSynchronize = 126, + CUPTI_DRIVER_TRACE_CBID_cuStreamDestroy = 127, + CUPTI_DRIVER_TRACE_CBID_cuGraphicsUnregisterResource = 128, + CUPTI_DRIVER_TRACE_CBID_cuGraphicsSubResourceGetMappedArray = 129, + CUPTI_DRIVER_TRACE_CBID_cuGraphicsResourceGetMappedPointer = 130, + CUPTI_DRIVER_TRACE_CBID_cu64GraphicsResourceGetMappedPointer = 131, + CUPTI_DRIVER_TRACE_CBID_cuGraphicsResourceSetMapFlags = 132, + CUPTI_DRIVER_TRACE_CBID_cuGraphicsMapResources = 133, + CUPTI_DRIVER_TRACE_CBID_cuGraphicsUnmapResources = 134, + CUPTI_DRIVER_TRACE_CBID_cuGetExportTable = 135, + CUPTI_DRIVER_TRACE_CBID_cuCtxSetLimit = 136, + CUPTI_DRIVER_TRACE_CBID_cuCtxGetLimit = 137, + CUPTI_DRIVER_TRACE_CBID_cuD3D10GetDevice = 138, + CUPTI_DRIVER_TRACE_CBID_cuD3D10CtxCreate = 139, + CUPTI_DRIVER_TRACE_CBID_cuGraphicsD3D10RegisterResource = 140, + CUPTI_DRIVER_TRACE_CBID_cuD3D10RegisterResource = 141, + CUPTI_DRIVER_TRACE_CBID_cuD3D10UnregisterResource = 142, + CUPTI_DRIVER_TRACE_CBID_cuD3D10MapResources = 143, + CUPTI_DRIVER_TRACE_CBID_cuD3D10UnmapResources = 144, + CUPTI_DRIVER_TRACE_CBID_cuD3D10ResourceSetMapFlags = 145, + CUPTI_DRIVER_TRACE_CBID_cuD3D10ResourceGetMappedArray = 146, + CUPTI_DRIVER_TRACE_CBID_cuD3D10ResourceGetMappedPointer = 147, + CUPTI_DRIVER_TRACE_CBID_cuD3D10ResourceGetMappedSize = 148, + CUPTI_DRIVER_TRACE_CBID_cuD3D10ResourceGetMappedPitch = 149, + CUPTI_DRIVER_TRACE_CBID_cuD3D10ResourceGetSurfaceDimensions = 150, + CUPTI_DRIVER_TRACE_CBID_cuD3D11GetDevice = 151, + CUPTI_DRIVER_TRACE_CBID_cuD3D11CtxCreate = 152, + CUPTI_DRIVER_TRACE_CBID_cuGraphicsD3D11RegisterResource = 153, + CUPTI_DRIVER_TRACE_CBID_cuD3D9GetDevice = 154, + CUPTI_DRIVER_TRACE_CBID_cuD3D9CtxCreate = 155, + CUPTI_DRIVER_TRACE_CBID_cuGraphicsD3D9RegisterResource = 156, + CUPTI_DRIVER_TRACE_CBID_cuD3D9GetDirect3DDevice = 157, + CUPTI_DRIVER_TRACE_CBID_cuD3D9RegisterResource = 158, + CUPTI_DRIVER_TRACE_CBID_cuD3D9UnregisterResource = 159, + CUPTI_DRIVER_TRACE_CBID_cuD3D9MapResources = 160, + CUPTI_DRIVER_TRACE_CBID_cuD3D9UnmapResources = 161, + CUPTI_DRIVER_TRACE_CBID_cuD3D9ResourceSetMapFlags = 162, + CUPTI_DRIVER_TRACE_CBID_cuD3D9ResourceGetSurfaceDimensions = 163, + CUPTI_DRIVER_TRACE_CBID_cuD3D9ResourceGetMappedArray = 164, + CUPTI_DRIVER_TRACE_CBID_cuD3D9ResourceGetMappedPointer = 165, + CUPTI_DRIVER_TRACE_CBID_cuD3D9ResourceGetMappedSize = 166, + CUPTI_DRIVER_TRACE_CBID_cuD3D9ResourceGetMappedPitch = 167, + CUPTI_DRIVER_TRACE_CBID_cuD3D9Begin = 168, + CUPTI_DRIVER_TRACE_CBID_cuD3D9End = 169, + CUPTI_DRIVER_TRACE_CBID_cuD3D9RegisterVertexBuffer = 170, + CUPTI_DRIVER_TRACE_CBID_cuD3D9MapVertexBuffer = 171, + CUPTI_DRIVER_TRACE_CBID_cuD3D9UnmapVertexBuffer = 172, + CUPTI_DRIVER_TRACE_CBID_cuD3D9UnregisterVertexBuffer = 173, + CUPTI_DRIVER_TRACE_CBID_cuGLCtxCreate = 174, + CUPTI_DRIVER_TRACE_CBID_cuGraphicsGLRegisterBuffer = 175, + CUPTI_DRIVER_TRACE_CBID_cuGraphicsGLRegisterImage = 176, + CUPTI_DRIVER_TRACE_CBID_cuWGLGetDevice = 177, + CUPTI_DRIVER_TRACE_CBID_cuGLInit = 178, + CUPTI_DRIVER_TRACE_CBID_cuGLRegisterBufferObject = 179, + CUPTI_DRIVER_TRACE_CBID_cuGLMapBufferObject = 180, + CUPTI_DRIVER_TRACE_CBID_cuGLUnmapBufferObject = 181, + CUPTI_DRIVER_TRACE_CBID_cuGLUnregisterBufferObject = 182, + CUPTI_DRIVER_TRACE_CBID_cuGLSetBufferObjectMapFlags = 183, + CUPTI_DRIVER_TRACE_CBID_cuGLMapBufferObjectAsync = 184, + CUPTI_DRIVER_TRACE_CBID_cuGLUnmapBufferObjectAsync = 185, + CUPTI_DRIVER_TRACE_CBID_cuVDPAUGetDevice = 186, + CUPTI_DRIVER_TRACE_CBID_cuVDPAUCtxCreate = 187, + CUPTI_DRIVER_TRACE_CBID_cuGraphicsVDPAURegisterVideoSurface = 188, + CUPTI_DRIVER_TRACE_CBID_cuGraphicsVDPAURegisterOutputSurface = 189, + CUPTI_DRIVER_TRACE_CBID_cuModuleGetSurfRef = 190, + CUPTI_DRIVER_TRACE_CBID_cuSurfRefCreate = 191, + CUPTI_DRIVER_TRACE_CBID_cuSurfRefDestroy = 192, + CUPTI_DRIVER_TRACE_CBID_cuSurfRefSetFormat = 193, + CUPTI_DRIVER_TRACE_CBID_cuSurfRefSetArray = 194, + CUPTI_DRIVER_TRACE_CBID_cuSurfRefGetFormat = 195, + CUPTI_DRIVER_TRACE_CBID_cuSurfRefGetArray = 196, + CUPTI_DRIVER_TRACE_CBID_cu64DeviceTotalMem = 197, + CUPTI_DRIVER_TRACE_CBID_cu64D3D10ResourceGetMappedPointer = 198, + CUPTI_DRIVER_TRACE_CBID_cu64D3D10ResourceGetMappedSize = 199, + CUPTI_DRIVER_TRACE_CBID_cu64D3D10ResourceGetMappedPitch = 200, + CUPTI_DRIVER_TRACE_CBID_cu64D3D10ResourceGetSurfaceDimensions = 201, + CUPTI_DRIVER_TRACE_CBID_cu64D3D9ResourceGetSurfaceDimensions = 202, + CUPTI_DRIVER_TRACE_CBID_cu64D3D9ResourceGetMappedPointer = 203, + CUPTI_DRIVER_TRACE_CBID_cu64D3D9ResourceGetMappedSize = 204, + CUPTI_DRIVER_TRACE_CBID_cu64D3D9ResourceGetMappedPitch = 205, + CUPTI_DRIVER_TRACE_CBID_cu64D3D9MapVertexBuffer = 206, + CUPTI_DRIVER_TRACE_CBID_cu64GLMapBufferObject = 207, + CUPTI_DRIVER_TRACE_CBID_cu64GLMapBufferObjectAsync = 208, + CUPTI_DRIVER_TRACE_CBID_cuD3D11GetDevices = 209, + CUPTI_DRIVER_TRACE_CBID_cuD3D11CtxCreateOnDevice = 210, + CUPTI_DRIVER_TRACE_CBID_cuD3D10GetDevices = 211, + CUPTI_DRIVER_TRACE_CBID_cuD3D10CtxCreateOnDevice = 212, + CUPTI_DRIVER_TRACE_CBID_cuD3D9GetDevices = 213, + CUPTI_DRIVER_TRACE_CBID_cuD3D9CtxCreateOnDevice = 214, + CUPTI_DRIVER_TRACE_CBID_cu64MemHostAlloc = 215, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD8Async = 216, + CUPTI_DRIVER_TRACE_CBID_cu64MemsetD8Async = 217, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD16Async = 218, + CUPTI_DRIVER_TRACE_CBID_cu64MemsetD16Async = 219, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD32Async = 220, + CUPTI_DRIVER_TRACE_CBID_cu64MemsetD32Async = 221, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD2D8Async = 222, + CUPTI_DRIVER_TRACE_CBID_cu64MemsetD2D8Async = 223, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD2D16Async = 224, + CUPTI_DRIVER_TRACE_CBID_cu64MemsetD2D16Async = 225, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD2D32Async = 226, + CUPTI_DRIVER_TRACE_CBID_cu64MemsetD2D32Async = 227, + CUPTI_DRIVER_TRACE_CBID_cu64ArrayCreate = 228, + CUPTI_DRIVER_TRACE_CBID_cu64ArrayGetDescriptor = 229, + CUPTI_DRIVER_TRACE_CBID_cu64Array3DCreate = 230, + CUPTI_DRIVER_TRACE_CBID_cu64Array3DGetDescriptor = 231, + CUPTI_DRIVER_TRACE_CBID_cu64Memcpy2D = 232, + CUPTI_DRIVER_TRACE_CBID_cu64Memcpy2DUnaligned = 233, + CUPTI_DRIVER_TRACE_CBID_cu64Memcpy2DAsync = 234, + CUPTI_DRIVER_TRACE_CBID_cuCtxCreate_v2 = 235, + CUPTI_DRIVER_TRACE_CBID_cuD3D10CtxCreate_v2 = 236, + CUPTI_DRIVER_TRACE_CBID_cuD3D11CtxCreate_v2 = 237, + CUPTI_DRIVER_TRACE_CBID_cuD3D9CtxCreate_v2 = 238, + CUPTI_DRIVER_TRACE_CBID_cuGLCtxCreate_v2 = 239, + CUPTI_DRIVER_TRACE_CBID_cuVDPAUCtxCreate_v2 = 240, + CUPTI_DRIVER_TRACE_CBID_cuModuleGetGlobal_v2 = 241, + CUPTI_DRIVER_TRACE_CBID_cuMemGetInfo_v2 = 242, + CUPTI_DRIVER_TRACE_CBID_cuMemAlloc_v2 = 243, + CUPTI_DRIVER_TRACE_CBID_cuMemAllocPitch_v2 = 244, + CUPTI_DRIVER_TRACE_CBID_cuMemFree_v2 = 245, + CUPTI_DRIVER_TRACE_CBID_cuMemGetAddressRange_v2 = 246, + CUPTI_DRIVER_TRACE_CBID_cuMemHostGetDevicePointer_v2 = 247, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy_v2 = 248, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD8_v2 = 249, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD16_v2 = 250, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD32_v2 = 251, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD2D8_v2 = 252, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD2D16_v2 = 253, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD2D32_v2 = 254, + CUPTI_DRIVER_TRACE_CBID_cuTexRefSetAddress_v2 = 255, + CUPTI_DRIVER_TRACE_CBID_cuTexRefSetAddress2D_v2 = 256, + CUPTI_DRIVER_TRACE_CBID_cuTexRefGetAddress_v2 = 257, + CUPTI_DRIVER_TRACE_CBID_cuGraphicsResourceGetMappedPointer_v2 = 258, + CUPTI_DRIVER_TRACE_CBID_cuDeviceTotalMem_v2 = 259, + CUPTI_DRIVER_TRACE_CBID_cuD3D10ResourceGetMappedPointer_v2 = 260, + CUPTI_DRIVER_TRACE_CBID_cuD3D10ResourceGetMappedSize_v2 = 261, + CUPTI_DRIVER_TRACE_CBID_cuD3D10ResourceGetMappedPitch_v2 = 262, + CUPTI_DRIVER_TRACE_CBID_cuD3D10ResourceGetSurfaceDimensions_v2 = 263, + CUPTI_DRIVER_TRACE_CBID_cuD3D9ResourceGetSurfaceDimensions_v2 = 264, + CUPTI_DRIVER_TRACE_CBID_cuD3D9ResourceGetMappedPointer_v2 = 265, + CUPTI_DRIVER_TRACE_CBID_cuD3D9ResourceGetMappedSize_v2 = 266, + CUPTI_DRIVER_TRACE_CBID_cuD3D9ResourceGetMappedPitch_v2 = 267, + CUPTI_DRIVER_TRACE_CBID_cuD3D9MapVertexBuffer_v2 = 268, + CUPTI_DRIVER_TRACE_CBID_cuGLMapBufferObject_v2 = 269, + CUPTI_DRIVER_TRACE_CBID_cuGLMapBufferObjectAsync_v2 = 270, + CUPTI_DRIVER_TRACE_CBID_cuMemHostAlloc_v2 = 271, + CUPTI_DRIVER_TRACE_CBID_cuArrayCreate_v2 = 272, + CUPTI_DRIVER_TRACE_CBID_cuArrayGetDescriptor_v2 = 273, + CUPTI_DRIVER_TRACE_CBID_cuArray3DCreate_v2 = 274, + CUPTI_DRIVER_TRACE_CBID_cuArray3DGetDescriptor_v2 = 275, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyHtoD_v2 = 276, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyHtoDAsync_v2 = 277, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyDtoH_v2 = 278, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyDtoHAsync_v2 = 279, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyDtoD_v2 = 280, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyDtoDAsync_v2 = 281, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyAtoH_v2 = 282, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyAtoHAsync_v2 = 283, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyAtoD_v2 = 284, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyDtoA_v2 = 285, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyAtoA_v2 = 286, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy2D_v2 = 287, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy2DUnaligned_v2 = 288, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy2DAsync_v2 = 289, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy3D_v2 = 290, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy3DAsync_v2 = 291, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyHtoA_v2 = 292, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyHtoAAsync_v2 = 293, + CUPTI_DRIVER_TRACE_CBID_cuMemAllocHost_v2 = 294, + CUPTI_DRIVER_TRACE_CBID_cuStreamWaitEvent = 295, + CUPTI_DRIVER_TRACE_CBID_cuCtxGetApiVersion = 296, + CUPTI_DRIVER_TRACE_CBID_cuD3D10GetDirect3DDevice = 297, + CUPTI_DRIVER_TRACE_CBID_cuD3D11GetDirect3DDevice = 298, + CUPTI_DRIVER_TRACE_CBID_cuCtxGetCacheConfig = 299, + CUPTI_DRIVER_TRACE_CBID_cuCtxSetCacheConfig = 300, + CUPTI_DRIVER_TRACE_CBID_cuMemHostRegister = 301, + CUPTI_DRIVER_TRACE_CBID_cuMemHostUnregister = 302, + CUPTI_DRIVER_TRACE_CBID_cuCtxSetCurrent = 303, + CUPTI_DRIVER_TRACE_CBID_cuCtxGetCurrent = 304, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy = 305, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyAsync = 306, + CUPTI_DRIVER_TRACE_CBID_cuLaunchKernel = 307, + CUPTI_DRIVER_TRACE_CBID_cuProfilerStart = 308, + CUPTI_DRIVER_TRACE_CBID_cuProfilerStop = 309, + CUPTI_DRIVER_TRACE_CBID_cuPointerGetAttribute = 310, + CUPTI_DRIVER_TRACE_CBID_cuProfilerInitialize = 311, + CUPTI_DRIVER_TRACE_CBID_cuDeviceCanAccessPeer = 312, + CUPTI_DRIVER_TRACE_CBID_cuCtxEnablePeerAccess = 313, + CUPTI_DRIVER_TRACE_CBID_cuCtxDisablePeerAccess = 314, + CUPTI_DRIVER_TRACE_CBID_cuMemPeerRegister = 315, + CUPTI_DRIVER_TRACE_CBID_cuMemPeerUnregister = 316, + CUPTI_DRIVER_TRACE_CBID_cuMemPeerGetDevicePointer = 317, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyPeer = 318, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyPeerAsync = 319, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy3DPeer = 320, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy3DPeerAsync = 321, + CUPTI_DRIVER_TRACE_CBID_cuCtxDestroy_v2 = 322, + CUPTI_DRIVER_TRACE_CBID_cuCtxPushCurrent_v2 = 323, + CUPTI_DRIVER_TRACE_CBID_cuCtxPopCurrent_v2 = 324, + CUPTI_DRIVER_TRACE_CBID_cuEventDestroy_v2 = 325, + CUPTI_DRIVER_TRACE_CBID_cuStreamDestroy_v2 = 326, + CUPTI_DRIVER_TRACE_CBID_cuTexRefSetAddress2D_v3 = 327, + CUPTI_DRIVER_TRACE_CBID_cuIpcGetMemHandle = 328, + CUPTI_DRIVER_TRACE_CBID_cuIpcOpenMemHandle = 329, + CUPTI_DRIVER_TRACE_CBID_cuIpcCloseMemHandle = 330, + CUPTI_DRIVER_TRACE_CBID_cuDeviceGetByPCIBusId = 331, + CUPTI_DRIVER_TRACE_CBID_cuDeviceGetPCIBusId = 332, + CUPTI_DRIVER_TRACE_CBID_cuGLGetDevices = 333, + CUPTI_DRIVER_TRACE_CBID_cuIpcGetEventHandle = 334, + CUPTI_DRIVER_TRACE_CBID_cuIpcOpenEventHandle = 335, + CUPTI_DRIVER_TRACE_CBID_cuCtxSetSharedMemConfig = 336, + CUPTI_DRIVER_TRACE_CBID_cuCtxGetSharedMemConfig = 337, + CUPTI_DRIVER_TRACE_CBID_cuFuncSetSharedMemConfig = 338, + CUPTI_DRIVER_TRACE_CBID_cuTexObjectCreate = 339, + CUPTI_DRIVER_TRACE_CBID_cuTexObjectDestroy = 340, + CUPTI_DRIVER_TRACE_CBID_cuTexObjectGetResourceDesc = 341, + CUPTI_DRIVER_TRACE_CBID_cuTexObjectGetTextureDesc = 342, + CUPTI_DRIVER_TRACE_CBID_cuSurfObjectCreate = 343, + CUPTI_DRIVER_TRACE_CBID_cuSurfObjectDestroy = 344, + CUPTI_DRIVER_TRACE_CBID_cuSurfObjectGetResourceDesc = 345, + CUPTI_DRIVER_TRACE_CBID_cuStreamAddCallback = 346, + CUPTI_DRIVER_TRACE_CBID_cuMipmappedArrayCreate = 347, + CUPTI_DRIVER_TRACE_CBID_cuMipmappedArrayGetLevel = 348, + CUPTI_DRIVER_TRACE_CBID_cuMipmappedArrayDestroy = 349, + CUPTI_DRIVER_TRACE_CBID_cuTexRefSetMipmappedArray = 350, + CUPTI_DRIVER_TRACE_CBID_cuTexRefSetMipmapFilterMode = 351, + CUPTI_DRIVER_TRACE_CBID_cuTexRefSetMipmapLevelBias = 352, + CUPTI_DRIVER_TRACE_CBID_cuTexRefSetMipmapLevelClamp = 353, + CUPTI_DRIVER_TRACE_CBID_cuTexRefSetMaxAnisotropy = 354, + CUPTI_DRIVER_TRACE_CBID_cuTexRefGetMipmappedArray = 355, + CUPTI_DRIVER_TRACE_CBID_cuTexRefGetMipmapFilterMode = 356, + CUPTI_DRIVER_TRACE_CBID_cuTexRefGetMipmapLevelBias = 357, + CUPTI_DRIVER_TRACE_CBID_cuTexRefGetMipmapLevelClamp = 358, + CUPTI_DRIVER_TRACE_CBID_cuTexRefGetMaxAnisotropy = 359, + CUPTI_DRIVER_TRACE_CBID_cuGraphicsResourceGetMappedMipmappedArray = 360, + CUPTI_DRIVER_TRACE_CBID_cuTexObjectGetResourceViewDesc = 361, + CUPTI_DRIVER_TRACE_CBID_cuLinkCreate = 362, + CUPTI_DRIVER_TRACE_CBID_cuLinkAddData = 363, + CUPTI_DRIVER_TRACE_CBID_cuLinkAddFile = 364, + CUPTI_DRIVER_TRACE_CBID_cuLinkComplete = 365, + CUPTI_DRIVER_TRACE_CBID_cuLinkDestroy = 366, + CUPTI_DRIVER_TRACE_CBID_cuStreamCreateWithPriority = 367, + CUPTI_DRIVER_TRACE_CBID_cuStreamGetPriority = 368, + CUPTI_DRIVER_TRACE_CBID_cuStreamGetFlags = 369, + CUPTI_DRIVER_TRACE_CBID_cuCtxGetStreamPriorityRange = 370, + CUPTI_DRIVER_TRACE_CBID_cuMemAllocManaged = 371, + CUPTI_DRIVER_TRACE_CBID_cuGetErrorString = 372, + CUPTI_DRIVER_TRACE_CBID_cuGetErrorName = 373, + CUPTI_DRIVER_TRACE_CBID_cuOccupancyMaxActiveBlocksPerMultiprocessor = 374, + CUPTI_DRIVER_TRACE_CBID_cuCompilePtx = 375, + CUPTI_DRIVER_TRACE_CBID_cuBinaryFree = 376, + CUPTI_DRIVER_TRACE_CBID_cuStreamAttachMemAsync = 377, + CUPTI_DRIVER_TRACE_CBID_cuPointerSetAttribute = 378, + CUPTI_DRIVER_TRACE_CBID_cuMemHostRegister_v2 = 379, + CUPTI_DRIVER_TRACE_CBID_cuGraphicsResourceSetMapFlags_v2 = 380, + CUPTI_DRIVER_TRACE_CBID_cuLinkCreate_v2 = 381, + CUPTI_DRIVER_TRACE_CBID_cuLinkAddData_v2 = 382, + CUPTI_DRIVER_TRACE_CBID_cuLinkAddFile_v2 = 383, + CUPTI_DRIVER_TRACE_CBID_cuOccupancyMaxPotentialBlockSize = 384, + CUPTI_DRIVER_TRACE_CBID_cuGLGetDevices_v2 = 385, + CUPTI_DRIVER_TRACE_CBID_cuDevicePrimaryCtxRetain = 386, + CUPTI_DRIVER_TRACE_CBID_cuDevicePrimaryCtxRelease = 387, + CUPTI_DRIVER_TRACE_CBID_cuDevicePrimaryCtxSetFlags = 388, + CUPTI_DRIVER_TRACE_CBID_cuDevicePrimaryCtxReset = 389, + CUPTI_DRIVER_TRACE_CBID_cuGraphicsEGLRegisterImage = 390, + CUPTI_DRIVER_TRACE_CBID_cuCtxGetFlags = 391, + CUPTI_DRIVER_TRACE_CBID_cuDevicePrimaryCtxGetState = 392, + CUPTI_DRIVER_TRACE_CBID_cuEGLStreamConsumerConnect = 393, + CUPTI_DRIVER_TRACE_CBID_cuEGLStreamConsumerDisconnect = 394, + CUPTI_DRIVER_TRACE_CBID_cuEGLStreamConsumerAcquireFrame = 395, + CUPTI_DRIVER_TRACE_CBID_cuEGLStreamConsumerReleaseFrame = 396, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyHtoD_v2_ptds = 397, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyDtoH_v2_ptds = 398, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyDtoD_v2_ptds = 399, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyDtoA_v2_ptds = 400, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyAtoD_v2_ptds = 401, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyHtoA_v2_ptds = 402, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyAtoH_v2_ptds = 403, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyAtoA_v2_ptds = 404, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy2D_v2_ptds = 405, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy2DUnaligned_v2_ptds = 406, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy3D_v2_ptds = 407, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy_ptds = 408, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyPeer_ptds = 409, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy3DPeer_ptds = 410, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD8_v2_ptds = 411, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD16_v2_ptds = 412, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD32_v2_ptds = 413, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD2D8_v2_ptds = 414, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD2D16_v2_ptds = 415, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD2D32_v2_ptds = 416, + CUPTI_DRIVER_TRACE_CBID_cuGLMapBufferObject_v2_ptds = 417, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyAsync_ptsz = 418, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyHtoAAsync_v2_ptsz = 419, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyAtoHAsync_v2_ptsz = 420, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyHtoDAsync_v2_ptsz = 421, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyDtoHAsync_v2_ptsz = 422, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyDtoDAsync_v2_ptsz = 423, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy2DAsync_v2_ptsz = 424, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy3DAsync_v2_ptsz = 425, + CUPTI_DRIVER_TRACE_CBID_cuMemcpyPeerAsync_ptsz = 426, + CUPTI_DRIVER_TRACE_CBID_cuMemcpy3DPeerAsync_ptsz = 427, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD8Async_ptsz = 428, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD16Async_ptsz = 429, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD32Async_ptsz = 430, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD2D8Async_ptsz = 431, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD2D16Async_ptsz = 432, + CUPTI_DRIVER_TRACE_CBID_cuMemsetD2D32Async_ptsz = 433, + CUPTI_DRIVER_TRACE_CBID_cuStreamGetPriority_ptsz = 434, + CUPTI_DRIVER_TRACE_CBID_cuStreamGetFlags_ptsz = 435, + CUPTI_DRIVER_TRACE_CBID_cuStreamWaitEvent_ptsz = 436, + CUPTI_DRIVER_TRACE_CBID_cuStreamAddCallback_ptsz = 437, + CUPTI_DRIVER_TRACE_CBID_cuStreamAttachMemAsync_ptsz = 438, + CUPTI_DRIVER_TRACE_CBID_cuStreamQuery_ptsz = 439, + CUPTI_DRIVER_TRACE_CBID_cuStreamSynchronize_ptsz = 440, + CUPTI_DRIVER_TRACE_CBID_cuEventRecord_ptsz = 441, + CUPTI_DRIVER_TRACE_CBID_cuLaunchKernel_ptsz = 442, + CUPTI_DRIVER_TRACE_CBID_cuGraphicsMapResources_ptsz = 443, + CUPTI_DRIVER_TRACE_CBID_cuGraphicsUnmapResources_ptsz = 444, + CUPTI_DRIVER_TRACE_CBID_cuGLMapBufferObjectAsync_v2_ptsz = 445, + CUPTI_DRIVER_TRACE_CBID_cuEGLStreamProducerConnect = 446, + CUPTI_DRIVER_TRACE_CBID_cuEGLStreamProducerDisconnect = 447, + CUPTI_DRIVER_TRACE_CBID_cuEGLStreamProducerPresentFrame = 448, + CUPTI_DRIVER_TRACE_CBID_cuGraphicsResourceGetMappedEglFrame = 449, + CUPTI_DRIVER_TRACE_CBID_cuPointerGetAttributes = 450, + CUPTI_DRIVER_TRACE_CBID_cuOccupancyMaxActiveBlocksPerMultiprocessorWithFlags = 451, + CUPTI_DRIVER_TRACE_CBID_cuOccupancyMaxPotentialBlockSizeWithFlags = 452, + CUPTI_DRIVER_TRACE_CBID_cuEGLStreamProducerReturnFrame = 453, + CUPTI_DRIVER_TRACE_CBID_cuDeviceGetP2PAttribute = 454, + CUPTI_DRIVER_TRACE_CBID_cuTexRefSetBorderColor = 455, + CUPTI_DRIVER_TRACE_CBID_cuTexRefGetBorderColor = 456, + CUPTI_DRIVER_TRACE_CBID_cuMemAdvise = 457, + CUPTI_DRIVER_TRACE_CBID_cuStreamWaitValue32 = 458, + CUPTI_DRIVER_TRACE_CBID_cuStreamWaitValue32_ptsz = 459, + CUPTI_DRIVER_TRACE_CBID_cuStreamWriteValue32 = 460, + CUPTI_DRIVER_TRACE_CBID_cuStreamWriteValue32_ptsz = 461, + CUPTI_DRIVER_TRACE_CBID_cuStreamBatchMemOp = 462, + CUPTI_DRIVER_TRACE_CBID_cuStreamBatchMemOp_ptsz = 463, + CUPTI_DRIVER_TRACE_CBID_cuNVNbufferGetPointer = 464, + CUPTI_DRIVER_TRACE_CBID_cuNVNtextureGetArray = 465, + CUPTI_DRIVER_TRACE_CBID_cuNNSetAllocator = 466, + CUPTI_DRIVER_TRACE_CBID_cuMemPrefetchAsync = 467, + CUPTI_DRIVER_TRACE_CBID_cuMemPrefetchAsync_ptsz = 468, + CUPTI_DRIVER_TRACE_CBID_cuEventCreateFromNVNSync = 469, + CUPTI_DRIVER_TRACE_CBID_cuEGLStreamConsumerConnectWithFlags = 470, + CUPTI_DRIVER_TRACE_CBID_cuMemRangeGetAttribute = 471, + CUPTI_DRIVER_TRACE_CBID_cuMemRangeGetAttributes = 472, + CUPTI_DRIVER_TRACE_CBID_cuStreamWaitValue64 = 473, + CUPTI_DRIVER_TRACE_CBID_cuStreamWaitValue64_ptsz = 474, + CUPTI_DRIVER_TRACE_CBID_cuStreamWriteValue64 = 475, + CUPTI_DRIVER_TRACE_CBID_cuStreamWriteValue64_ptsz = 476, + CUPTI_DRIVER_TRACE_CBID_cuLaunchCooperativeKernel = 477, + CUPTI_DRIVER_TRACE_CBID_cuLaunchCooperativeKernel_ptsz = 478, + CUPTI_DRIVER_TRACE_CBID_cuEventCreateFromEGLSync = 479, + CUPTI_DRIVER_TRACE_CBID_cuLaunchCooperativeKernelMultiDevice = 480, + CUPTI_DRIVER_TRACE_CBID_cuFuncSetAttribute = 481, + CUPTI_DRIVER_TRACE_CBID_cuDeviceGetUuid = 482, + CUPTI_DRIVER_TRACE_CBID_cuStreamGetCtx = 483, + CUPTI_DRIVER_TRACE_CBID_cuStreamGetCtx_ptsz = 484, + CUPTI_DRIVER_TRACE_CBID_cuImportExternalMemory = 485, + CUPTI_DRIVER_TRACE_CBID_cuExternalMemoryGetMappedBuffer = 486, + CUPTI_DRIVER_TRACE_CBID_cuExternalMemoryGetMappedMipmappedArray = 487, + CUPTI_DRIVER_TRACE_CBID_cuDestroyExternalMemory = 488, + CUPTI_DRIVER_TRACE_CBID_cuImportExternalSemaphore = 489, + CUPTI_DRIVER_TRACE_CBID_cuSignalExternalSemaphoresAsync = 490, + CUPTI_DRIVER_TRACE_CBID_cuSignalExternalSemaphoresAsync_ptsz = 491, + CUPTI_DRIVER_TRACE_CBID_cuWaitExternalSemaphoresAsync = 492, + CUPTI_DRIVER_TRACE_CBID_cuWaitExternalSemaphoresAsync_ptsz = 493, + CUPTI_DRIVER_TRACE_CBID_cuDestroyExternalSemaphore = 494, + CUPTI_DRIVER_TRACE_CBID_cuStreamBeginCapture = 495, + CUPTI_DRIVER_TRACE_CBID_cuStreamBeginCapture_ptsz = 496, + CUPTI_DRIVER_TRACE_CBID_cuStreamEndCapture = 497, + CUPTI_DRIVER_TRACE_CBID_cuStreamEndCapture_ptsz = 498, + CUPTI_DRIVER_TRACE_CBID_cuStreamIsCapturing = 499, + CUPTI_DRIVER_TRACE_CBID_cuStreamIsCapturing_ptsz = 500, + CUPTI_DRIVER_TRACE_CBID_cuGraphCreate = 501, + CUPTI_DRIVER_TRACE_CBID_cuGraphAddKernelNode = 502, + CUPTI_DRIVER_TRACE_CBID_cuGraphKernelNodeGetParams = 503, + CUPTI_DRIVER_TRACE_CBID_cuGraphAddMemcpyNode = 504, + CUPTI_DRIVER_TRACE_CBID_cuGraphMemcpyNodeGetParams = 505, + CUPTI_DRIVER_TRACE_CBID_cuGraphAddMemsetNode = 506, + CUPTI_DRIVER_TRACE_CBID_cuGraphMemsetNodeGetParams = 507, + CUPTI_DRIVER_TRACE_CBID_cuGraphMemsetNodeSetParams = 508, + CUPTI_DRIVER_TRACE_CBID_cuGraphNodeGetType = 509, + CUPTI_DRIVER_TRACE_CBID_cuGraphGetRootNodes = 510, + CUPTI_DRIVER_TRACE_CBID_cuGraphNodeGetDependencies = 511, + CUPTI_DRIVER_TRACE_CBID_cuGraphNodeGetDependentNodes = 512, + CUPTI_DRIVER_TRACE_CBID_cuGraphInstantiate = 513, + CUPTI_DRIVER_TRACE_CBID_cuGraphLaunch = 514, + CUPTI_DRIVER_TRACE_CBID_cuGraphLaunch_ptsz = 515, + CUPTI_DRIVER_TRACE_CBID_cuGraphExecDestroy = 516, + CUPTI_DRIVER_TRACE_CBID_cuGraphDestroy = 517, + CUPTI_DRIVER_TRACE_CBID_cuGraphAddDependencies = 518, + CUPTI_DRIVER_TRACE_CBID_cuGraphRemoveDependencies = 519, + CUPTI_DRIVER_TRACE_CBID_cuGraphMemcpyNodeSetParams = 520, + CUPTI_DRIVER_TRACE_CBID_cuGraphKernelNodeSetParams = 521, + CUPTI_DRIVER_TRACE_CBID_cuGraphDestroyNode = 522, + CUPTI_DRIVER_TRACE_CBID_cuGraphClone = 523, + CUPTI_DRIVER_TRACE_CBID_cuGraphNodeFindInClone = 524, + CUPTI_DRIVER_TRACE_CBID_cuGraphAddChildGraphNode = 525, + CUPTI_DRIVER_TRACE_CBID_cuGraphAddEmptyNode = 526, + CUPTI_DRIVER_TRACE_CBID_cuLaunchHostFunc = 527, + CUPTI_DRIVER_TRACE_CBID_cuLaunchHostFunc_ptsz = 528, + CUPTI_DRIVER_TRACE_CBID_cuGraphChildGraphNodeGetGraph = 529, + CUPTI_DRIVER_TRACE_CBID_cuGraphAddHostNode = 530, + CUPTI_DRIVER_TRACE_CBID_cuGraphHostNodeGetParams = 531, + CUPTI_DRIVER_TRACE_CBID_cuDeviceGetLuid = 532, + CUPTI_DRIVER_TRACE_CBID_cuGraphHostNodeSetParams = 533, + CUPTI_DRIVER_TRACE_CBID_cuGraphGetNodes = 534, + CUPTI_DRIVER_TRACE_CBID_cuGraphGetEdges = 535, + CUPTI_DRIVER_TRACE_CBID_cuStreamGetCaptureInfo = 536, + CUPTI_DRIVER_TRACE_CBID_cuStreamGetCaptureInfo_ptsz = 537, + CUPTI_DRIVER_TRACE_CBID_cuGraphExecKernelNodeSetParams = 538, + CUPTI_DRIVER_TRACE_CBID_cuStreamBeginCapture_v2 = 539, + CUPTI_DRIVER_TRACE_CBID_cuStreamBeginCapture_v2_ptsz = 540, + CUPTI_DRIVER_TRACE_CBID_cuThreadExchangeStreamCaptureMode = 541, + CUPTI_DRIVER_TRACE_CBID_cuDeviceGetNvSciSyncAttributes = 542, + CUPTI_DRIVER_TRACE_CBID_cuOccupancyAvailableDynamicSMemPerBlock = 543, + CUPTI_DRIVER_TRACE_CBID_cuDevicePrimaryCtxRelease_v2 = 544, + CUPTI_DRIVER_TRACE_CBID_cuDevicePrimaryCtxReset_v2 = 545, + CUPTI_DRIVER_TRACE_CBID_cuDevicePrimaryCtxSetFlags_v2 = 546, + CUPTI_DRIVER_TRACE_CBID_cuMemAddressReserve = 547, + CUPTI_DRIVER_TRACE_CBID_cuMemAddressFree = 548, + CUPTI_DRIVER_TRACE_CBID_cuMemCreate = 549, + CUPTI_DRIVER_TRACE_CBID_cuMemRelease = 550, + CUPTI_DRIVER_TRACE_CBID_cuMemMap = 551, + CUPTI_DRIVER_TRACE_CBID_cuMemUnmap = 552, + CUPTI_DRIVER_TRACE_CBID_cuMemSetAccess = 553, + CUPTI_DRIVER_TRACE_CBID_cuMemExportToShareableHandle = 554, + CUPTI_DRIVER_TRACE_CBID_cuMemImportFromShareableHandle = 555, + CUPTI_DRIVER_TRACE_CBID_cuMemGetAllocationGranularity = 556, + CUPTI_DRIVER_TRACE_CBID_cuMemGetAllocationPropertiesFromHandle = 557, + CUPTI_DRIVER_TRACE_CBID_cuMemGetAccess = 558, + CUPTI_DRIVER_TRACE_CBID_cuStreamSetFlags = 559, + CUPTI_DRIVER_TRACE_CBID_cuStreamSetFlags_ptsz = 560, + CUPTI_DRIVER_TRACE_CBID_cuGraphExecUpdate = 561, + CUPTI_DRIVER_TRACE_CBID_cuGraphExecMemcpyNodeSetParams = 562, + CUPTI_DRIVER_TRACE_CBID_cuGraphExecMemsetNodeSetParams = 563, + CUPTI_DRIVER_TRACE_CBID_cuGraphExecHostNodeSetParams = 564, + CUPTI_DRIVER_TRACE_CBID_cuMemRetainAllocationHandle = 565, + CUPTI_DRIVER_TRACE_CBID_cuFuncGetModule = 566, + CUPTI_DRIVER_TRACE_CBID_cuIpcOpenMemHandle_v2 = 567, + CUPTI_DRIVER_TRACE_CBID_cuCtxResetPersistingL2Cache = 568, + CUPTI_DRIVER_TRACE_CBID_cuGraphKernelNodeCopyAttributes = 569, + CUPTI_DRIVER_TRACE_CBID_cuGraphKernelNodeGetAttribute = 570, + CUPTI_DRIVER_TRACE_CBID_cuGraphKernelNodeSetAttribute = 571, + CUPTI_DRIVER_TRACE_CBID_cuStreamCopyAttributes = 572, + CUPTI_DRIVER_TRACE_CBID_cuStreamCopyAttributes_ptsz = 573, + CUPTI_DRIVER_TRACE_CBID_cuStreamGetAttribute = 574, + CUPTI_DRIVER_TRACE_CBID_cuStreamGetAttribute_ptsz = 575, + CUPTI_DRIVER_TRACE_CBID_cuStreamSetAttribute = 576, + CUPTI_DRIVER_TRACE_CBID_cuStreamSetAttribute_ptsz = 577, + CUPTI_DRIVER_TRACE_CBID_cuGraphInstantiate_v2 = 578, + CUPTI_DRIVER_TRACE_CBID_cuDeviceGetTexture1DLinearMaxWidth = 579, + CUPTI_DRIVER_TRACE_CBID_cuGraphUpload = 580, + CUPTI_DRIVER_TRACE_CBID_cuGraphUpload_ptsz = 581, + CUPTI_DRIVER_TRACE_CBID_cuArrayGetSparseProperties = 582, + CUPTI_DRIVER_TRACE_CBID_cuMipmappedArrayGetSparseProperties = 583, + CUPTI_DRIVER_TRACE_CBID_cuMemMapArrayAsync = 584, + CUPTI_DRIVER_TRACE_CBID_cuMemMapArrayAsync_ptsz = 585, + CUPTI_DRIVER_TRACE_CBID_cuGraphExecChildGraphNodeSetParams = 586, + CUPTI_DRIVER_TRACE_CBID_cuEventRecordWithFlags = 587, + CUPTI_DRIVER_TRACE_CBID_cuEventRecordWithFlags_ptsz = 588, + CUPTI_DRIVER_TRACE_CBID_cuGraphAddEventRecordNode = 589, + CUPTI_DRIVER_TRACE_CBID_cuGraphAddEventWaitNode = 590, + CUPTI_DRIVER_TRACE_CBID_cuGraphEventRecordNodeGetEvent = 591, + CUPTI_DRIVER_TRACE_CBID_cuGraphEventWaitNodeGetEvent = 592, + CUPTI_DRIVER_TRACE_CBID_cuGraphEventRecordNodeSetEvent = 593, + CUPTI_DRIVER_TRACE_CBID_cuGraphEventWaitNodeSetEvent = 594, + CUPTI_DRIVER_TRACE_CBID_cuGraphExecEventRecordNodeSetEvent = 595, + CUPTI_DRIVER_TRACE_CBID_cuGraphExecEventWaitNodeSetEvent = 596, + CUPTI_DRIVER_TRACE_CBID_cuArrayGetPlane = 597, + CUPTI_DRIVER_TRACE_CBID_cuMemAllocAsync = 598, + CUPTI_DRIVER_TRACE_CBID_cuMemAllocAsync_ptsz = 599, + CUPTI_DRIVER_TRACE_CBID_cuMemFreeAsync = 600, + CUPTI_DRIVER_TRACE_CBID_cuMemFreeAsync_ptsz = 601, + CUPTI_DRIVER_TRACE_CBID_cuMemPoolTrimTo = 602, + CUPTI_DRIVER_TRACE_CBID_cuMemPoolSetAttribute = 603, + CUPTI_DRIVER_TRACE_CBID_cuMemPoolGetAttribute = 604, + CUPTI_DRIVER_TRACE_CBID_cuMemPoolSetAccess = 605, + CUPTI_DRIVER_TRACE_CBID_cuDeviceGetDefaultMemPool = 606, + CUPTI_DRIVER_TRACE_CBID_cuMemPoolCreate = 607, + CUPTI_DRIVER_TRACE_CBID_cuMemPoolDestroy = 608, + CUPTI_DRIVER_TRACE_CBID_cuDeviceSetMemPool = 609, + CUPTI_DRIVER_TRACE_CBID_cuDeviceGetMemPool = 610, + CUPTI_DRIVER_TRACE_CBID_cuMemAllocFromPoolAsync = 611, + CUPTI_DRIVER_TRACE_CBID_cuMemAllocFromPoolAsync_ptsz = 612, + CUPTI_DRIVER_TRACE_CBID_cuMemPoolExportToShareableHandle = 613, + CUPTI_DRIVER_TRACE_CBID_cuMemPoolImportFromShareableHandle = 614, + CUPTI_DRIVER_TRACE_CBID_cuMemPoolExportPointer = 615, + CUPTI_DRIVER_TRACE_CBID_cuMemPoolImportPointer = 616, + CUPTI_DRIVER_TRACE_CBID_cuMemPoolGetAccess = 617, + CUPTI_DRIVER_TRACE_CBID_cuGraphAddExternalSemaphoresSignalNode = 618, + CUPTI_DRIVER_TRACE_CBID_cuGraphExternalSemaphoresSignalNodeGetParams = 619, + CUPTI_DRIVER_TRACE_CBID_cuGraphExternalSemaphoresSignalNodeSetParams = 620, + CUPTI_DRIVER_TRACE_CBID_cuGraphAddExternalSemaphoresWaitNode = 621, + CUPTI_DRIVER_TRACE_CBID_cuGraphExternalSemaphoresWaitNodeGetParams = 622, + CUPTI_DRIVER_TRACE_CBID_cuGraphExternalSemaphoresWaitNodeSetParams = 623, + CUPTI_DRIVER_TRACE_CBID_cuGraphExecExternalSemaphoresSignalNodeSetParams = 624, + CUPTI_DRIVER_TRACE_CBID_cuGraphExecExternalSemaphoresWaitNodeSetParams = 625, + CUPTI_DRIVER_TRACE_CBID_cuGetProcAddress = 626, + CUPTI_DRIVER_TRACE_CBID_cuFlushGPUDirectRDMAWrites = 627, + CUPTI_DRIVER_TRACE_CBID_cuGraphDebugDotPrint = 628, + CUPTI_DRIVER_TRACE_CBID_cuStreamGetCaptureInfo_v2 = 629, + CUPTI_DRIVER_TRACE_CBID_cuStreamGetCaptureInfo_v2_ptsz = 630, + CUPTI_DRIVER_TRACE_CBID_cuStreamUpdateCaptureDependencies = 631, + CUPTI_DRIVER_TRACE_CBID_cuStreamUpdateCaptureDependencies_ptsz = 632, + CUPTI_DRIVER_TRACE_CBID_cuUserObjectCreate = 633, + CUPTI_DRIVER_TRACE_CBID_cuUserObjectRetain = 634, + CUPTI_DRIVER_TRACE_CBID_cuUserObjectRelease = 635, + CUPTI_DRIVER_TRACE_CBID_cuGraphRetainUserObject = 636, + CUPTI_DRIVER_TRACE_CBID_cuGraphReleaseUserObject = 637, + CUPTI_DRIVER_TRACE_CBID_cuGraphAddMemAllocNode = 638, + CUPTI_DRIVER_TRACE_CBID_cuGraphAddMemFreeNode = 639, + CUPTI_DRIVER_TRACE_CBID_cuDeviceGraphMemTrim = 640, + CUPTI_DRIVER_TRACE_CBID_cuDeviceGetGraphMemAttribute = 641, + CUPTI_DRIVER_TRACE_CBID_cuDeviceSetGraphMemAttribute = 642, + CUPTI_DRIVER_TRACE_CBID_cuGraphInstantiateWithFlags = 643, + CUPTI_DRIVER_TRACE_CBID_cuDeviceGetExecAffinitySupport = 644, + CUPTI_DRIVER_TRACE_CBID_cuCtxCreate_v3 = 645, + CUPTI_DRIVER_TRACE_CBID_cuCtxGetExecAffinity = 646, + CUPTI_DRIVER_TRACE_CBID_cuDeviceGetUuid_v2 = 647, + CUPTI_DRIVER_TRACE_CBID_cuGraphMemAllocNodeGetParams = 648, + CUPTI_DRIVER_TRACE_CBID_cuGraphMemFreeNodeGetParams = 649, + CUPTI_DRIVER_TRACE_CBID_cuGraphNodeSetEnabled = 650, + CUPTI_DRIVER_TRACE_CBID_cuGraphNodeGetEnabled = 651, + CUPTI_DRIVER_TRACE_CBID_cuLaunchKernelEx = 652, + CUPTI_DRIVER_TRACE_CBID_cuLaunchKernelEx_ptsz = 653, + CUPTI_DRIVER_TRACE_CBID_cuArrayGetMemoryRequirements = 654, + CUPTI_DRIVER_TRACE_CBID_cuMipmappedArrayGetMemoryRequirements = 655, + CUPTI_DRIVER_TRACE_CBID_cuGraphInstantiateWithParams = 656, + CUPTI_DRIVER_TRACE_CBID_cuGraphInstantiateWithParams_ptsz = 657, + CUPTI_DRIVER_TRACE_CBID_cuGraphExecGetFlags = 658, + CUPTI_DRIVER_TRACE_CBID_cuStreamWaitValue32_v2 = 659, + CUPTI_DRIVER_TRACE_CBID_cuStreamWaitValue32_v2_ptsz = 660, + CUPTI_DRIVER_TRACE_CBID_cuStreamWaitValue64_v2 = 661, + CUPTI_DRIVER_TRACE_CBID_cuStreamWaitValue64_v2_ptsz = 662, + CUPTI_DRIVER_TRACE_CBID_cuStreamWriteValue32_v2 = 663, + CUPTI_DRIVER_TRACE_CBID_cuStreamWriteValue32_v2_ptsz = 664, + CUPTI_DRIVER_TRACE_CBID_cuStreamWriteValue64_v2 = 665, + CUPTI_DRIVER_TRACE_CBID_cuStreamWriteValue64_v2_ptsz = 666, + CUPTI_DRIVER_TRACE_CBID_cuStreamBatchMemOp_v2 = 667, + CUPTI_DRIVER_TRACE_CBID_cuStreamBatchMemOp_v2_ptsz = 668, + CUPTI_DRIVER_TRACE_CBID_cuGraphAddBatchMemOpNode = 669, + CUPTI_DRIVER_TRACE_CBID_cuGraphBatchMemOpNodeGetParams = 670, + CUPTI_DRIVER_TRACE_CBID_cuGraphBatchMemOpNodeSetParams = 671, + CUPTI_DRIVER_TRACE_CBID_cuGraphExecBatchMemOpNodeSetParams = 672, + CUPTI_DRIVER_TRACE_CBID_cuModuleGetLoadingMode = 673, + CUPTI_DRIVER_TRACE_CBID_cuMemGetHandleForAddressRange = 674, + CUPTI_DRIVER_TRACE_CBID_cuOccupancyMaxPotentialClusterSize = 675, + CUPTI_DRIVER_TRACE_CBID_cuOccupancyMaxActiveClusters = 676, + CUPTI_DRIVER_TRACE_CBID_cuGetProcAddress_v2 = 677, + CUPTI_DRIVER_TRACE_CBID_cuLibraryLoadData = 678, + CUPTI_DRIVER_TRACE_CBID_cuLibraryLoadFromFile = 679, + CUPTI_DRIVER_TRACE_CBID_cuLibraryUnload = 680, + CUPTI_DRIVER_TRACE_CBID_cuLibraryGetKernel = 681, + CUPTI_DRIVER_TRACE_CBID_cuLibraryGetModule = 682, + CUPTI_DRIVER_TRACE_CBID_cuKernelGetFunction = 683, + CUPTI_DRIVER_TRACE_CBID_cuLibraryGetGlobal = 684, + CUPTI_DRIVER_TRACE_CBID_cuLibraryGetManaged = 685, + CUPTI_DRIVER_TRACE_CBID_cuKernelGetAttribute = 686, + CUPTI_DRIVER_TRACE_CBID_cuKernelSetAttribute = 687, + CUPTI_DRIVER_TRACE_CBID_cuKernelSetCacheConfig = 688, + CUPTI_DRIVER_TRACE_CBID_cuGraphAddKernelNode_v2 = 689, + CUPTI_DRIVER_TRACE_CBID_cuGraphKernelNodeGetParams_v2 = 690, + CUPTI_DRIVER_TRACE_CBID_cuGraphKernelNodeSetParams_v2 = 691, + CUPTI_DRIVER_TRACE_CBID_cuGraphExecKernelNodeSetParams_v2 = 692, + CUPTI_DRIVER_TRACE_CBID_cuStreamGetId = 693, + CUPTI_DRIVER_TRACE_CBID_cuStreamGetId_ptsz = 694, + CUPTI_DRIVER_TRACE_CBID_cuCtxGetId = 695, + CUPTI_DRIVER_TRACE_CBID_cuGraphExecUpdate_v2 = 696, + CUPTI_DRIVER_TRACE_CBID_cuTensorMapEncodeTiled = 697, + CUPTI_DRIVER_TRACE_CBID_cuTensorMapEncodeIm2col = 698, + CUPTI_DRIVER_TRACE_CBID_cuTensorMapReplaceAddress = 699, + CUPTI_DRIVER_TRACE_CBID_cuLibraryGetUnifiedFunction = 700, + CUPTI_DRIVER_TRACE_CBID_cuCoredumpGetAttribute = 701, + CUPTI_DRIVER_TRACE_CBID_cuCoredumpGetAttributeGlobal = 702, + CUPTI_DRIVER_TRACE_CBID_cuCoredumpSetAttribute = 703, + CUPTI_DRIVER_TRACE_CBID_cuCoredumpSetAttributeGlobal = 704, + CUPTI_DRIVER_TRACE_CBID_cuCtxSetFlags = 705, + CUPTI_DRIVER_TRACE_CBID_cuMulticastCreate = 706, + CUPTI_DRIVER_TRACE_CBID_cuMulticastAddDevice = 707, + CUPTI_DRIVER_TRACE_CBID_cuMulticastBindMem = 708, + CUPTI_DRIVER_TRACE_CBID_cuMulticastBindAddr = 709, + CUPTI_DRIVER_TRACE_CBID_cuMulticastUnbind = 710, + CUPTI_DRIVER_TRACE_CBID_cuMulticastGetGranularity = 711, + CUPTI_DRIVER_TRACE_CBID_cuGraphAddNode = 712, + CUPTI_DRIVER_TRACE_CBID_cuGraphNodeSetParams = 713, + CUPTI_DRIVER_TRACE_CBID_cuGraphExecNodeSetParams = 714, + CUPTI_DRIVER_TRACE_CBID_cuMemAdvise_v2 = 715, + CUPTI_DRIVER_TRACE_CBID_cuMemPrefetchAsync_v2 = 716, + CUPTI_DRIVER_TRACE_CBID_cuMemPrefetchAsync_v2_ptsz = 717, + CUPTI_DRIVER_TRACE_CBID_cuFuncGetName = 718, + CUPTI_DRIVER_TRACE_CBID_cuKernelGetName = 719, + CUPTI_DRIVER_TRACE_CBID_cuStreamBeginCaptureToGraph = 720, + CUPTI_DRIVER_TRACE_CBID_cuStreamBeginCaptureToGraph_ptsz = 721, + CUPTI_DRIVER_TRACE_CBID_cuGraphConditionalHandleCreate = 722, + CUPTI_DRIVER_TRACE_CBID_cuGraphAddNode_v2 = 723, + CUPTI_DRIVER_TRACE_CBID_cuGraphGetEdges_v2 = 724, + CUPTI_DRIVER_TRACE_CBID_cuGraphNodeGetDependencies_v2 = 725, + CUPTI_DRIVER_TRACE_CBID_cuGraphNodeGetDependentNodes_v2 = 726, + CUPTI_DRIVER_TRACE_CBID_cuGraphAddDependencies_v2 = 727, + CUPTI_DRIVER_TRACE_CBID_cuGraphRemoveDependencies_v2 = 728, + CUPTI_DRIVER_TRACE_CBID_cuStreamGetCaptureInfo_v3 = 729, + CUPTI_DRIVER_TRACE_CBID_cuStreamGetCaptureInfo_v3_ptsz = 730, + CUPTI_DRIVER_TRACE_CBID_cuStreamUpdateCaptureDependencies_v2 = 731, + CUPTI_DRIVER_TRACE_CBID_cuStreamUpdateCaptureDependencies_v2_ptsz = 732, + CUPTI_DRIVER_TRACE_CBID_cuFuncGetParamInfo = 733, + CUPTI_DRIVER_TRACE_CBID_cuKernelGetParamInfo = 734, + CUPTI_DRIVER_TRACE_CBID_cuDeviceRegisterAsyncNotification = 735, + CUPTI_DRIVER_TRACE_CBID_cuDeviceUnregisterAsyncNotification = 736, + CUPTI_DRIVER_TRACE_CBID_cuModuleGetFunctionCount = 737, + CUPTI_DRIVER_TRACE_CBID_cuModuleEnumerateFunctions = 738, + CUPTI_DRIVER_TRACE_CBID_cuLibraryGetKernelCount = 739, + CUPTI_DRIVER_TRACE_CBID_cuLibraryEnumerateKernels = 740, + CUPTI_DRIVER_TRACE_CBID_cuFuncIsLoaded = 741, + CUPTI_DRIVER_TRACE_CBID_cuFuncLoad = 742, + CUPTI_DRIVER_TRACE_CBID_cuGreenCtxCreate = 743, + CUPTI_DRIVER_TRACE_CBID_cuGreenCtxDestroy = 744, + CUPTI_DRIVER_TRACE_CBID_cuDeviceGetDevResource = 745, + CUPTI_DRIVER_TRACE_CBID_cuCtxGetDevResource = 746, + CUPTI_DRIVER_TRACE_CBID_cuGreenCtxGetDevResource = 747, + CUPTI_DRIVER_TRACE_CBID_cuDevResourceGenerateDesc = 748, + CUPTI_DRIVER_TRACE_CBID_cuGreenCtxRecordEvent = 749, + CUPTI_DRIVER_TRACE_CBID_cuGreenCtxWaitEvent = 750, + CUPTI_DRIVER_TRACE_CBID_cuDevSmResourceSplitByCount = 751, + CUPTI_DRIVER_TRACE_CBID_cuStreamGetGreenCtx = 752, + CUPTI_DRIVER_TRACE_CBID_cuCtxFromGreenCtx = 753, + CUPTI_DRIVER_TRACE_CBID_cuKernelGetLibrary = 754, + CUPTI_DRIVER_TRACE_CBID_cuCtxRecordEvent = 755, + CUPTI_DRIVER_TRACE_CBID_cuCtxWaitEvent = 756, + CUPTI_DRIVER_TRACE_CBID_cuCtxCreate_v4 = 757, + CUPTI_DRIVER_TRACE_CBID_cuGreenCtxStreamCreate = 758, + CUPTI_DRIVER_TRACE_CBID_cuStreamGetCtx_v2 = 759, + CUPTI_DRIVER_TRACE_CBID_cuStreamGetCtx_v2_ptsz = 760, + CUPTI_DRIVER_TRACE_CBID_cuMemBatchDecompressAsync = 761, + CUPTI_DRIVER_TRACE_CBID_cuMemBatchDecompressAsync_ptsz = 762, + CUPTI_DRIVER_TRACE_CBID_SIZE = 763, + CUPTI_DRIVER_TRACE_CBID_FORCE_INT = 0x7fffffff; + +// #endif + + +// Parsed from cupti_runtime_cbid.h + + +// ************************************************************************* +// Definitions of indices for API functions, unique across entire API +// ************************************************************************* + +// This file is generated. Any changes you make will be lost during the next clean build. +// CUDA public interface, for type definitions and cu* function prototypes + +// #if !defined(_CUPTI_RUNTIME_CBID_H) +// #define _CUPTI_RUNTIME_CBID_H + +/** enum CUpti_runtime_api_trace_cbid */ +public static final int + CUPTI_RUNTIME_TRACE_CBID_INVALID = 0, + CUPTI_RUNTIME_TRACE_CBID_cudaDriverGetVersion_v3020 = 1, + CUPTI_RUNTIME_TRACE_CBID_cudaRuntimeGetVersion_v3020 = 2, + CUPTI_RUNTIME_TRACE_CBID_cudaGetDeviceCount_v3020 = 3, + CUPTI_RUNTIME_TRACE_CBID_cudaGetDeviceProperties_v3020 = 4, + CUPTI_RUNTIME_TRACE_CBID_cudaChooseDevice_v3020 = 5, + CUPTI_RUNTIME_TRACE_CBID_cudaGetChannelDesc_v3020 = 6, + CUPTI_RUNTIME_TRACE_CBID_cudaCreateChannelDesc_v3020 = 7, + CUPTI_RUNTIME_TRACE_CBID_cudaConfigureCall_v3020 = 8, + CUPTI_RUNTIME_TRACE_CBID_cudaSetupArgument_v3020 = 9, + CUPTI_RUNTIME_TRACE_CBID_cudaGetLastError_v3020 = 10, + CUPTI_RUNTIME_TRACE_CBID_cudaPeekAtLastError_v3020 = 11, + CUPTI_RUNTIME_TRACE_CBID_cudaGetErrorString_v3020 = 12, + CUPTI_RUNTIME_TRACE_CBID_cudaLaunch_v3020 = 13, + CUPTI_RUNTIME_TRACE_CBID_cudaFuncSetCacheConfig_v3020 = 14, + CUPTI_RUNTIME_TRACE_CBID_cudaFuncGetAttributes_v3020 = 15, + CUPTI_RUNTIME_TRACE_CBID_cudaSetDevice_v3020 = 16, + CUPTI_RUNTIME_TRACE_CBID_cudaGetDevice_v3020 = 17, + CUPTI_RUNTIME_TRACE_CBID_cudaSetValidDevices_v3020 = 18, + CUPTI_RUNTIME_TRACE_CBID_cudaSetDeviceFlags_v3020 = 19, + CUPTI_RUNTIME_TRACE_CBID_cudaMalloc_v3020 = 20, + CUPTI_RUNTIME_TRACE_CBID_cudaMallocPitch_v3020 = 21, + CUPTI_RUNTIME_TRACE_CBID_cudaFree_v3020 = 22, + CUPTI_RUNTIME_TRACE_CBID_cudaMallocArray_v3020 = 23, + CUPTI_RUNTIME_TRACE_CBID_cudaFreeArray_v3020 = 24, + CUPTI_RUNTIME_TRACE_CBID_cudaMallocHost_v3020 = 25, + CUPTI_RUNTIME_TRACE_CBID_cudaFreeHost_v3020 = 26, + CUPTI_RUNTIME_TRACE_CBID_cudaHostAlloc_v3020 = 27, + CUPTI_RUNTIME_TRACE_CBID_cudaHostGetDevicePointer_v3020 = 28, + CUPTI_RUNTIME_TRACE_CBID_cudaHostGetFlags_v3020 = 29, + CUPTI_RUNTIME_TRACE_CBID_cudaMemGetInfo_v3020 = 30, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy_v3020 = 31, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy2D_v3020 = 32, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyToArray_v3020 = 33, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy2DToArray_v3020 = 34, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyFromArray_v3020 = 35, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy2DFromArray_v3020 = 36, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyArrayToArray_v3020 = 37, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy2DArrayToArray_v3020 = 38, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyToSymbol_v3020 = 39, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyFromSymbol_v3020 = 40, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyAsync_v3020 = 41, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyToArrayAsync_v3020 = 42, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyFromArrayAsync_v3020 = 43, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy2DAsync_v3020 = 44, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy2DToArrayAsync_v3020 = 45, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy2DFromArrayAsync_v3020 = 46, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyToSymbolAsync_v3020 = 47, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyFromSymbolAsync_v3020 = 48, + CUPTI_RUNTIME_TRACE_CBID_cudaMemset_v3020 = 49, + CUPTI_RUNTIME_TRACE_CBID_cudaMemset2D_v3020 = 50, + CUPTI_RUNTIME_TRACE_CBID_cudaMemsetAsync_v3020 = 51, + CUPTI_RUNTIME_TRACE_CBID_cudaMemset2DAsync_v3020 = 52, + CUPTI_RUNTIME_TRACE_CBID_cudaGetSymbolAddress_v3020 = 53, + CUPTI_RUNTIME_TRACE_CBID_cudaGetSymbolSize_v3020 = 54, + CUPTI_RUNTIME_TRACE_CBID_cudaBindTexture_v3020 = 55, + CUPTI_RUNTIME_TRACE_CBID_cudaBindTexture2D_v3020 = 56, + CUPTI_RUNTIME_TRACE_CBID_cudaBindTextureToArray_v3020 = 57, + CUPTI_RUNTIME_TRACE_CBID_cudaUnbindTexture_v3020 = 58, + CUPTI_RUNTIME_TRACE_CBID_cudaGetTextureAlignmentOffset_v3020 = 59, + CUPTI_RUNTIME_TRACE_CBID_cudaGetTextureReference_v3020 = 60, + CUPTI_RUNTIME_TRACE_CBID_cudaBindSurfaceToArray_v3020 = 61, + CUPTI_RUNTIME_TRACE_CBID_cudaGetSurfaceReference_v3020 = 62, + CUPTI_RUNTIME_TRACE_CBID_cudaGLSetGLDevice_v3020 = 63, + CUPTI_RUNTIME_TRACE_CBID_cudaGLRegisterBufferObject_v3020 = 64, + CUPTI_RUNTIME_TRACE_CBID_cudaGLMapBufferObject_v3020 = 65, + CUPTI_RUNTIME_TRACE_CBID_cudaGLUnmapBufferObject_v3020 = 66, + CUPTI_RUNTIME_TRACE_CBID_cudaGLUnregisterBufferObject_v3020 = 67, + CUPTI_RUNTIME_TRACE_CBID_cudaGLSetBufferObjectMapFlags_v3020 = 68, + CUPTI_RUNTIME_TRACE_CBID_cudaGLMapBufferObjectAsync_v3020 = 69, + CUPTI_RUNTIME_TRACE_CBID_cudaGLUnmapBufferObjectAsync_v3020 = 70, + CUPTI_RUNTIME_TRACE_CBID_cudaWGLGetDevice_v3020 = 71, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphicsGLRegisterImage_v3020 = 72, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphicsGLRegisterBuffer_v3020 = 73, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphicsUnregisterResource_v3020 = 74, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphicsResourceSetMapFlags_v3020 = 75, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphicsMapResources_v3020 = 76, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphicsUnmapResources_v3020 = 77, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphicsResourceGetMappedPointer_v3020 = 78, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphicsSubResourceGetMappedArray_v3020 = 79, + CUPTI_RUNTIME_TRACE_CBID_cudaVDPAUGetDevice_v3020 = 80, + CUPTI_RUNTIME_TRACE_CBID_cudaVDPAUSetVDPAUDevice_v3020 = 81, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphicsVDPAURegisterVideoSurface_v3020 = 82, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphicsVDPAURegisterOutputSurface_v3020 = 83, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D11GetDevice_v3020 = 84, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D11GetDevices_v3020 = 85, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D11SetDirect3DDevice_v3020 = 86, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphicsD3D11RegisterResource_v3020 = 87, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D10GetDevice_v3020 = 88, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D10GetDevices_v3020 = 89, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D10SetDirect3DDevice_v3020 = 90, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphicsD3D10RegisterResource_v3020 = 91, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D10RegisterResource_v3020 = 92, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D10UnregisterResource_v3020 = 93, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D10MapResources_v3020 = 94, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D10UnmapResources_v3020 = 95, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D10ResourceSetMapFlags_v3020 = 96, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D10ResourceGetSurfaceDimensions_v3020 = 97, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D10ResourceGetMappedArray_v3020 = 98, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D10ResourceGetMappedPointer_v3020 = 99, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D10ResourceGetMappedSize_v3020 = 100, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D10ResourceGetMappedPitch_v3020 = 101, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D9GetDevice_v3020 = 102, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D9GetDevices_v3020 = 103, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D9SetDirect3DDevice_v3020 = 104, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D9GetDirect3DDevice_v3020 = 105, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphicsD3D9RegisterResource_v3020 = 106, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D9RegisterResource_v3020 = 107, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D9UnregisterResource_v3020 = 108, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D9MapResources_v3020 = 109, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D9UnmapResources_v3020 = 110, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D9ResourceSetMapFlags_v3020 = 111, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D9ResourceGetSurfaceDimensions_v3020 = 112, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D9ResourceGetMappedArray_v3020 = 113, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D9ResourceGetMappedPointer_v3020 = 114, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D9ResourceGetMappedSize_v3020 = 115, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D9ResourceGetMappedPitch_v3020 = 116, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D9Begin_v3020 = 117, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D9End_v3020 = 118, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D9RegisterVertexBuffer_v3020 = 119, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D9UnregisterVertexBuffer_v3020 = 120, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D9MapVertexBuffer_v3020 = 121, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D9UnmapVertexBuffer_v3020 = 122, + CUPTI_RUNTIME_TRACE_CBID_cudaThreadExit_v3020 = 123, + CUPTI_RUNTIME_TRACE_CBID_cudaSetDoubleForDevice_v3020 = 124, + CUPTI_RUNTIME_TRACE_CBID_cudaSetDoubleForHost_v3020 = 125, + CUPTI_RUNTIME_TRACE_CBID_cudaThreadSynchronize_v3020 = 126, + CUPTI_RUNTIME_TRACE_CBID_cudaThreadGetLimit_v3020 = 127, + CUPTI_RUNTIME_TRACE_CBID_cudaThreadSetLimit_v3020 = 128, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamCreate_v3020 = 129, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamDestroy_v3020 = 130, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamSynchronize_v3020 = 131, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamQuery_v3020 = 132, + CUPTI_RUNTIME_TRACE_CBID_cudaEventCreate_v3020 = 133, + CUPTI_RUNTIME_TRACE_CBID_cudaEventCreateWithFlags_v3020 = 134, + CUPTI_RUNTIME_TRACE_CBID_cudaEventRecord_v3020 = 135, + CUPTI_RUNTIME_TRACE_CBID_cudaEventDestroy_v3020 = 136, + CUPTI_RUNTIME_TRACE_CBID_cudaEventSynchronize_v3020 = 137, + CUPTI_RUNTIME_TRACE_CBID_cudaEventQuery_v3020 = 138, + CUPTI_RUNTIME_TRACE_CBID_cudaEventElapsedTime_v3020 = 139, + CUPTI_RUNTIME_TRACE_CBID_cudaMalloc3D_v3020 = 140, + CUPTI_RUNTIME_TRACE_CBID_cudaMalloc3DArray_v3020 = 141, + CUPTI_RUNTIME_TRACE_CBID_cudaMemset3D_v3020 = 142, + CUPTI_RUNTIME_TRACE_CBID_cudaMemset3DAsync_v3020 = 143, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy3D_v3020 = 144, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy3DAsync_v3020 = 145, + CUPTI_RUNTIME_TRACE_CBID_cudaThreadSetCacheConfig_v3020 = 146, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamWaitEvent_v3020 = 147, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D11GetDirect3DDevice_v3020 = 148, + CUPTI_RUNTIME_TRACE_CBID_cudaD3D10GetDirect3DDevice_v3020 = 149, + CUPTI_RUNTIME_TRACE_CBID_cudaThreadGetCacheConfig_v3020 = 150, + CUPTI_RUNTIME_TRACE_CBID_cudaPointerGetAttributes_v4000 = 151, + CUPTI_RUNTIME_TRACE_CBID_cudaHostRegister_v4000 = 152, + CUPTI_RUNTIME_TRACE_CBID_cudaHostUnregister_v4000 = 153, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceCanAccessPeer_v4000 = 154, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceEnablePeerAccess_v4000 = 155, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceDisablePeerAccess_v4000 = 156, + CUPTI_RUNTIME_TRACE_CBID_cudaPeerRegister_v4000 = 157, + CUPTI_RUNTIME_TRACE_CBID_cudaPeerUnregister_v4000 = 158, + CUPTI_RUNTIME_TRACE_CBID_cudaPeerGetDevicePointer_v4000 = 159, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyPeer_v4000 = 160, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyPeerAsync_v4000 = 161, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy3DPeer_v4000 = 162, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy3DPeerAsync_v4000 = 163, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceReset_v3020 = 164, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceSynchronize_v3020 = 165, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceGetLimit_v3020 = 166, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceSetLimit_v3020 = 167, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceGetCacheConfig_v3020 = 168, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceSetCacheConfig_v3020 = 169, + CUPTI_RUNTIME_TRACE_CBID_cudaProfilerInitialize_v4000 = 170, + CUPTI_RUNTIME_TRACE_CBID_cudaProfilerStart_v4000 = 171, + CUPTI_RUNTIME_TRACE_CBID_cudaProfilerStop_v4000 = 172, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceGetByPCIBusId_v4010 = 173, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceGetPCIBusId_v4010 = 174, + CUPTI_RUNTIME_TRACE_CBID_cudaGLGetDevices_v4010 = 175, + CUPTI_RUNTIME_TRACE_CBID_cudaIpcGetEventHandle_v4010 = 176, + CUPTI_RUNTIME_TRACE_CBID_cudaIpcOpenEventHandle_v4010 = 177, + CUPTI_RUNTIME_TRACE_CBID_cudaIpcGetMemHandle_v4010 = 178, + CUPTI_RUNTIME_TRACE_CBID_cudaIpcOpenMemHandle_v4010 = 179, + CUPTI_RUNTIME_TRACE_CBID_cudaIpcCloseMemHandle_v4010 = 180, + CUPTI_RUNTIME_TRACE_CBID_cudaArrayGetInfo_v4010 = 181, + CUPTI_RUNTIME_TRACE_CBID_cudaFuncSetSharedMemConfig_v4020 = 182, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceGetSharedMemConfig_v4020 = 183, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceSetSharedMemConfig_v4020 = 184, + CUPTI_RUNTIME_TRACE_CBID_cudaCreateTextureObject_v5000 = 185, + CUPTI_RUNTIME_TRACE_CBID_cudaDestroyTextureObject_v5000 = 186, + CUPTI_RUNTIME_TRACE_CBID_cudaGetTextureObjectResourceDesc_v5000 = 187, + CUPTI_RUNTIME_TRACE_CBID_cudaGetTextureObjectTextureDesc_v5000 = 188, + CUPTI_RUNTIME_TRACE_CBID_cudaCreateSurfaceObject_v5000 = 189, + CUPTI_RUNTIME_TRACE_CBID_cudaDestroySurfaceObject_v5000 = 190, + CUPTI_RUNTIME_TRACE_CBID_cudaGetSurfaceObjectResourceDesc_v5000 = 191, + CUPTI_RUNTIME_TRACE_CBID_cudaMallocMipmappedArray_v5000 = 192, + CUPTI_RUNTIME_TRACE_CBID_cudaGetMipmappedArrayLevel_v5000 = 193, + CUPTI_RUNTIME_TRACE_CBID_cudaFreeMipmappedArray_v5000 = 194, + CUPTI_RUNTIME_TRACE_CBID_cudaBindTextureToMipmappedArray_v5000 = 195, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphicsResourceGetMappedMipmappedArray_v5000 = 196, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamAddCallback_v5000 = 197, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamCreateWithFlags_v5000 = 198, + CUPTI_RUNTIME_TRACE_CBID_cudaGetTextureObjectResourceViewDesc_v5000 = 199, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceGetAttribute_v5000 = 200, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamDestroy_v5050 = 201, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamCreateWithPriority_v5050 = 202, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamGetPriority_v5050 = 203, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamGetFlags_v5050 = 204, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceGetStreamPriorityRange_v5050 = 205, + CUPTI_RUNTIME_TRACE_CBID_cudaMallocManaged_v6000 = 206, + CUPTI_RUNTIME_TRACE_CBID_cudaOccupancyMaxActiveBlocksPerMultiprocessor_v6000 = 207, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamAttachMemAsync_v6000 = 208, + CUPTI_RUNTIME_TRACE_CBID_cudaGetErrorName_v6050 = 209, + CUPTI_RUNTIME_TRACE_CBID_cudaOccupancyMaxActiveBlocksPerMultiprocessor_v6050 = 210, + CUPTI_RUNTIME_TRACE_CBID_cudaLaunchKernel_v7000 = 211, + CUPTI_RUNTIME_TRACE_CBID_cudaGetDeviceFlags_v7000 = 212, + CUPTI_RUNTIME_TRACE_CBID_cudaLaunch_ptsz_v7000 = 213, + CUPTI_RUNTIME_TRACE_CBID_cudaLaunchKernel_ptsz_v7000 = 214, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy_ptds_v7000 = 215, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy2D_ptds_v7000 = 216, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyToArray_ptds_v7000 = 217, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy2DToArray_ptds_v7000 = 218, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyFromArray_ptds_v7000 = 219, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy2DFromArray_ptds_v7000 = 220, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyArrayToArray_ptds_v7000 = 221, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy2DArrayToArray_ptds_v7000 = 222, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyToSymbol_ptds_v7000 = 223, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyFromSymbol_ptds_v7000 = 224, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyAsync_ptsz_v7000 = 225, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyToArrayAsync_ptsz_v7000 = 226, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyFromArrayAsync_ptsz_v7000 = 227, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy2DAsync_ptsz_v7000 = 228, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy2DToArrayAsync_ptsz_v7000 = 229, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy2DFromArrayAsync_ptsz_v7000 = 230, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyToSymbolAsync_ptsz_v7000 = 231, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpyFromSymbolAsync_ptsz_v7000 = 232, + CUPTI_RUNTIME_TRACE_CBID_cudaMemset_ptds_v7000 = 233, + CUPTI_RUNTIME_TRACE_CBID_cudaMemset2D_ptds_v7000 = 234, + CUPTI_RUNTIME_TRACE_CBID_cudaMemsetAsync_ptsz_v7000 = 235, + CUPTI_RUNTIME_TRACE_CBID_cudaMemset2DAsync_ptsz_v7000 = 236, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamGetPriority_ptsz_v7000 = 237, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamGetFlags_ptsz_v7000 = 238, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamSynchronize_ptsz_v7000 = 239, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamQuery_ptsz_v7000 = 240, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamAttachMemAsync_ptsz_v7000 = 241, + CUPTI_RUNTIME_TRACE_CBID_cudaEventRecord_ptsz_v7000 = 242, + CUPTI_RUNTIME_TRACE_CBID_cudaMemset3D_ptds_v7000 = 243, + CUPTI_RUNTIME_TRACE_CBID_cudaMemset3DAsync_ptsz_v7000 = 244, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy3D_ptds_v7000 = 245, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy3DAsync_ptsz_v7000 = 246, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamWaitEvent_ptsz_v7000 = 247, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamAddCallback_ptsz_v7000 = 248, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy3DPeer_ptds_v7000 = 249, + CUPTI_RUNTIME_TRACE_CBID_cudaMemcpy3DPeerAsync_ptsz_v7000 = 250, + CUPTI_RUNTIME_TRACE_CBID_cudaOccupancyMaxActiveBlocksPerMultiprocessorWithFlags_v7000 = 251, + CUPTI_RUNTIME_TRACE_CBID_cudaMemPrefetchAsync_v8000 = 252, + CUPTI_RUNTIME_TRACE_CBID_cudaMemPrefetchAsync_ptsz_v8000 = 253, + CUPTI_RUNTIME_TRACE_CBID_cudaMemAdvise_v8000 = 254, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceGetP2PAttribute_v8000 = 255, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphicsEGLRegisterImage_v7000 = 256, + CUPTI_RUNTIME_TRACE_CBID_cudaEGLStreamConsumerConnect_v7000 = 257, + CUPTI_RUNTIME_TRACE_CBID_cudaEGLStreamConsumerDisconnect_v7000 = 258, + CUPTI_RUNTIME_TRACE_CBID_cudaEGLStreamConsumerAcquireFrame_v7000 = 259, + CUPTI_RUNTIME_TRACE_CBID_cudaEGLStreamConsumerReleaseFrame_v7000 = 260, + CUPTI_RUNTIME_TRACE_CBID_cudaEGLStreamProducerConnect_v7000 = 261, + CUPTI_RUNTIME_TRACE_CBID_cudaEGLStreamProducerDisconnect_v7000 = 262, + CUPTI_RUNTIME_TRACE_CBID_cudaEGLStreamProducerPresentFrame_v7000 = 263, + CUPTI_RUNTIME_TRACE_CBID_cudaEGLStreamProducerReturnFrame_v7000 = 264, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphicsResourceGetMappedEglFrame_v7000 = 265, + CUPTI_RUNTIME_TRACE_CBID_cudaMemRangeGetAttribute_v8000 = 266, + CUPTI_RUNTIME_TRACE_CBID_cudaMemRangeGetAttributes_v8000 = 267, + CUPTI_RUNTIME_TRACE_CBID_cudaEGLStreamConsumerConnectWithFlags_v7000 = 268, + CUPTI_RUNTIME_TRACE_CBID_cudaLaunchCooperativeKernel_v9000 = 269, + CUPTI_RUNTIME_TRACE_CBID_cudaLaunchCooperativeKernel_ptsz_v9000 = 270, + CUPTI_RUNTIME_TRACE_CBID_cudaEventCreateFromEGLSync_v9000 = 271, + CUPTI_RUNTIME_TRACE_CBID_cudaLaunchCooperativeKernelMultiDevice_v9000 = 272, + CUPTI_RUNTIME_TRACE_CBID_cudaFuncSetAttribute_v9000 = 273, + CUPTI_RUNTIME_TRACE_CBID_cudaImportExternalMemory_v10000 = 274, + CUPTI_RUNTIME_TRACE_CBID_cudaExternalMemoryGetMappedBuffer_v10000 = 275, + CUPTI_RUNTIME_TRACE_CBID_cudaExternalMemoryGetMappedMipmappedArray_v10000 = 276, + CUPTI_RUNTIME_TRACE_CBID_cudaDestroyExternalMemory_v10000 = 277, + CUPTI_RUNTIME_TRACE_CBID_cudaImportExternalSemaphore_v10000 = 278, + CUPTI_RUNTIME_TRACE_CBID_cudaSignalExternalSemaphoresAsync_v10000 = 279, + CUPTI_RUNTIME_TRACE_CBID_cudaSignalExternalSemaphoresAsync_ptsz_v10000 = 280, + CUPTI_RUNTIME_TRACE_CBID_cudaWaitExternalSemaphoresAsync_v10000 = 281, + CUPTI_RUNTIME_TRACE_CBID_cudaWaitExternalSemaphoresAsync_ptsz_v10000 = 282, + CUPTI_RUNTIME_TRACE_CBID_cudaDestroyExternalSemaphore_v10000 = 283, + CUPTI_RUNTIME_TRACE_CBID_cudaLaunchHostFunc_v10000 = 284, + CUPTI_RUNTIME_TRACE_CBID_cudaLaunchHostFunc_ptsz_v10000 = 285, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphCreate_v10000 = 286, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphKernelNodeGetParams_v10000 = 287, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphKernelNodeSetParams_v10000 = 288, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphAddKernelNode_v10000 = 289, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphAddMemcpyNode_v10000 = 290, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphMemcpyNodeGetParams_v10000 = 291, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphMemcpyNodeSetParams_v10000 = 292, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphAddMemsetNode_v10000 = 293, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphMemsetNodeGetParams_v10000 = 294, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphMemsetNodeSetParams_v10000 = 295, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphAddHostNode_v10000 = 296, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphHostNodeGetParams_v10000 = 297, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphAddChildGraphNode_v10000 = 298, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphChildGraphNodeGetGraph_v10000 = 299, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphAddEmptyNode_v10000 = 300, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphClone_v10000 = 301, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphNodeFindInClone_v10000 = 302, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphNodeGetType_v10000 = 303, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphGetRootNodes_v10000 = 304, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphNodeGetDependencies_v10000 = 305, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphNodeGetDependentNodes_v10000 = 306, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphAddDependencies_v10000 = 307, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphRemoveDependencies_v10000 = 308, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphDestroyNode_v10000 = 309, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphInstantiate_v10000 = 310, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphLaunch_v10000 = 311, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphLaunch_ptsz_v10000 = 312, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphExecDestroy_v10000 = 313, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphDestroy_v10000 = 314, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamBeginCapture_v10000 = 315, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamBeginCapture_ptsz_v10000 = 316, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamIsCapturing_v10000 = 317, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamIsCapturing_ptsz_v10000 = 318, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamEndCapture_v10000 = 319, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamEndCapture_ptsz_v10000 = 320, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphHostNodeSetParams_v10000 = 321, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphGetNodes_v10000 = 322, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphGetEdges_v10000 = 323, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamGetCaptureInfo_v10010 = 324, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamGetCaptureInfo_ptsz_v10010 = 325, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphExecKernelNodeSetParams_v10010 = 326, + CUPTI_RUNTIME_TRACE_CBID_cudaThreadExchangeStreamCaptureMode_v10010 = 327, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceGetNvSciSyncAttributes_v10020 = 328, + CUPTI_RUNTIME_TRACE_CBID_cudaOccupancyAvailableDynamicSMemPerBlock_v10200 = 329, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamSetFlags_v10200 = 330, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamSetFlags_ptsz_v10200 = 331, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphExecMemcpyNodeSetParams_v10020 = 332, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphExecMemsetNodeSetParams_v10020 = 333, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphExecHostNodeSetParams_v10020 = 334, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphExecUpdate_v10020 = 335, + CUPTI_RUNTIME_TRACE_CBID_cudaGetFuncBySymbol_v11000 = 336, + CUPTI_RUNTIME_TRACE_CBID_cudaCtxResetPersistingL2Cache_v11000 = 337, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphKernelNodeCopyAttributes_v11000 = 338, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphKernelNodeGetAttribute_v11000 = 339, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphKernelNodeSetAttribute_v11000 = 340, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamCopyAttributes_v11000 = 341, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamCopyAttributes_ptsz_v11000 = 342, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamGetAttribute_v11000 = 343, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamGetAttribute_ptsz_v11000 = 344, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamSetAttribute_v11000 = 345, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamSetAttribute_ptsz_v11000 = 346, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceGetTexture1DLinearMaxWidth_v11010 = 347, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphUpload_v10000 = 348, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphUpload_ptsz_v10000 = 349, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphAddMemcpyNodeToSymbol_v11010 = 350, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphAddMemcpyNodeFromSymbol_v11010 = 351, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphAddMemcpyNode1D_v11010 = 352, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphMemcpyNodeSetParamsToSymbol_v11010 = 353, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphMemcpyNodeSetParamsFromSymbol_v11010 = 354, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphMemcpyNodeSetParams1D_v11010 = 355, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphExecMemcpyNodeSetParamsToSymbol_v11010 = 356, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphExecMemcpyNodeSetParamsFromSymbol_v11010 = 357, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphExecMemcpyNodeSetParams1D_v11010 = 358, + CUPTI_RUNTIME_TRACE_CBID_cudaArrayGetSparseProperties_v11010 = 359, + CUPTI_RUNTIME_TRACE_CBID_cudaMipmappedArrayGetSparseProperties_v11010 = 360, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphExecChildGraphNodeSetParams_v11010 = 361, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphAddEventRecordNode_v11010 = 362, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphEventRecordNodeGetEvent_v11010 = 363, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphEventRecordNodeSetEvent_v11010 = 364, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphAddEventWaitNode_v11010 = 365, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphEventWaitNodeGetEvent_v11010 = 366, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphEventWaitNodeSetEvent_v11010 = 367, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphExecEventRecordNodeSetEvent_v11010 = 368, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphExecEventWaitNodeSetEvent_v11010 = 369, + CUPTI_RUNTIME_TRACE_CBID_cudaEventRecordWithFlags_v11010 = 370, + CUPTI_RUNTIME_TRACE_CBID_cudaEventRecordWithFlags_ptsz_v11010 = 371, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceGetDefaultMemPool_v11020 = 372, + CUPTI_RUNTIME_TRACE_CBID_cudaMallocAsync_v11020 = 373, + CUPTI_RUNTIME_TRACE_CBID_cudaMallocAsync_ptsz_v11020 = 374, + CUPTI_RUNTIME_TRACE_CBID_cudaFreeAsync_v11020 = 375, + CUPTI_RUNTIME_TRACE_CBID_cudaFreeAsync_ptsz_v11020 = 376, + CUPTI_RUNTIME_TRACE_CBID_cudaMemPoolTrimTo_v11020 = 377, + CUPTI_RUNTIME_TRACE_CBID_cudaMemPoolSetAttribute_v11020 = 378, + CUPTI_RUNTIME_TRACE_CBID_cudaMemPoolGetAttribute_v11020 = 379, + CUPTI_RUNTIME_TRACE_CBID_cudaMemPoolSetAccess_v11020 = 380, + CUPTI_RUNTIME_TRACE_CBID_cudaArrayGetPlane_v11020 = 381, + CUPTI_RUNTIME_TRACE_CBID_cudaMemPoolGetAccess_v11020 = 382, + CUPTI_RUNTIME_TRACE_CBID_cudaMemPoolCreate_v11020 = 383, + CUPTI_RUNTIME_TRACE_CBID_cudaMemPoolDestroy_v11020 = 384, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceSetMemPool_v11020 = 385, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceGetMemPool_v11020 = 386, + CUPTI_RUNTIME_TRACE_CBID_cudaMemPoolExportToShareableHandle_v11020 = 387, + CUPTI_RUNTIME_TRACE_CBID_cudaMemPoolImportFromShareableHandle_v11020 = 388, + CUPTI_RUNTIME_TRACE_CBID_cudaMemPoolExportPointer_v11020 = 389, + CUPTI_RUNTIME_TRACE_CBID_cudaMemPoolImportPointer_v11020 = 390, + CUPTI_RUNTIME_TRACE_CBID_cudaMallocFromPoolAsync_v11020 = 391, + CUPTI_RUNTIME_TRACE_CBID_cudaMallocFromPoolAsync_ptsz_v11020 = 392, + CUPTI_RUNTIME_TRACE_CBID_cudaSignalExternalSemaphoresAsync_v2_v11020 = 393, + CUPTI_RUNTIME_TRACE_CBID_cudaSignalExternalSemaphoresAsync_v2_ptsz_v11020 = 394, + CUPTI_RUNTIME_TRACE_CBID_cudaWaitExternalSemaphoresAsync_v2_v11020 = 395, + CUPTI_RUNTIME_TRACE_CBID_cudaWaitExternalSemaphoresAsync_v2_ptsz_v11020 = 396, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphAddExternalSemaphoresSignalNode_v11020 = 397, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphExternalSemaphoresSignalNodeGetParams_v11020 = 398, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphExternalSemaphoresSignalNodeSetParams_v11020 = 399, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphAddExternalSemaphoresWaitNode_v11020 = 400, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphExternalSemaphoresWaitNodeGetParams_v11020 = 401, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphExternalSemaphoresWaitNodeSetParams_v11020 = 402, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphExecExternalSemaphoresSignalNodeSetParams_v11020 = 403, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphExecExternalSemaphoresWaitNodeSetParams_v11020 = 404, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceFlushGPUDirectRDMAWrites_v11030 = 405, + CUPTI_RUNTIME_TRACE_CBID_cudaGetDriverEntryPoint_v11030 = 406, + CUPTI_RUNTIME_TRACE_CBID_cudaGetDriverEntryPoint_ptsz_v11030 = 407, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphDebugDotPrint_v11030 = 408, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamGetCaptureInfo_v2_v11030 = 409, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamGetCaptureInfo_v2_ptsz_v11030 = 410, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamUpdateCaptureDependencies_v11030 = 411, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamUpdateCaptureDependencies_ptsz_v11030 = 412, + CUPTI_RUNTIME_TRACE_CBID_cudaUserObjectCreate_v11030 = 413, + CUPTI_RUNTIME_TRACE_CBID_cudaUserObjectRetain_v11030 = 414, + CUPTI_RUNTIME_TRACE_CBID_cudaUserObjectRelease_v11030 = 415, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphRetainUserObject_v11030 = 416, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphReleaseUserObject_v11030 = 417, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphInstantiateWithFlags_v11040 = 418, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphAddMemAllocNode_v11040 = 419, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphMemAllocNodeGetParams_v11040 = 420, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphAddMemFreeNode_v11040 = 421, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphMemFreeNodeGetParams_v11040 = 422, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceGraphMemTrim_v11040 = 423, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceGetGraphMemAttribute_v11040 = 424, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceSetGraphMemAttribute_v11040 = 425, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphNodeSetEnabled_v11060 = 426, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphNodeGetEnabled_v11060 = 427, + CUPTI_RUNTIME_TRACE_CBID_cudaArrayGetMemoryRequirements_v11060 = 428, + CUPTI_RUNTIME_TRACE_CBID_cudaMipmappedArrayGetMemoryRequirements_v11060 = 429, + CUPTI_RUNTIME_TRACE_CBID_cudaLaunchKernelExC_v11060 = 430, + CUPTI_RUNTIME_TRACE_CBID_cudaLaunchKernelExC_ptsz_v11060 = 431, + CUPTI_RUNTIME_TRACE_CBID_cudaOccupancyMaxPotentialClusterSize_v11070 = 432, + CUPTI_RUNTIME_TRACE_CBID_cudaOccupancyMaxActiveClusters_v11070 = 433, + CUPTI_RUNTIME_TRACE_CBID_cudaCreateTextureObject_v2_v11080 = 434, + CUPTI_RUNTIME_TRACE_CBID_cudaGetTextureObjectTextureDesc_v2_v11080 = 435, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphInstantiateWithParams_v12000 = 436, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphInstantiateWithParams_ptsz_v12000 = 437, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphExecGetFlags_v12000 = 438, + CUPTI_RUNTIME_TRACE_CBID_cudaGetKernel_v12000 = 439, + CUPTI_RUNTIME_TRACE_CBID_cudaGetDeviceProperties_v2_v12000 = 440, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamGetId_v12000 = 441, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamGetId_ptsz_v12000 = 442, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphInstantiate_v12000 = 443, + CUPTI_RUNTIME_TRACE_CBID_cudaInitDevice_v12000 = 444, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphAddNode_v12020 = 445, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphNodeSetParams_v12020 = 446, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphExecNodeSetParams_v12020 = 447, + CUPTI_RUNTIME_TRACE_CBID_cudaMemAdvise_v2_v12020 = 448, + CUPTI_RUNTIME_TRACE_CBID_cudaMemPrefetchAsync_v2_v12020 = 449, + CUPTI_RUNTIME_TRACE_CBID_cudaMemPrefetchAsync_v2_ptsz_v12020 = 450, + CUPTI_RUNTIME_TRACE_CBID_cudaFuncGetName_v12030 = 451, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamBeginCaptureToGraph_v12030 = 452, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamBeginCaptureToGraph_ptsz_v12030 = 453, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphConditionalHandleCreate_v12030 = 454, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphGetEdges_v2_v12030 = 455, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphNodeGetDependencies_v2_v12030 = 456, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphNodeGetDependentNodes_v2_v12030 = 457, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphAddDependencies_v2_v12030 = 458, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphRemoveDependencies_v2_v12030 = 459, + CUPTI_RUNTIME_TRACE_CBID_cudaGraphAddNode_v2_v12030 = 460, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamGetCaptureInfo_v3_v12030 = 461, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamGetCaptureInfo_v3_ptsz_v12030 = 462, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamUpdateCaptureDependencies_v2_v12030 = 463, + CUPTI_RUNTIME_TRACE_CBID_cudaStreamUpdateCaptureDependencies_v2_ptsz_v12030 = 464, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceRegisterAsyncNotification_v12040 = 465, + CUPTI_RUNTIME_TRACE_CBID_cudaDeviceUnregisterAsyncNotification_v12040 = 466, + CUPTI_RUNTIME_TRACE_CBID_cudaFuncGetParamInfo_v12040 = 467, + CUPTI_RUNTIME_TRACE_CBID_cudaGetDriverEntryPointByVersion_v12050 = 468, + CUPTI_RUNTIME_TRACE_CBID_cudaGetDriverEntryPointByVersion_ptsz_v12050 = 469, + CUPTI_RUNTIME_TRACE_CBID_cuda470_v12060 = 470, + CUPTI_RUNTIME_TRACE_CBID_cuda471_v12060 = 471, + CUPTI_RUNTIME_TRACE_CBID_cuda472_v12060 = 472, + CUPTI_RUNTIME_TRACE_CBID_cuda473_v12060 = 473, + CUPTI_RUNTIME_TRACE_CBID_cuda474_v12060 = 474, + CUPTI_RUNTIME_TRACE_CBID_cuda475_v12060 = 475, + CUPTI_RUNTIME_TRACE_CBID_cuda476_v12060 = 476, + CUPTI_RUNTIME_TRACE_CBID_cuda477_v12060 = 477, + CUPTI_RUNTIME_TRACE_CBID_cuda478_v12060 = 478, + CUPTI_RUNTIME_TRACE_CBID_cuda479_v12060 = 479, + CUPTI_RUNTIME_TRACE_CBID_SIZE = 480, + CUPTI_RUNTIME_TRACE_CBID_FORCE_INT = 0x7fffffff; + +// #endif + + +// Parsed from cupti_nvtx_cbid.h + +/* + * Copyright 2013-2017 NVIDIA Corporation. All rights reserved. + * + * NOTICE TO LICENSEE: + * + * This source code and/or documentation ("Licensed Deliverables") are + * subject to NVIDIA intellectual property rights under U.S. and + * international Copyright laws. + * + * These Licensed Deliverables contained herein is PROPRIETARY and + * CONFIDENTIAL to NVIDIA and is being provided under the terms and + * conditions of a form of NVIDIA software license agreement by and + * between NVIDIA and Licensee ("License Agreement") or electronically + * accepted by Licensee. Notwithstanding any terms or conditions to + * the contrary in the License Agreement, reproduction or disclosure + * of the Licensed Deliverables to any third party without the express + * written consent of NVIDIA is prohibited. + * + * NOTWITHSTANDING ANY TERMS OR CONDITIONS TO THE CONTRARY IN THE + * LICENSE AGREEMENT, NVIDIA MAKES NO REPRESENTATION ABOUT THE + * SUITABILITY OF THESE LICENSED DELIVERABLES FOR ANY PURPOSE. IT IS + * PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY OF ANY KIND. + * NVIDIA DISCLAIMS ALL WARRANTIES WITH REGARD TO THESE LICENSED + * DELIVERABLES, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY, + * NONINFRINGEMENT, AND FITNESS FOR A PARTICULAR PURPOSE. + * NOTWITHSTANDING ANY TERMS OR CONDITIONS TO THE CONTRARY IN THE + * LICENSE AGREEMENT, IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY + * SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, OR ANY + * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, + * WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS + * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE + * OF THESE LICENSED DELIVERABLES. + * + * U.S. Government End Users. These Licensed Deliverables are a + * "commercial item" as that term is defined at 48 C.F.R. 2.101 (OCT + * 1995), consisting of "commercial computer software" and "commercial + * computer software documentation" as such terms are used in 48 + * C.F.R. 12.212 (SEPT 1995) and is provided to the U.S. Government + * only as a commercial end item. Consistent with 48 C.F.R.12.212 and + * 48 C.F.R. 227.7202-1 through 227.7202-4 (JUNE 1995), all + * U.S. Government End Users acquire the Licensed Deliverables with + * only those rights set forth herein. + * + * Any use of the Licensed Deliverables in individual and commercial + * software must include, in the user documentation and internal + * comments to the code, the above Disclaimer and U.S. Government End + * Users Notice. + */ + +// #if defined(__GNUC__) && defined(CUPTI_LIB) +// #pragma GCC visibility push(default) +// #endif + +/** enum CUpti_nvtx_api_trace_cbid */ +public static final int + CUPTI_CBID_NVTX_INVALID = 0, + CUPTI_CBID_NVTX_nvtxMarkA = 1, + CUPTI_CBID_NVTX_nvtxMarkW = 2, + CUPTI_CBID_NVTX_nvtxMarkEx = 3, + CUPTI_CBID_NVTX_nvtxRangeStartA = 4, + CUPTI_CBID_NVTX_nvtxRangeStartW = 5, + CUPTI_CBID_NVTX_nvtxRangeStartEx = 6, + CUPTI_CBID_NVTX_nvtxRangeEnd = 7, + CUPTI_CBID_NVTX_nvtxRangePushA = 8, + CUPTI_CBID_NVTX_nvtxRangePushW = 9, + CUPTI_CBID_NVTX_nvtxRangePushEx = 10, + CUPTI_CBID_NVTX_nvtxRangePop = 11, + CUPTI_CBID_NVTX_nvtxNameCategoryA = 12, + CUPTI_CBID_NVTX_nvtxNameCategoryW = 13, + CUPTI_CBID_NVTX_nvtxNameOsThreadA = 14, + CUPTI_CBID_NVTX_nvtxNameOsThreadW = 15, + CUPTI_CBID_NVTX_nvtxNameCuDeviceA = 16, + CUPTI_CBID_NVTX_nvtxNameCuDeviceW = 17, + CUPTI_CBID_NVTX_nvtxNameCuContextA = 18, + CUPTI_CBID_NVTX_nvtxNameCuContextW = 19, + CUPTI_CBID_NVTX_nvtxNameCuStreamA = 20, + CUPTI_CBID_NVTX_nvtxNameCuStreamW = 21, + CUPTI_CBID_NVTX_nvtxNameCuEventA = 22, + CUPTI_CBID_NVTX_nvtxNameCuEventW = 23, + CUPTI_CBID_NVTX_nvtxNameCudaDeviceA = 24, + CUPTI_CBID_NVTX_nvtxNameCudaDeviceW = 25, + CUPTI_CBID_NVTX_nvtxNameCudaStreamA = 26, + CUPTI_CBID_NVTX_nvtxNameCudaStreamW = 27, + CUPTI_CBID_NVTX_nvtxNameCudaEventA = 28, + CUPTI_CBID_NVTX_nvtxNameCudaEventW = 29, + CUPTI_CBID_NVTX_nvtxDomainMarkEx = 30, + CUPTI_CBID_NVTX_nvtxDomainRangeStartEx = 31, + CUPTI_CBID_NVTX_nvtxDomainRangeEnd = 32, + CUPTI_CBID_NVTX_nvtxDomainRangePushEx = 33, + CUPTI_CBID_NVTX_nvtxDomainRangePop = 34, + CUPTI_CBID_NVTX_nvtxDomainResourceCreate = 35, + CUPTI_CBID_NVTX_nvtxDomainResourceDestroy = 36, + CUPTI_CBID_NVTX_nvtxDomainNameCategoryA = 37, + CUPTI_CBID_NVTX_nvtxDomainNameCategoryW = 38, + CUPTI_CBID_NVTX_nvtxDomainRegisterStringA = 39, + CUPTI_CBID_NVTX_nvtxDomainRegisterStringW = 40, + CUPTI_CBID_NVTX_nvtxDomainCreateA = 41, + CUPTI_CBID_NVTX_nvtxDomainCreateW = 42, + CUPTI_CBID_NVTX_nvtxDomainDestroy = 43, + CUPTI_CBID_NVTX_nvtxDomainSyncUserCreate = 44, + CUPTI_CBID_NVTX_nvtxDomainSyncUserDestroy = 45, + CUPTI_CBID_NVTX_nvtxDomainSyncUserAcquireStart = 46, + CUPTI_CBID_NVTX_nvtxDomainSyncUserAcquireFailed = 47, + CUPTI_CBID_NVTX_nvtxDomainSyncUserAcquireSuccess = 48, + CUPTI_CBID_NVTX_nvtxDomainSyncUserReleasing = 49, + CUPTI_CBID_NVTX_SIZE = 50, + CUPTI_CBID_NVTX_FORCE_INT = 0x7fffffff; + +// #if defined(__GNUC__) && defined(CUPTI_LIB) +// #pragma GCC visibility pop +// #endif + + +} diff --git a/cuda/src/main/java/org/bytedeco/cuda/presets/cupti.java b/cuda/src/main/java/org/bytedeco/cuda/presets/cupti.java new file mode 100644 index 00000000000..08e56ffe4ef --- /dev/null +++ b/cuda/src/main/java/org/bytedeco/cuda/presets/cupti.java @@ -0,0 +1,55 @@ +/* + * Copyright (C) 2024 Hervé Guillemet + * + * Licensed either under the Apache License, Version 2.0, or (at your option) + * under the terms of the GNU General Public License as published by + * the Free Software Foundation (subject to the "Classpath" exception), + * either version 2, or any later version (collectively, the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.gnu.org/licenses/ + * http://www.gnu.org/software/classpath/license.html + * + * or as provided in the LICENSE.txt file that accompanied this code. + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.bytedeco.cuda.presets; + +import org.bytedeco.javacpp.annotation.NoException; +import org.bytedeco.javacpp.annotation.Platform; +import org.bytedeco.javacpp.annotation.Properties; +import org.bytedeco.javacpp.tools.Info; +import org.bytedeco.javacpp.tools.InfoMap; +import org.bytedeco.javacpp.tools.InfoMapper; + +/** + * + * @author Hervé Guillemet + */ +@Properties(inherit = cudart.class, value = { + @Platform(include = {"cupti_result.h", "cupti_version.h", "cupti_activity.h", "cupti_callbacks.h", "cupti_events.h", "cupti_metrics.h", "cupti_driver_cbid.h", "cupti_runtime_cbid.h", "cupti_nvtx_cbid.h"}, + link = "cupti@.12"), + @Platform(value = "windows-x86_64", includepath = "C:/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v12.6/extras/CUPTI/include/", linkpath = "C:/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v12.6/extras/CUPTI/lib64/", + preload = "cupti64_2024.3.0", preloadpath = "C:/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v12.6/lib64/"), + @Platform(value = {"linux-x86_64", "linux-arm64", "linux-ppc64le"}, includepath = {"/usr/local/cuda-12.6/extras/CUPTI/include/", "/usr/local/cuda/extras/CUPTI/include/"}, linkpath = {"/usr/local/cuda-12.6/extras/CUPTI/lib64/", "/usr/local/cuda/extras/CUPTI/lib64/"}), + @Platform(value = "macosx-x86_64", includepath = "/Developer/NVIDIA/CUDA-12.6/extras/CUPTI/include/", linkpath = "/Developer/NVIDIA/CUDA-12.6/extras/CUPTI/lib64/"), +}, + target = "org.bytedeco.cuda.cupti", global = "org.bytedeco.cuda.global.cupti") +@NoException +public class cupti implements InfoMapper { + public void map(InfoMap infoMap) { + infoMap + .put(new Info("CUPTIAPI").cppTypes().annotations().cppText("")) + .put(new Info("CUPTILP64").define()) + .put(new Info("CUpti_EventID", "CUpti_EventDomainID", "CUpti_MetricID", "CUpti_CallbackId", "CUpti_DeviceAttribute", "CUpti_MetricValueKind").valueTypes("int").cast().pointerTypes("IntPointer", "int[]")) // enum or uint32 + .put(new Info("CUpti_SubscriberHandle").valueTypes("@ByPtr CUpti_Subscriber_st").pointerTypes("@ByPtrPtr CUpti_Subscriber_st")) + ; + } +} diff --git a/cuda/src/main/java9/module-info.java b/cuda/src/main/java9/module-info.java index 5ac9713b9c5..d831d47b891 100644 --- a/cuda/src/main/java9/module-info.java +++ b/cuda/src/main/java9/module-info.java @@ -6,6 +6,7 @@ exports org.bytedeco.cuda.cudart; exports org.bytedeco.cuda.cudnn; exports org.bytedeco.cuda.cufftw; + exports org.bytedeco.cuda.cupti; exports org.bytedeco.cuda.curand; exports org.bytedeco.cuda.cusolver; exports org.bytedeco.cuda.cusparse;