Skip to content

Commit b305bb7

Browse files
authored
Update GPU profile types for PC sampling (#6362)
1 parent 6c73af5 commit b305bb7

2 files changed

Lines changed: 19 additions & 1 deletion

File tree

ui/packages/shared/profile/src/ProfileMetricsGraph/index.tsx

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -368,9 +368,15 @@ const ProfileMetricsGraph = ({
368368
yAxisLabel = 'CPU Cores';
369369
yAxisUnit = '';
370370
}
371-
if (sampleType === 'cuda') {
371+
if (sampleType === 'cuda' || sampleType === 'gpu_time') {
372372
yAxisLabel = 'GPU Time';
373373
}
374+
if (sampleType === 'gpu_kernel_time') {
375+
yAxisLabel = 'GPU Kernel Time';
376+
}
377+
if (sampleType === 'gpu_stall_time') {
378+
yAxisLabel = 'GPU Stall Time';
379+
}
374380
}
375381
if (sampleUnit === 'bytes') {
376382
yAxisLabel = 'Bytes per Second';

ui/packages/shared/profile/src/ProfileTypeSelector/index.tsx

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,18 @@ export const wellKnownProfiles: WellKnownProfiles = {
111111
name: 'On-GPU',
112112
help: 'Time spent on the GPU.',
113113
},
114+
'parca_agent:gpu_time:nanoseconds:gpu_time:nanoseconds:delta': {
115+
name: 'On-GPU',
116+
help: 'Time spent on the GPU. Combines kernel execution time and PC stall samples; the gpu_view label distinguishes the two views.',
117+
},
118+
'parca_agent:gpu_kernel_time:nanoseconds:gpu_kernel_time:nanoseconds:delta': {
119+
name: 'On-GPU',
120+
help: 'GPU kernel execution time measured via CUDA runtime callbacks.',
121+
},
122+
'parca_agent:gpu_stall_time:nanoseconds:gpu_stall_time:nanoseconds:delta': {
123+
name: 'GPU Stalls',
124+
help: 'GPU stall time accumulated from PC sampling — shows where threads were waiting on the GPU.',
125+
},
114126
};
115127

116128
export function flexibleWellKnownProfileMatching(name: string): WellKnownProfile | undefined {

0 commit comments

Comments
 (0)