Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp2610072pxj; Mon, 31 May 2021 06:31:05 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzWP70EX0UrodH9VHX7NHUb0SmO5Fodq0S3s4BT7z6CvVGKvidJvH0sComVKU1fM45b7t/z X-Received: by 2002:a05:6402:3512:: with SMTP id b18mr25719451edd.245.1622467864975; Mon, 31 May 2021 06:31:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1622467864; cv=none; d=google.com; s=arc-20160816; b=hC6TeviimBPS2bzoLPUEJcVC3tvQGpgD1vs1uzZ8i24nposdXio8mOS0SdYQQq2PYt qPFgxK/LGt8k3pVY+SlBbahP0Z3r9D10HXXcIWLBkGhN0KHorj2NY6PRCqZ2k52FYqe1 Kl+AB5/oZSfsAiNpx+Wb+mKccVYbGTobmzcqO0VNAMmic5r7+WBDFdf7W40MWIFbbJBf vAlc7fBbzzKN34ZILSBBiYLC2irJIRwSF9+v3WNsCT7CavM7Uktqg4ISg8k1W93bEsFS 6/eeTjCK4us0tsJKNzJAKE2j7emlj0eCKPER2j+MCzrM+3WuvR2+bss4p6nMQB6in68d 146g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=Cn+663xg9Fnis1kPt/caWzCnnri9r67XIbRUjlSvtGg=; b=qvQxdwY1DTGSCAdKMFKGsrJltneb9y2p+vGaAGPrIZtP96mxS6UrbHkru5AJB6BAvq TEfjAn5U0S/qmwtS4ujTGXrtAC7+E6SqLduc8msKXSGbpzt7+ttYE9QLEEa9y5So6jMY hJ33YZ1LhfL4CG4/O2B4RnGxnLfRe2qnMoxwXaWWFHvMwGUJBf8OCSuSUj45gtLZrG6Y 65DrB0alK3UGF8J5rr3SvFUvkrypBXlokGvnvdDzzN6MKAlPZSqGCZIYkFm0XVqDsT5s YGztGRtKoJ5mUZdP371AjtvDMCCezfdhw21QQ6di39eXLC1/tjHrGxJA2mdswpBfZ/g9 NKVw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.com header.s=susede1 header.b=cORQ88Ja; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=suse.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id e6si13984168edz.503.2021.05.31.06.30.42; Mon, 31 May 2021 06:31:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.com header.s=susede1 header.b=cORQ88Ja; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=suse.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232284AbhEaNbW (ORCPT + 99 others); Mon, 31 May 2021 09:31:22 -0400 Received: from mx2.suse.de ([195.135.220.15]:53336 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232322AbhEaNXE (ORCPT ); Mon, 31 May 2021 09:23:04 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1622467282; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=Cn+663xg9Fnis1kPt/caWzCnnri9r67XIbRUjlSvtGg=; b=cORQ88Jay6syGjcqRdfEdiKuMErohocMbegu0uQxg/gOnWoEEFeClHuWZyhAOXqHNYNuMq zkjxd+kSWelM5SgM+QYkH009HIWEyDzEiVknEJpniLx2YmKyfc7pDP2n0hUUzNfvwQMDnx 8E7hhMWNfu9JNJIZQar+kDfdVb0X3Ns= Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id E200EB4C1; Mon, 31 May 2021 13:21:21 +0000 (UTC) Date: Mon, 31 May 2021 15:21:21 +0200 From: Michal Hocko To: Vlastimil Babka Cc: Aaron Tomlin , linux-mm@kvack.org, akpm@linux-foundation.org, willy@infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v4] mm/page_alloc: bail out on fatal signal during reclaim/compaction retry attempt Message-ID: References: <20210520142901.3371299-1-atomlin@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon 31-05-21 13:35:31, Vlastimil Babka wrote: > On 5/31/21 1:33 PM, Michal Hocko wrote: > > On Thu 20-05-21 15:29:01, Aaron Tomlin wrote: > >> A customer experienced a low-memory situation and decided to issue a > >> SIGKILL (i.e. a fatal signal). Instead of promptly terminating as one > >> would expect, the aforementioned task remained unresponsive. > >> > >> Further investigation indicated that the task was "stuck" in the > >> reclaim/compaction retry loop. Now, it does not make sense to retry > >> compaction when a fatal signal is pending. > > > > Is this really true in general? The memory reclaim is retried even when > > fatal signals are pending. Why should be compaction different? I do > > agree that retrying way too much is bad but is there any reason why this > > special case doesn't follow the max retry logic? > > Compaction doesn't do anything if fatal signal is pending, it bails out > immediately and the checks are rather frequent. So why retry? OK, I was not aware of that and it would be helpful to have that mentioned in the changelog. -- Michal Hocko SUSE Labs