From mboxrd@z Thu Jan 1 00:00:00 1970 From: Konrad Rzeszutek Wilk Subject: [PATCH v3] Support CPU-list parsing in xentrace. Date: Tue, 24 Mar 2015 11:39:16 -0400 Message-ID: <1427211559-15185-1-git-send-email-konrad.wilk@oracle.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta14.messagelabs.com ([193.109.254.103]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1YaQvP-0006rU-2u for xen-devel@lists.xenproject.org; Tue, 24 Mar 2015 15:39:27 +0000 List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: xen-devel@lists.xenproject.org, george.dunlap@eu.citrix.com List-Id: xen-devel@lists.xenproject.org Hey George and Ian, Since v2 [http://lists.xen.org/archives/html/xen-devel/2014-06/msg01835.html] - Redid the code per George's feedback - Expanded the xc_cpumap_* calls so that we have an 'setbit' variant. The purpose of these patches is to allow users of xentrace to narrow down a specific CPU without having to figure out a bit mask. They fix the limitation of the bit mask which is it can only do up to 32-bits - which on large machines (say 120CPUs), you can't selectively trace anything past 32CPUs. The code expands the -c parameter where you can do -c - or -c , or a combination of them. There is also the mode of automatic detection, such as: -c -, (so it will assume up to cpu2 - so 0,1, and 2 CPU), or the inverse: -c - (which will figure the max cpus and do it from cpu2 up to maximum cpu). This along with 'xl vcpu-list' makes it extremely easy to trace a specific guest (if pinned). You can still use the -c 0x option if you prefer. The patches are also at my git tree: git://xenbits.xen.org/people/konradwilk/xen.git xentrace.v3 tools/libxc/include/xenctrl.h | 16 ++- tools/libxc/xc_misc.c | 16 +++ tools/libxc/xc_tbuf.c | 26 +++-- tools/xentrace/xentrace.8 | 33 +++++- tools/xentrace/xentrace.c | 240 ++++++++++++++++++++++++++++++++++++++---- 5 files changed, 300 insertions(+), 31 deletions(-) Konrad Rzeszutek Wilk (3): libxl/cpumap: Add xc_cpumap_[setcpu, clearcpu, testcpu] to complement xc_cpumap_alloc. libxc/xentrace: Replace xc_tbuf_set_cpu_mask with CPU mask with xc_cpumap_t instead of uint32_t xentrace: Implement cpu mask range parsing of human values (-c).