From owner-freebsd-current@FreeBSD.ORG Tue Apr 5 01:33:29 2011 Return-Path: Delivered-To: current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 657E01065670; Tue, 5 Apr 2011 01:33:29 +0000 (UTC) (envelope-from chmeeedalf@gmail.com) Received: from mail-iy0-f182.google.com (mail-iy0-f182.google.com [209.85.210.182]) by mx1.freebsd.org (Postfix) with ESMTP id 1BF7D8FC0C; Tue, 5 Apr 2011 01:33:28 +0000 (UTC) Received: by iyj12 with SMTP id 12so8120807iyj.13 for ; Mon, 04 Apr 2011 18:33:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:cc:message-id:from:to:in-reply-to:content-type :content-transfer-encoding:mime-version:subject:date:references :x-mailer; bh=6O40rcRSin/xe33TZHXy9yPNx3cWyPJhSgT/Y8SDtoE=; b=L4/HxVyY151KQMwQ00uJgufU7TUE9x7e4fU+ZmtuDnuwPcMvQNNM4Wf/Jd0hk4yvj9 JH24dCDMXXPPFT8eL09eGAQCHh8O6iYqHw2DI/qkwSu/ABqAINI4MIIbmo+zdLszJoap a+K6y/o/oU7X7hKU7eKxl3owfpjVoKxJAga/o= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=cc:message-id:from:to:in-reply-to:content-type :content-transfer-encoding:mime-version:subject:date:references :x-mailer; b=K9V3JL4mRcDsSPDR5AQpjM8ye9PIwiR+fVQRaowebiADKi/HVTqAVxJqGtlh+NE8UG ul/D3vJ9YHXGPHl7UVBz6SvE/SZjjL7VIObJclX50oAOSCEqL2Hn/lY2s/zeZmXQ6HCv ZuVQnXJLqxB1eT8th+GpejvGKiR4SAnawnmdk= Received: by 10.42.163.68 with SMTP id b4mr2667536icy.120.1301965466107; Mon, 04 Apr 2011 18:04:26 -0700 (PDT) Received: from triad.knownspace (216-15-41-8.c3-0.gth-ubr1.lnh-gth.md.cable.rcn.com [216.15.41.8]) by mx.google.com with ESMTPS id c4sm3801336ict.7.2011.04.04.18.04.24 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 04 Apr 2011 18:04:25 -0700 (PDT) Message-Id: From: Justin Hibbits To: Julian Elischer In-Reply-To: <4D9A4CE5.5090900@freebsd.org> Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Mime-Version: 1.0 (Apple Message framework v936) Date: Mon, 4 Apr 2011 21:04:23 -0400 References: <4D9A4CE5.5090900@freebsd.org> X-Mailer: Apple Mail (2.936) Cc: FreeBSD Current Subject: Re: KGDB stack traces in the kernel. X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 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: Tue, 05 Apr 2011 01:33:29 -0000 On Apr 4, 2011, at 6:57 PM, Julian Elischer wrote: > is there anyone here with enough gdb/kgdb source experience to know > what > we would need to put on the stack at fork_exit() to make it stop > when it > gets there? > > not only is it annoying but it slows down debugging because kgdb and > the ddd > front end ask for stacks a LOT. sometimes it actually just hangs as > the stack > goes into a loop and never ends. > > I had a quick look but didn't spot how gdb decides it has reached > the end of a stack. > > Julian From my experience, it checks for a NULL stack chain pointer. Once that reaches NULL, it's the end of the stack. - Justin