Portal 2 crashes if you have 128 cores, due to 15 year old assumptions
1–10 of 12 posts
Re: Portal 2 crashes if you have 128 cores, due to 15 year old assumptions
#2https://github.com/perilouswithadollarsign/cstrike15_src/blo...
Entirely reasonable that no one in 2005 would even consider the possibility of 128 core processors. I bet nobody reconsidered or even looked at that code ever since, until it started breaking because of today's extremely parallel cpus starting to get somewhat affordable for consumers.
Re: Portal 2 crashes if you have 128 cores, due to 15 year old assumptions
#3 # echo 0 > /sys/devices/system/cpu/cpu{121..127}/online
>"Disabling just one core makes the game start, but then it segfaults when the menu opens. Disabling six cores makes the menu work. Disabling seven makes the rest of the game work too."What path do you walk to be able to figure out this kind of black magic by yourself?
Re: Portal 2 crashes if you have 128 cores, due to 15 year old assumptions
#4> "The solution?" # echo 0 > /sys/devices/system/cpu/cpu{121..127}/online > "Disabling just one core makes the game start, but then it segfaults when the menu opens. Disabling six cores makes the menu work. Disabling seven makes the rest of the game work too. " What path do you walk to be able to figure out this kind of black magic by yourself?
Re: Portal 2 crashes if you have 128 cores, due to 15 year old assumptions
#5> "The solution?" # echo 0 > /sys/devices/system/cpu/cpu{121..127}/online > "Disabling just one core makes the game start, but then it segfaults when the menu opens. Disabling six cores makes the menu work. Disabling seven makes the rest of the game work too. " What path do you walk to be able to figure out this kind of black magic by yourself?
They're still consuming about the same power they would normally (when idle) :)
Edit: cpusets would probably handle this better dynamically. I'm not sure if that influences the count visible to a process
Re: Portal 2 crashes if you have 128 cores, due to 15 year old assumptions
#6Re: Portal 2 crashes if you have 128 cores, due to 15 year old assumptions
#7MAX_THREAD_IDS is defined as 128 in a file with a copyright notice of 2005, which was when the very first consumer dual core processors started getting released: https://github.com/perilouswithadollarsign/cstrike15_src/blo... Entirely reasonable that no one in 2005 would even consider the possibility of 128 core processors. I bet nobody reconsidered or even looked at that code ever since, until it started breaking be…
Re: Portal 2 crashes if you have 128 cores, due to 15 year old assumptions
#8> "The solution?" # echo 0 > /sys/devices/system/cpu/cpu{121..127}/online > "Disabling just one core makes the game start, but then it segfaults when the menu opens. Disabling six cores makes the menu work. Disabling seven makes the rest of the game work too. " What path do you walk to be able to figure out this kind of black magic by yourself?
Just reading a book on the Linux kernel and it's structure should be enough to get you going.
Re: Portal 2 crashes if you have 128 cores, due to 15 year old assumptions
#9Re: Portal 2 crashes if you have 128 cores, due to 15 year old assumptions
#10To be fair, the issue is not that there are too many physical cores, or that someone set that constant to 128. The issue is the code that spawns 1 thread per core doesn't check that constant to limit how many threads it spawns.