Gwinel / likwid

Automatically exported from code.google.com/p/likwid
GNU General Public License v3.0
0 stars 0 forks source link

Handling of -c/-C argument in cpuset #169

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
See: https://groups.google.com/forum/#!topic/likwid-users/yS5cVVOGRZI

I think I'm hitting a small bug in Likwid's handling of logical CPU's when 
running under taskset.  When I set to L:0 within a single CPU cpuset, I get the 
expected successful result: 

nate@haswell$ taskset -c 3  likwid -C L:0 -g BRANCH test-sbb
Using logical numbering within cpuset 1 ...  |            Event             |   
core 3    |

When I request a high numbered logical CPU, I get failure as should be expected:

nate@haswell$ taskset -c 3  likwid -C L:3 -g BRANCH test-sbb
Using logical numbering within cpuset 1
ERROR - [./src/strUtil.c:430] Request cpu out of range of max 1

But when I request a CPU one beyond what should be the end, I get measurement 
and execution on Core 0 instead of an error:

nate@haswell$ taskset -c 3  likwid -C L:1 -g BRANCH test-sbb
Using logical numbering within cpuset 1  ... |            Event             |   
core 0    |

The same off-by-one leads to execution on Core 0 seems to occur when I use 
multiple CPU's in taskset.    But this error would seem to imply that the 
restriction about only running on CPU's within the current cpuset is not 
impossible, if it's something that Likwid wanted to support.  

Original issue reported on code.google.com by Thomas.R...@googlemail.com on 14 Oct 2014 at 7:55

GoogleCodeExporter commented 9 years ago
This issue was closed by revision r275.

Original comment by Thomas.R...@googlemail.com on 16 Oct 2014 at 12:33