From owner-freebsd-arch Thu Jan 31 18:40:15 2002 Delivered-To: freebsd-arch@freebsd.org Received: from rwcrmhc53.attbi.com (rwcrmhc53.attbi.com [204.127.198.39]) by hub.freebsd.org (Postfix) with ESMTP id 2A25D37B404 for ; Thu, 31 Jan 2002 18:40:12 -0800 (PST) Received: from InterJet.elischer.org ([12.232.206.8]) by rwcrmhc53.attbi.com (InterMail vM.4.01.03.27 201-229-121-127-20010626) with ESMTP id <20020201024011.OZND10199.rwcrmhc53.attbi.com@InterJet.elischer.org> for ; Fri, 1 Feb 2002 02:40:11 +0000 Received: from localhost (localhost.elischer.org [127.0.0.1]) by InterJet.elischer.org (8.9.1a/8.9.1) with ESMTP id SAA64109 for ; Thu, 31 Jan 2002 18:39:23 -0800 (PST) Date: Thu, 31 Jan 2002 18:39:23 -0800 (PST) From: Julian Elischer To: arch@freebsd.org Subject: KSE and SIGNALS (How to feel ill in 30 seconds) Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Well, we have no real design yet for handling signals in a multi-threaded process. In the current statem the signals would be handled by whatever thread is next returned to by the system, or in fact if it is an upcall, it would be handled on the UTS stack if that was next. (In the current incarnation, all syscalls return with an upcall so quite a few signals would be handled on the UTS stack. In other words whenever the next return to user space is made after the signal is posted, the signal will be acted upon. It is likely that we want to do something a little more consitent than this. Some possibilities: * Leave it as it is.. The signals are done on whatever thread is next, even if it is an upcall. * A special upcall location is assigned for them. The upcall is scheduled instead of whatever the next return to userland would be (which is delayed). * They are returned only on upcalls (choosing the next one up) (upcalls can be done at almost any time that there is not already an upcall in progress). * They are returned only on a particular upcall stack (but it may not be active for a while, maybe we can force it to happen. * They are retunred only on a specified user thread, (but there is nothing to say that the UTS will schedule that thread any time soon. * A separate signal stack is provided. Not an upcall, just dedicated. In addition to this is the complication that ptrace is bound up in signals as well. I'm slowely reworking ptrace so that you can specify a thread but first I have to break it away from using signals to pass it's state because signals are per-process and not per-thread.... To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message