New range specification in CPU affinities, e.g 0;2-4 for processors 0;2;3;4

Started by Jeremy Collake, June 05, 2013, 03:19:11 AM

Previous topic - Next topic

Jeremy Collake

I'm completing code changes and testing necessary to support an expanded textual representation of CPU affinities. Specifically, CPU affinities where two or more consecutive processors are selected can be represented by A-B (A through B).

Processors "0;1;2;3;4" could be represented as the range "0-4". 
Processors "0;2;3;4" could be represented by "0;2-4"
Processors "0;1;2;3;4;5;6;7" would be "0-7".

Ordering isn't important, so that "2-4;0" is as valid as "0;2-4".

This will be available in v6.5.0.23 beta and later. All CPU affinities throughout the product will support this range syntax, and CPU affinities emitted in text by the product will also follow this format.

#docs
Software Engineer. Bitsum LLC.

hanemach_gt

A very clever improvement, I believe that people having more than 8 cores will find it useful, as well as extended 64-bit CPU affinity bitmask support.  8)
<img src="[url="http://imageshack.com/a/img913/7827/On37F9.gif"]http://imageshack.com/a/img913/7827/On37F9.gif[/url]"/>

BenYeeHua

Quote from: hanemach_gt on June 12, 2013, 04:03:16 PM
A very clever improvement, I believe that people having more than 8 cores will find it useful, as well as extended 64-bit CPU affinity bitmask support.  8)
Did you also means 8 core, 16 threads. ;D

Jeremy Collake

Thanks! Truth be told, I need to also allow a bitmask representation. I'll work on that next (after this next final version).
Software Engineer. Bitsum LLC.