fix intel_gpu_top parsing when engine instance id is in column (#1230)

This commit is contained in:
henrygd
2025-11-04 16:02:20 -05:00
parent 04b6067e64
commit 954400ea45
2 changed files with 12 additions and 1 deletions

View File

@@ -134,7 +134,9 @@ func (gm *GPUManager) parseIntelHeaders(header1 string, header2 string) (engineN
powerIndex = -1 // Initialize to -1, will be set to actual index if found
// Collect engine names from header1
for _, col := range h1 {
key := strings.TrimRightFunc(col, func(r rune) bool { return r >= '0' && r <= '9' })
key := strings.TrimRightFunc(col, func(r rune) bool {
return (r >= '0' && r <= '9') || r == '/'
})
var friendly string
switch key {
case "RCS":