Error when running in parallel

Hi everyone, I have a problem running multithreading. The first picture is of me running my application on Win10 although I use 40/48 threads, the usage performance is only <50%. While in the following picture I am running on an Ubuntu machine with the same application, the message in the htop command seems to be that the program is crashing when running in parallel. Can someone help me?