Process list: type filter (#294) and secondary sort key (#473) - #500
Open
Code4me2 wants to merge 1 commit into
Open
Process list: type filter (#294) and secondary sort key (#473)#500Code4me2 wants to merge 1 commit into
Code4me2 wants to merge 1 commit into
Conversation
Two related process-list enhancements: Syllo#294 - Process type filter Add a 'Show only process type' option (All / Compute only / Graphical only) so users who mostly care about compute workloads can declutter the process list. The filter is applied after the process list is merged across devices and is also honored in the F2 setup menu and persisted in the config file (ProcessTypeFilter = all|compute|graphical). Syllo#473 - Multi-field sorting Allow a secondary sort key so the list can be ordered by e.g. GPU usage desc, then GPU memory desc. The F6 quick-sort window now supports Tab to edit the primary/secondary key ('Sort by' / 'Then by'), the F2 setup menu gains a 'Sort by (then)' dropdown, and the new option is persisted in the config file (SortBySecondary = ...). Implementation notes: - The per-field comparators were refactored into a single three-way comparator (compare_process_field) and a small chained multi-key comparator, so a uniform ascending/descending direction applies to all sort keys (matching the request's 'GPU% Desc, then GPU memory Desc'). - Adds process_none sentinel and enum process_type_filter. - New config keys: SortBySecondary, ProcessTypeFilter. Closes Syllo#294 and Syllo#473.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Two related process-list enhancements.
#294 — Filter the process list by workload type
New
Show only process typeoption: All / Compute only / Graphical only. Useful when you mainly care about compute workloads and want to hide graphical processes.enum process_type_filteroption; filter applied after the per-device process lists are merged.ProcessTypeFilter = all|compute|graphical).Validated on a DGX Spark (GB10): with the single running CUDA process (compute type),
allandcomputeshow it andgraphicalhides it.#473 — Secondary sort key (multi-field sort)
Sort by a primary field then a secondary field, e.g. GPU% desc, then GPU memory desc.
sort_processes_by_secondaryoption.Sort by/Then byand Tab switches between editing the primary and secondary key (the*marks the current key for the active mode).SortBySecondary = ..., e.g.nonewhen unset).Implementation
compare_process_field()plus a small chained multi-key comparator (compare_process_multi), sinceqsortneeds consistent0/tie handling for stable multi-key ordering. This also fixes the pre-existingcompare_process_type_asccopy-paste bug (it was comparing by name).process_nonesentinel andenum process_type_filter.Testing
#294filter verified at runtime on real hardware (compute/all show the process, graphical hides it).#473ordering verified with a unit-style harness (GPU desc→mem desc yields expected order; tie-break works).F12writesSortBySecondary/ProcessTypeFilter; snapshot loads them cleanly).Closes #294 and #473.