From owner-freebsd-arch@FreeBSD.ORG Mon Apr 6 20:37:44 2015 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id CF3AA8C7 for ; Mon, 6 Apr 2015 20:37:44 +0000 (UTC) Received: from mail-ig0-x22e.google.com (mail-ig0-x22e.google.com [IPv6:2607:f8b0:4001:c05::22e]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 939A4128 for ; Mon, 6 Apr 2015 20:37:44 +0000 (UTC) Received: by igblo3 with SMTP id lo3so28943987igb.0 for ; Mon, 06 Apr 2015 13:37:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=SpxPc8W06ujAx0lDvN+5kRqeEVomOvlgbSbqZ+ILagI=; b=QVrUvsAmuiHmtTeR7AJZGmXkyRazxZloOIZbP/j5z9Oyl5CRriEYOFigHVPfXcJR4N yczAAshI+Ohs5xiL2G0/Nv7iYpkigUwsdY9tP8h8KpRX7/RO05EhfeX9yg1+JOC9pCsY RE4ukVoClFyQwM/12mVrmktjITjL0tx9dovSqGF44WW7Sj9SpzP0ca56ASQ0/mcvbtj4 RP1U9W121J4RCsKCimNx59S7qsr8OLqerSH3XBP/PVvBa1wdhvnWKvbx9NTi44HXjdms FX997t8p6D/13ARX1qrSm6Fko2ADdQrigqmzCa2saSv6vK3fxSeuUMOCJAn9pwSlb/dz V6gw== MIME-Version: 1.0 X-Received: by 10.107.155.13 with SMTP id d13mr25087212ioe.29.1428352664075; Mon, 06 Apr 2015 13:37:44 -0700 (PDT) Sender: adrian.chadd@gmail.com Received: by 10.36.17.194 with HTTP; Mon, 6 Apr 2015 13:37:44 -0700 (PDT) In-Reply-To: <8818748.ffDquhmdWF@akita> References: <8818748.ffDquhmdWF@akita> Date: Mon, 6 Apr 2015 13:37:44 -0700 X-Google-Sender-Auth: mjVf3IC6t6W1-EexlocwfZGlrSU Message-ID: Subject: Re: x86: finding interrupts that aren't being accounted for? From: Adrian Chadd To: Rui Paulo Content-Type: text/plain; charset=UTF-8 Cc: "freebsd-arch@freebsd.org" X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 06 Apr 2015 20:37:44 -0000 On 6 April 2015 at 12:01, Rui Paulo wrote: > On Monday 06 April 2015 00:21:29 Adrian Chadd wrote: >> Hi, >> >> I have an .. odd problem on a Lenovo X230. >> >> I just threw in a very old wifi card (Intel 3945) into the expresscard >> (pcie) slot. Now, we don't have any pcie-hp support in -HEAD just yet, >> but i wasn't expecting the system to crawl to a halt. >> >> When I unplug it, everything returns to normal. >> >> Other cards don't do this. >> >> So, I figured it may be interrupt spam - but vmstat -ia shows no >> interrupts going crazy. >> >> pmcstat -S CPU_CLK_UNHALTED_CORE -T -w 5 doesn't register anything >> either - only a handful of background samples. >> >> However, /counter/ mode pmc tells a different story - pmcstat -s >> CPU_CLK_UNHALTED_CORE -w 1 shows all four cores going at 110% when the >> card is inserted, with brief periods of idle. Once I remove the card, >> the counters go back down to zero. >> >> My working theory is: something is chewing CPU and it's likely >> interrupts, but if it is, it's something far, far earlier than the x86 >> interrupt C code, which counts interrupts and spurious events. >> >> So - has anyone diagnosed this stuff on FreeBSD/x86 before? I was kind >> of hoping we'd at least get accurate statistics about spurious >> interrupts, and if we don't, I'd like to understand why. > > If the cores are being used, you should be getting some samples as to where > the PC is. pmcstat doesn't show that? How about DTrace? Nope, nothing. Nothing at all shows up in the sample based checks. -adrian