Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp4327179imm; Mon, 30 Jul 2018 12:32:06 -0700 (PDT) X-Google-Smtp-Source: AAOMgpcfRqUMjUPDFKv6hM3ywpE1FHajBvTdKpvikn1UxcYXcPRgCcCUmzfA60Ygt4H5Xu69OfQy X-Received: by 2002:a63:8042:: with SMTP id j63-v6mr17629297pgd.230.1532979126666; Mon, 30 Jul 2018 12:32:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1532979126; cv=none; d=google.com; s=arc-20160816; b=mhfp5ujf6Zv+5/t7YhctpOMp4x0qjXKoCh7DJ5GfA2TLGhC01mnFK4QeqZIF2DSbdc JdEjIeSg/Id31xE/JqZXVlL8ONU3DX4xYp2MroP7K1zhVPl2YAjikP3bR1dTLJUqZ9Qp zGDCjzKyoUSNtSIAu7Eu3bhGBPoYqLoE0f/CF4BlkUFeMFaSMmaXnvPbc9wgibcwwUYq b5kFOoxzK4RBW3tSqrq+d3tE+EYSpRUVr9gOcBXIsgN5qKDdzQedqyDQdVDHfY1xcnmJ MRy5xTI8qqWDIU/cjcgjtDj/N94cw57Sa1v9o1KsRv4mldpGOgqDQrwLJWb7qQFnP5dC 0svQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :references:in-reply-to:mime-version:dkim-signature :arc-authentication-results; bh=GYFPhZGe8FBZ4X/3kUFQT63F+37Gz6S3QUTd3gcx91g=; b=1F1bHBhtDUW5YqoYU3g5nmFnu6BVaGQXd/aPyQGEN5RRGH//ZXDyRmfc7z3lTGNuxk /TYDCzd4MHU3LYPNNP9k+VXAICYaqoEubBsZ4bdntlCZpFOWJUplHtEjt0sFhzEavzSQ Gc4dvunGjVjHmep5UQkWnS449eKOjtHI3cmOFtNQiML7UeqdLrxPJjc49VBp+Fm+RYUP PLrBlNtHX/aX0GW9iFKwoWtZc/bg3o68gAk7MR/PMcRI9qbCiYosggj+4DvkaxKc6oRh ovEt2GMGva31Xh9x/zkcZy9utEq5Id9HlUz2elxF/Pro0zovLpA3OvFIknqdHuO1ay5r 7HLQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=PGKweX7s; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 13-v6si11089168pgt.638.2018.07.30.12.31.52; Mon, 30 Jul 2018 12:32:06 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=PGKweX7s; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731927AbeG3VHc (ORCPT + 99 others); Mon, 30 Jul 2018 17:07:32 -0400 Received: from mail.kernel.org ([198.145.29.99]:48480 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731852AbeG3VHc (ORCPT ); Mon, 30 Jul 2018 17:07:32 -0400 Received: from mail-wm0-f46.google.com (mail-wm0-f46.google.com [74.125.82.46]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 5EAA220894 for ; Mon, 30 Jul 2018 19:31:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1532979063; bh=GYFPhZGe8FBZ4X/3kUFQT63F+37Gz6S3QUTd3gcx91g=; h=In-Reply-To:References:From:Date:Subject:To:Cc:From; b=PGKweX7sCxCYkkFTmZHHOcjoMslvVacrFMt3wy+RJA3TgUt12R/Uo0jXXP6CJXKnK y2n3iiYMJyO062WQtxXOYLn/oN5eATVOquBggNm+DsP8qTrabSnFmhoDQWy11KAhOF Z9lIqk1hBzaMIITwujFlKgVA/M8RUHLPG3nLim4Q= Received: by mail-wm0-f46.google.com with SMTP id s14-v6so592843wmc.1 for ; Mon, 30 Jul 2018 12:31:03 -0700 (PDT) X-Gm-Message-State: AOUpUlHrrpvyG6bcevA09WQ3Yb48Qht2+j7YkvxjDhRbZxBv9H+G414E QAjmaa/J0lXE4NscsK4I5JjOb74JyLEaxxAY9ALZ8w== X-Received: by 2002:a1c:f30d:: with SMTP id q13-v6mr368459wmq.36.1532979061874; Mon, 30 Jul 2018 12:31:01 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a1c:548:0:0:0:0:0 with HTTP; Mon, 30 Jul 2018 12:30:41 -0700 (PDT) In-Reply-To: <1532978146.28585.32.camel@surriel.com> References: <20180728215357.3249-1-riel@surriel.com> <20180728215357.3249-11-riel@surriel.com> <20180729155452.37eddc11@imladris.surriel.com> <20180730095502.GG2494@hirez.programming.kicks-ass.net> <1532961011.28585.30.camel@surriel.com> <20180730162653.GM2494@hirez.programming.kicks-ass.net> <1532978146.28585.32.camel@surriel.com> From: Andy Lutomirski Date: Mon, 30 Jul 2018 12:30:41 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v2 11/11] mm,sched: conditionally skip lazy TLB mm refcounting To: Rik van Riel Cc: Peter Zijlstra , Andy Lutomirski , LKML , kernel-team , X86 ML , Vitaly Kuznetsov , Ingo Molnar , Mike Galbraith , Dave Hansen , Catalin Marinas , Benjamin Herrenschmidt Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Jul 30, 2018 at 12:15 PM, Rik van Riel wrote: > On Mon, 2018-07-30 at 18:26 +0200, Peter Zijlstra wrote: >> On Mon, Jul 30, 2018 at 10:30:11AM -0400, Rik van Riel wrote: >> >> > > What happened to the rework I did there? That not only avoided >> > > fiddling >> > > with active_mm, but also avoids grab/drop cycles for the other >> > > architectures when doing task->kthread->kthread->task things. >> > >> > I don't think I saw that. I only saw your email from >> > July 20th with this fragment of code, which does not >> > appear to avoid the grab/drop cycles, and still fiddles >> > with active_mm: >> >> Yeah, that's it. Note how it doesn't do a grab+drop for kernel- >> >kernel, >> where the current could would have. >> >> And also note that it only fiddles with active_mm if it does the >> grab+drop thing (the below should have s/ifdef/ifndef/ to make more >> sense maybe). > > I'll kick off a test with your variant. I don't think we > will see any performance difference on x86 (due to not > using a refcount at all any more), but unless Ingo is in > a hurry I guess there's no issue rewriting this part of > the patch series :) > > Do the other patches look ok to you and Andy? > The whole series other than the active_mm stuff looked okay to me.