From owner-svn-src-all@FreeBSD.ORG Tue Dec 9 14:21:44 2014 Return-Path: Delivered-To: svn-src-all@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 4B9E336A; Tue, 9 Dec 2014 14:21:44 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (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 37F39AEC; Tue, 9 Dec 2014 14:21:44 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.9/8.14.9) with ESMTP id sB9ELij9092071; Tue, 9 Dec 2014 14:21:44 GMT (envelope-from dchagin@FreeBSD.org) Received: (from dchagin@localhost) by svn.freebsd.org (8.14.9/8.14.9/Submit) id sB9ELiXF092070; Tue, 9 Dec 2014 14:21:44 GMT (envelope-from dchagin@FreeBSD.org) Message-Id: <201412091421.sB9ELiXF092070@svn.freebsd.org> X-Authentication-Warning: svn.freebsd.org: dchagin set sender to dchagin@FreeBSD.org using -f From: Dmitry Chagin Date: Tue, 9 Dec 2014 14:21:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r275644 - head/gnu/usr.bin/gdb/kgdb X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Dec 2014 14:21:44 -0000 Author: dchagin Date: Tue Dec 9 14:21:43 2014 New Revision: 275644 URL: https://svnweb.freebsd.org/changeset/base/275644 Log: Skip calling CPU_ISSET for NOCPU as a short period of time we can have td_oncpu is NOCPU for thread in TDS_RUNNING state. Differential Revision: https://reviews.freebsd.org/D1283 Reviewed by: jhb MFC after: 1 Month Modified: head/gnu/usr.bin/gdb/kgdb/kthr.c Modified: head/gnu/usr.bin/gdb/kgdb/kthr.c ============================================================================== --- head/gnu/usr.bin/gdb/kgdb/kthr.c Tue Dec 9 11:52:36 2014 (r275643) +++ head/gnu/usr.bin/gdb/kgdb/kthr.c Tue Dec 9 14:21:43 2014 (r275644) @@ -96,7 +96,7 @@ kgdb_thr_add_procs(uintptr_t paddr) kt->kaddr = addr; if (td.td_tid == dumptid) kt->pcb = dumppcb; - else if (td.td_state == TDS_RUNNING && + else if (td.td_oncpu != NOCPU && CPU_ISSET(td.td_oncpu, &stopped_cpus)) kt->pcb = kgdb_trgt_core_pcb(td.td_oncpu); else