From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: list-threads Date: Thu, 02 Aug 2018 16:53:19 +0300 Message-ID: <83o9ekvprk.fsf@gnu.org> References: <87tvoiq208.fsf@runbox.com> <83pnz4py5t.fsf@gnu.org> <874lgeoz0h.fsf@runbox.com> <83o9emm4ab.fsf@gnu.org> <87wot9onul.fsf@runbox.com> NNTP-Posting-Host: blaine.gmane.org X-Trace: blaine.gmane.org 1533217930 3251 195.159.176.226 (2 Aug 2018 13:52:10 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Thu, 2 Aug 2018 13:52:10 +0000 (UTC) Cc: emacs-devel@gnu.org To: Gemini Lasswell Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Aug 02 15:52:06 2018 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1flE1L-0000g2-K8 for ged-emacs-devel@m.gmane.org; Thu, 02 Aug 2018 15:52:03 +0200 Original-Received: from localhost ([::1]:45790 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1flE3Q-0001vU-I6 for ged-emacs-devel@m.gmane.org; Thu, 02 Aug 2018 09:54:12 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:48342) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1flE2o-0001v8-JG for emacs-devel@gnu.org; Thu, 02 Aug 2018 09:53:35 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1flE2l-0008Pw-Cj for emacs-devel@gnu.org; Thu, 02 Aug 2018 09:53:34 -0400 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:39885) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1flE2l-0008Po-8v; Thu, 02 Aug 2018 09:53:31 -0400 Original-Received: from [176.228.60.248] (port=3931 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1flE2k-0005I8-Nn; Thu, 02 Aug 2018 09:53:31 -0400 In-reply-to: <87wot9onul.fsf@runbox.com> (message from Gemini Lasswell on Wed, 01 Aug 2018 13:04:18 -0700) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:228109 Archived-At: > From: Gemini Lasswell > Cc: emacs-devel@gnu.org > Date: Wed, 01 Aug 2018 13:04:18 -0700 > > If the thread at point is not the current thread, then I'll call the new > primitive that I'm working on, maybe to be called > backtrace--get-frames-from-thread, pass it the thread as an argument, > and it will cons up a list of backtrace frames using that thread's > specpdl stack, which I can use to fill my backtrace buffer. I'm saying that this will always show a thread that is blocked, either on some mutex/condvar, or waiting for the global lock to be released. You will never be able to see the backtrace of another running thread, because the only thread that is running is the one which takes the backtrace snapshot. That question was response to what you said here: > If a thread is actively working the backtrace will just be a > snapshot of where it was when you asked for the backtrace. I'm saying that this is impossible: any thread but the current one is not "actively working".