From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Newsgroups: gmane.emacs.help Subject: Re: try-this-for ? Date: Fri, 19 Jan 2018 10:25:41 +0100 Message-ID: <20180119092541.GC7809@tuxteam.de> References: <86d1277u37.fsf@zoho.com> <86r2qn5qby.fsf@zoho.com> <86vafz4922.fsf@zoho.com> <86r2qm4wjz.fsf@zoho.com> <86shb22po8.fsf@zoho.com> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; x-action=pgp-signed Content-Transfer-Encoding: 8bit X-Trace: blaine.gmane.org 1516353891 25648 195.159.176.226 (19 Jan 2018 09:24:51 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Fri, 19 Jan 2018 09:24:51 +0000 (UTC) User-Agent: Mutt/1.5.21 (2010-09-15) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Jan 19 10:24:47 2018 Return-path: Envelope-to: geh-help-gnu-emacs@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 1ecSuY-0005ei-8F for geh-help-gnu-emacs@m.gmane.org; Fri, 19 Jan 2018 10:24:34 +0100 Original-Received: from localhost ([::1]:37576 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ecSwY-00042E-96 for geh-help-gnu-emacs@m.gmane.org; Fri, 19 Jan 2018 04:26:38 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:36771) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ecSvj-00040v-RB for help-gnu-emacs@gnu.org; Fri, 19 Jan 2018 04:25:48 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ecSvf-0000UX-IA for help-gnu-emacs@gnu.org; Fri, 19 Jan 2018 04:25:47 -0500 Original-Received: from mail.tuxteam.de ([5.199.139.25]:37854) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1ecSvf-0000Rq-7M for help-gnu-emacs@gnu.org; Fri, 19 Jan 2018 04:25:43 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tuxteam.de; s=20171004; h=From:In-Reply-To:Content-Transfer-Encoding:Content-Type:MIME-Version:References:Message-ID:Subject:To:Date; bh=OxpZbHgkQLwmD5LAHQhEBrCTX6nLZ4nzW+Tvz2yOX4I=; b=q+nPOh/aZa6XDmoAJqnhOIEQf2F9TgYMMxJyM3oyu0z5GgTRBkefugh/K2q6Xlv/P35Rt4VWkMpRCv1veaHsOYpI5N1UBWjaZqm5W5foJjivMN89QmTuISt6bqx7atxKbHQvwMwtU1basES8/gSdB1FHHV+CNwKTE0Hh7u7Fi5xlvF8NqwosgJrVER3d95PPP1uaXMDLOPSQvlEa3dTgF450oAb1Td2nvk/XJfj/qrnAoWUk6r5M9eiDidtn6G+Hg8ecOuVs1NHlHYxwkG5P4fAtCPeWvPJJ3SsCMHMggwIUhrPIigHLZ5PdiHFK7BudvxPAdiiBBbd64Z5LPZNi0g==; Original-Received: from tomas by mail.tuxteam.de with local (Exim 4.80) (envelope-from ) id 1ecSvd-0002RG-3O for help-gnu-emacs@gnu.org; Fri, 19 Jan 2018 10:25:41 +0100 In-Reply-To: <86shb22po8.fsf@zoho.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy] X-Received-From: 5.199.139.25 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.org gmane.emacs.help:115787 Archived-At: -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Fri, Jan 19, 2018 at 09:55:35AM +0100, Emanuel Berg wrote: > tomas wrote: > > > I meant "user space programs" in the context > > of Unix (more precisely: an unixoid operating > > system). More specifically I meant > > "practical, useful programs" and not > > proofs-of-concepts. > > OK, but do you really have that many user space > programs that does scheduling? I'm actually enhancing one I wrote for a customer ten years ago (C, GTK2). I have written many of those. And I'm far from a special snowflake. Every interactive program (worth its salt) does scheduling. Every server which has to juggle different client requests (web server, database server, ssh daemon, you name it). In my current case, it's a GUI program. I want it to be responsive to the user, but concurrently listen to database notifications, send requests to the database and to an LDAP server, and asynchronously wait for their responses (that is: not block the GUI while doing so). At the same time it is polling an RFID card reader hung on a serial interface -- every 500 ms or so please look for it, again, without glitching the GUI or missing a database notification. Pretty standard fare, and the model isn't that different of what Emacs does or Exim or lighttpd. Under an unixoid, it reduces to watching a bunch of file descriptors using one of the asynchronous interfaces offered to you by your trusty operating system interface (select, poll, epoll, perhaps AIO if you're fancy), thinking hard about whether you need some prioritization (your life is way easier if you don't) and keeping things well organized. You notice when you don't :-) It's not magic. It's pretty "classical" as Unix goes, perhaps like [1]. Cheers [1] https://en.wikipedia.org/wiki/Advanced_Programming_in_the_Unix_Environment - -- tomás -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) iEYEARECAAYFAlphuZUACgkQBcgs9XrR2kby+QCfQOaumMt53kx3jqxMXUOkbFtA dgAAn1zpnkaq3e8vizynQUkAf5GIuILz =cKCH -----END PGP SIGNATURE-----