From owner-freebsd-stable@freebsd.org Tue Jul 21 10:54:09 2015 Return-Path: Delivered-To: freebsd-stable@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 25EB89A7A65 for ; Tue, 21 Jul 2015 10:54:09 +0000 (UTC) (envelope-from slw@zxy.spb.ru) Received: from zxy.spb.ru (zxy.spb.ru [195.70.199.98]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id D66AF16A9; Tue, 21 Jul 2015 10:54:08 +0000 (UTC) (envelope-from slw@zxy.spb.ru) Received: from slw by zxy.spb.ru with local (Exim 4.84 (FreeBSD)) (envelope-from ) id 1ZHUsh-0007V9-Oq; Tue, 21 Jul 2015 13:34:39 +0300 Date: Tue, 21 Jul 2015 13:34:39 +0300 From: Slawa Olhovchenkov To: freebsd-stable@freebsd.org, Ryan Stone Subject: Re: pmcstat on selected cpu -- posible bug? Message-ID: <20150721103439.GC43740@zxy.spb.ru> References: <20150627120835.GK58397@zxy.spb.ru> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20150627120835.GK58397@zxy.spb.ru> User-Agent: Mutt/1.5.23 (2014-03-12) X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: slw@zxy.spb.ru X-SA-Exim-Scanned: No (on zxy.spb.ru); SAEximRunCond expanded to false X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 21 Jul 2015 10:54:09 -0000 On Sat, Jun 27, 2015 at 03:08:35PM +0300, Slawa Olhovchenkov wrote: > I have dual-socket E5v3 system and try to profiling source of CPU load > on first socket. I am try some expirement and this is like incorrect CPU(socket)/core selecting: selecting '-c 0' allocate system mode PMCs on 'core 0' for all sockets, not for only 'core 0 socket 0'. > cpuset -l 1 pmcstat -S CPU_CLK_UNHALTED_CORE -l 10 -c 1 -n 500 -O sample.out > pmcstat -R sample.out -G out.txt -k /boot/kernel.VSTREAM > cat out.txt | ./stackcollapse-pmc.pl | ./flamegraph.pl --width=1200 > cpi.svg > > cpi.svg can be see at http://zxy.spb.ru/cpi.svg > > I see many times send in t4_intr, but all chelsio interrupt handlers (t4_intr) > binded to second CPU socket: > > # vmstat -i > interrupt total rate > irq9: acpi0 4 0 > irq18: ehci0 ehci1 2893412 2 > irq19: xhci0 3185327 2 > cpu0:timer 1532629922 1093 > irq264: mps0 1399546223 998 > irq265: mps1 3638584876 2595 > irq266: ahci0 3049531638 2175 > irq267: ahci1 707587584 504 > irq268: mps2 6161214642 4395 > irq270: t5nex0:evt 4 0 > irq281: t5nex0:1.0 62811267214 44810 > irq282: t5nex0:1.1 63080900542 45002 > irq283: t5nex0:1.2 62979721970 44930 > irq284: t5nex0:1.3 62968826175 44922 > irq285: t5nex0:1.4 62963754266 44918 > irq286: t5nex0:1.5 63303732253 45161 > irq287: t5nex0:1.6 63012633949 44953 > irq288: t5nex0:1.7 63538714658 45328 > irq289: t5nex0:1,0 73899 0 > irq290: t5nex0:1,1 111666 0 > cpu3:timer 1534027652 1094 > cpu6:timer 1546786165 1103 > cpu13:timer 1588099533 1132 > cpu2:timer 1534703017 1094 > cpu7:timer 1553306409 1108 > cpu9:timer 1586733982 1131 > cpu1:timer 1538685850 1097 > cpu8:timer 1587569958 1132 > cpu5:timer 1537756504 1097 > cpu12:timer 1585898180 1131 > cpu4:timer 1530812247 1092 > cpu10:timer 1586851448 1132 > cpu15:timer 1586024994 1131 > cpu11:timer 1587022608 1132 > cpu14:timer 1586503852 1131 > Total 544625692623 388539 > > # cpuset -g -x 281 > irq 281 mask: 8 > irq 282 mask: 9 > irq 283 mask: 10 > irq 284 mask: 11 > irq 285 mask: 12 > irq 286 mask: 13 > irq 287 mask: 14 > irq 288 mask: 15 > irq 289 mask: 8 > irq 290 mask: 12 > > Cross-checked by dtrace: > # dtrace -n '::t4_intr:entry { @[stringof(curthread->td_name), curthread->td_oncpu] = count(); }' > dtrace: description '::t4_intr:entry ' matched 1 probe > ^C > > irq282: t5nex0:1.1 9 361413 > irq281: t5nex0:1.0 8 361573 > irq285: t5nex0:1.4 12 364535 > irq283: t5nex0:1.2 10 365919 > irq284: t5nex0:1.3 11 366386 > irq287: t5nex0:1.6 14 367603 > irq286: t5nex0:1.5 13 368409 > irq288: t5nex0:1.7 15 371441 > > What is wrong? Bug in pmcstat? > _______________________________________________ > freebsd-stable@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-stable > To unsubscribe, send any mail to "freebsd-stable-unsubscribe@freebsd.org"