Author pitrou
Recipients amaury.forgeotdarc, anacrolix, benjamin.peterson, georg.brandl, giampaolo.rodola, neologix, pitrou, python-dev, rosslagerwall, vstinner
Date 2012-08-04.00:35:00
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
> Is it possible to get the number of CPU to be able to convert a Python 
> set to a cpu_set?

sched_getaffinity returns EINVAL if the cpu_set is too small, so it should be easy enough to iterate.
I agree the API should be changed for something saner, and before 3.3. Sorry for not looking at the patch in more detail when it was first submitted. I will try to cook up a new patch this week-end.
Date User Action Args
2012-08-04 00:35:02pitrousetrecipients: + pitrou, georg.brandl, amaury.forgeotdarc, vstinner, giampaolo.rodola, benjamin.peterson, anacrolix, neologix, rosslagerwall, python-dev
2012-08-04 00:35:02pitrousetmessageid: <>
2012-08-04 00:35:01pitroulinkissue12655 messages
2012-08-04 00:35:00pitroucreate