From owner-freebsd-hackers@freebsd.org Fri Dec 8 15:03:34 2017 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id F3EDAE85A5E for ; Fri, 8 Dec 2017 15:03:33 +0000 (UTC) (envelope-from lm@mcvoy.com) Received: from mcvoy.com (mcvoy.com [192.169.23.250]) (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 E728B7565E for ; Fri, 8 Dec 2017 15:03:33 +0000 (UTC) (envelope-from lm@mcvoy.com) Received: by mcvoy.com (Postfix, from userid 3546) id 2990535E0C0; Fri, 8 Dec 2017 07:03:33 -0800 (PST) Date: Fri, 8 Dec 2017 07:03:33 -0800 From: Larry McVoy To: Konstantin Belousov Cc: Johannes Lundberg , Larry McVoy , freebsd-hackers@freebsd.org Subject: Re: OOM problem? Message-ID: <20171208150333.GI16028@mcvoy.com> References: <20171208011430.GA16016@mcvoy.com> <20171208101658.GD2272@kib.kiev.ua> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20171208101658.GD2272@kib.kiev.ua> User-Agent: Mutt/1.5.24 (2015-08-30) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 08 Dec 2017 15:03:34 -0000 On Fri, Dec 08, 2017 at 12:16:58PM +0200, Konstantin Belousov wrote: > On Fri, Dec 08, 2017 at 08:18:21AM +0000, Johannes Lundberg wrote: > > Regarding potential oom overhaul. Personally I like the idea of an oom > > signal. The idea comes from iOS where applications get a callback when > > system memory is low and they're given a chance to free unused > > resources or resources that can easily be recreated, before getting > > killed completely. > The OOM signal is a topic which was discussed to death many times before. > The summary is that it does not work, because you need to provide pages > for userspace to be able to handle the signal. Just for the record, what I was proposing wasn't as ambitious as what Johannes suggested (while I like his idea it's "weird" and it's unlikely that Firefox et al would use it unless we got Linux to have the same thing). I was just suggesting that processes sleeping in vm_wait() wake up once in a while to respect signals, as in, if I kill -9 that process I want it to go away. Currently, it doesn't. -- --- Larry McVoy lm at mcvoy.com http://www.mcvoy.com/lm