Jeff wrote: > I have a program that is embarrassing parallel. > On my older computer which has an epyc 7302 (16 cores, 32 threads) it > scales very well using cygwin, and fully utilized all threads. > On my new computer which has an epyc 7B13 (64 cores, 128 threads) it > does not scale very well.
> According to the windows task manager, it only uses 74% of the cpu > resources. > The time it takes the program to run on windows is 166 seconds. > Using the same hardware on a recent version of linux, I can get 100% cpu > utilization and the program takes 100 seconds to run. > I suspect there may be something in cygwin that doesn't scale well with > lots of posix threads. > I know this is a bit of an unusual situation, but you can buy a 128 core > / 256 thread system now. > Enclosed is the output of cygcheck. > I updated my version of cygwin to be current as of today, Sep 2 2023. > thanks, > jeff Hi Jeff, Cygwin's memory allocation, and anything that uses it under the hood, such as some containers from the C++ standard library, don't scale well with many threads. I have observed even worse scalling than yours in my own massively multi-thread programs. My advice would be to either rewrite your program to centralize memory allocation in a specialized thread that serves the other processing threads, or, if you don't need Posix things, compile with the Mingw cross-compiler, which produces code that uses M$ implementation for memory allocation, which scales better. Regards, - André Bleau -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation: https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple