[*] Build regression after ROXTL AuMin/Max update to use the common type as opposed to a stupid reference of a forced common T in the usual case of taking one of two integer values

(thats to say, the edge case of needing copy-less operator-overloaded numeric-like classes aren't used anywhere. The c++ definition of min/max is stupid; we dont ever need a reference to min/max variable)
This commit is contained in:
Reece Wilson 2023-10-17 04:58:30 +01:00
parent c8f3305669
commit f62771b6e7

View File

@ -438,11 +438,11 @@ namespace Aurora::Async
void ThreadPool::DoThing(ThreadState *pState)
{
auto uState = pState->cvHasWork;
auto uMin = AuMin<AuUInt32>(uState, pState->pendingWorkItems.size());
auto uMin = AuMin(uState, pState->pendingWorkItems.size());
if (!uMin) uMin = 1;
while (uState &&
AuAtomicCompareExchange(&pState->cvHasWork, uState - uMin, uState) != uState)
AuAtomicCompareExchange<AuUInt32>(&pState->cvHasWork, uState - uMin, uState) != uState)
{
uState = pState->cvHasWork;