LIU Hao wrote: > 在 2026-9-5 07:20, Kirill Makurin 写道: >> This change was one of my biggest concerns and I mentioned it in my original >> email. Do we want to have >> fast paths for all mutex types or only normal mutexes? > > There should fast paths for all of them. > >> I see two ways to move forward: >> >> 1. I drop changes from 09/24, and in updated 11/24, each `Winpthraads*Lock` >> function (or, perhaps only >> implementation for normal mutexes) will contain the fast path. >> 2. I keep 09/24 as-is as an intermediate change, and introduce fast path >> back in 11/24. >> >> The first one probably makes more sense. > > Yes.
Ok. I'll send new version of changes in coming days. >> Are there any other issues with these patches, and most >> importantly 0011.txt? > > It probably makes little sense to have a union in `WinpthreadsMutex`; you can > always allocate all fields > in one structure, and ignore unused ones. Note that in future we might need to implement more mutex types (e.g. robust POSIX mutexes), which may or may not require extra fields. Given that now logic for each mutex type is moved to a separate function, I think having a structure for each mutex type goes well along with the change. A minor, but somewhat speculative benefit, is that normal mutexes now will require slightly less heap memory than other mutex types. - Kirill Makurin _______________________________________________ Mingw-w64-public mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/mingw-w64-public
