On Fri Mar 7 09:28:55 2025 +0000, Rémi Bernon wrote:
I don't think `base_priority` makes anything clearer. https://learn.microsoft.com/en-us/windows/win32/procthread/scheduling-priori... uses that term for the absolute values, which is not what this is. Event though the ntdll constant cannot be changed, I think we should maybe use `priority_level` instead to describe the class-relative priority everywhere we can.
Yeah I originally also read that piece of documentation first (and the current nomenclature used in Wine makes sense with it), but the more I looked into how things actually work and not only ntdll constants, but also all structures fields and functions (some even documented like [KeSetPriorityThread](https://learn.microsoft.com/en-us/windows-hardware/drivers/ddi/wdm/nf-wdm-ke...) or [KeSetBasePriorityThread](https://learn.microsoft.com/en-us/windows-hardware/drivers/ddi/ntddk/nf-ntdd...)) consistently use the terms in exactly the opposite way.
Naming them like that makes everything line up perfectly AFAICT, so I think the rename is worth it here. I also wouldn't mind renaming the old thread priority to `priority_level` like you suggested per se, which would be the same amount of work... I believe the way it is in this MR now though is nicer and more consistent.