From owner-freebsd-current@FreeBSD.ORG Fri Apr 15 10:03:20 2005 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7CD2116A4CE; Fri, 15 Apr 2005 10:03:20 +0000 (GMT) Received: from lexi.siliconlandmark.com (lexi.siliconlandmark.com [209.69.98.4]) by mx1.FreeBSD.org (Postfix) with ESMTP id E07C043D2D; Fri, 15 Apr 2005 10:03:19 +0000 (GMT) (envelope-from andy@siliconlandmark.com) Received: from lexi.siliconlandmark.com (localhost [127.0.0.1]) j3FA3AJf089902; Fri, 15 Apr 2005 06:03:10 -0400 (EDT) (envelope-from andy@siliconlandmark.com) Received: from localhost (andy@localhost)j3FA2w64089899; Fri, 15 Apr 2005 06:02:58 -0400 (EDT) (envelope-from andy@siliconlandmark.com) X-Authentication-Warning: lexi.siliconlandmark.com: andy owned process doing -bs Date: Fri, 15 Apr 2005 06:02:58 -0400 (EDT) From: Andre Guibert de Bruet To: Giorgos Keramidas In-Reply-To: <20050413141957.GA40546@orion.daedalusnetworks.priv> Message-ID: <20050415055604.N93987@lexi.siliconlandmark.com> References: <425CC7F8.3030803@samsco.org> <425D2163.4090603@freebsd.org> <20050413141957.GA40546@orion.daedalusnetworks.priv> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Information: Please contact the ISP for more information X-SL-MailScanner: Found to be clean X-SL-SpamCheck: not spam, SpamAssassin (score=-2.515, required 6, autolearn=not spam, AWL 0.08, BAYES_00 -2.60) X-MailScanner-From: andy@siliconlandmark.com cc: freebsd-current@freebsd.org cc: Anthony Ginepro cc: Jiawei Ye cc: David Xu Subject: Re: How does one know how many thread a process owns? X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 15 Apr 2005 10:03:20 -0000 On Wed, 13 Apr 2005, Giorgos Keramidas wrote: > On 2005-04-13 16:08, Anthony Ginepro wrote: >> On 04/13/05 21:40, David Xu wrote: >>> Giorgos Keramidas wrote: >>>> Can you try the following patch? >>> >>> I am using the patch, it works fine, the screen output is attractive. :-) >> >> Except for WCPU it looks like SunOS' top. > > /me thinks (Oops, they caught me!) > > Yes, I have to admit, I used the output of SunOS top as an inspiration > for the ordering and naming of the THR column :-) Please commit the following patch which unbreaks the display problems which appear on 80-column terminals with the THR column (The D would wrap and cause weird behavior): Index: machine.c =================================================================== RCS file: /home/ncvs/src/usr.bin/top/machine.c,v retrieving revision 1.70 diff -r1.70 machine.c 106c106 < " PID %-*.*s THR PRI NICE SIZE RES STATE C TIME WCPU CPU COMMAND"; --- > " PID %-*.*s THR PRI NICE SIZE RES STATE C TIME WCPU CPU CMD"; 114c114 < " PID %-*.*s THR PRI NICE SIZE RES STATE TIME WCPU CPU COMMAND"; --- > " PID %-*.*s THR PRI NICE SIZE RES STATE TIME WCPU CPU CMD"; It is available online, for your convenience (Due to possible line-wrap issues with your MUA), at: http://bling.properkernel.com/freebsd/top.machine.c.patch Cheers, Andy | Andre Guibert de Bruet | Enterprise Software Consultant > | Silicon Landmark, LLC. | http://siliconlandmark.com/ >