Replies: 1 comment 9 replies
-
Hey, Thank you for asking the question! Sure! for the first question, the answer is in the second one! it's because we want to spawn workers based on physical cores, not logical ones! |
Beta Was this translation helpful? Give feedback.
9 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello, I was reading tinypool's source code and had two questions in the
src/physicalCpuCount.ts
. I don't understand the logic for counting cpu number , could you help me with it?questions
os.cpus().length
to get cpu count instead of doing special logic for different plaforms?cat /proc/cpuinfo | grep "physical id" | sort | wc -l
instead of the logical cpu's number by the commandcat /proc/cpuinfo| grep "processor"| wc -l
?Beta Was this translation helpful? Give feedback.
All reactions