Received: by 2002:a05:6358:53a8:b0:117:f937:c515 with SMTP id z40csp3471076rwe; Sun, 16 Apr 2023 21:13:34 -0700 (PDT) X-Google-Smtp-Source: AKy350ZncXXCm2vtGUcwrOLnqmz8wwxG/EnnPmq7DqcQyLQWCmClyBonBgUgOy7jwPZiHqFYlRqp X-Received: by 2002:a05:6a00:140f:b0:63d:26c3:fd65 with SMTP id l15-20020a056a00140f00b0063d26c3fd65mr840887pfu.1.1681704814356; Sun, 16 Apr 2023 21:13:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681704814; cv=none; d=google.com; s=arc-20160816; b=aH9E5fjOHYdgq9zGzHlE3EuVDQH7B2OqTonXIYIfQMsEWqU/+8521uO4XYgP+q+dbD mYpNkek921Puj9VTJvuJE2X5VL/ZgW/SehG1D3AkHBo5TYzha0sh3x0bkrT0WyhboqEx LUTtGK5dU+AfuAYxcGWzytwYBrjIAiEki+DPc7uxl7d2T+XlUF6CdaNDtdwe44M43GYH Hn7FHJ0ZFn7UQcvGMpxpglyHwmeNF2MLtz97rHo0UJ9IAUWWki8f1AJiRbRmHy7y5oOt PE17yoQ4oP+ky2Qr/8hiR8J0Kvg8XfRLA0R2eLEzaC/qVQccav1oDy+KgRXFNEAZujRc NnRw== 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=WTaC8jFgNYlM5AivUFM1gcPJigYzK2LIKWBXEllK3W4=; b=xvaDqYhU6fxfYQePaMtILYxqFmAbKoPATGrMWsYf8oPoiNu7Uqo7DX/8fQZ0hM1NzR Wkpn6XxGgYXlbOGv1kvH3GN8RCviNIRRsd8FR3Dp+kPDaoSdikGxL9i4YzKjdez9Ba8Z 24nCj8lR4uZAG4TbPNaLvj+UjXJc6Fezbmbg5XVxpIk3Gu1rTIGxPFMUqFTw2CkTLr4P WGPVPyqrEtHBwW7oJiUWGqJtvzpA4GhliKxRYPFYZzPt5lJ1tuwHUXihJL/RSbZcCzoS XFHsluxANYGAB+0omWktXjlD38cZcdfYEmACTeUrsZQyfMJMaTQBDTLj9iqzzJZQZCyM DTig== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=AUGJzuQS; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id r2-20020a63ce42000000b0050bebc3e35bsi11421894pgi.766.2023.04.16.21.13.10; Sun, 16 Apr 2023 21:13:34 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=AUGJzuQS; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229740AbjDQDwp (ORCPT + 99 others); Sun, 16 Apr 2023 23:52:45 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60054 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229593AbjDQDwn (ORCPT ); Sun, 16 Apr 2023 23:52:43 -0400 Received: from mail-pj1-x102e.google.com (mail-pj1-x102e.google.com [IPv6:2607:f8b0:4864:20::102e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 659BD139 for ; Sun, 16 Apr 2023 20:52:42 -0700 (PDT) Received: by mail-pj1-x102e.google.com with SMTP id l9-20020a17090a3f0900b0023d32684e7fso13144057pjc.1 for ; Sun, 16 Apr 2023 20:52:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1681703562; x=1684295562; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=WTaC8jFgNYlM5AivUFM1gcPJigYzK2LIKWBXEllK3W4=; b=AUGJzuQSHCt5UDqx0rTAL9Yy+SUketTabUza7NWFbx6ye/lM2ccblA2XDccgSL6t0A Y0tGvwJJABKr8V7HPsklXM+p2dKulUFjWF8Qy60OijlGaqN+Z/M4Jcf8PM4YMNS9oIKP nF1cg82F10dUw8LMDAoo69tRUlBsBHQ9Y5kcU= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1681703562; x=1684295562; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=WTaC8jFgNYlM5AivUFM1gcPJigYzK2LIKWBXEllK3W4=; b=TO36I47iBFg3gaGlq5YtFmJQXDdxnUlJMDPIBWyRECsT/+t5c5TkW0TYzslS0n7Hbe w1ovwq5UMJEALr4RLRAGQIw4lkQD1wtlM8AH/SCCY29qoVFl5b4LtBrhesuauJO8G7YY wtdmKlIOSdOl5mfTHd8Kt7YYtsF7Vq6RLUhm/8l5MIEj4MG4hZ+j2Q6vJGqpxrtOFS6F fwPrjjiUhZAV38V3tqEeW5KDsOSO4I7yemMOlzB+FbupanI462VMWIKHx+Q4V/xorJHK RErFey+qadXZg1SEd4kq/Zk09PdWrq1Af2A8z6wH5x0ClzDBFN7AiIhgM5vffWs3dYQG 845Q== X-Gm-Message-State: AAQBX9dtja1hgXuk2LSepJhNq/JKoq6JZfH4nfDCuGk5CvO8Rxw905Qr 52AMJRgHr+O/zjqrWbX6vE4IFA== X-Received: by 2002:a17:902:cec1:b0:1a1:e33f:d567 with SMTP id d1-20020a170902cec100b001a1e33fd567mr13736769plg.52.1681703561783; Sun, 16 Apr 2023 20:52:41 -0700 (PDT) Received: from google.com (KD124209188001.ppp-bb.dion.ne.jp. [124.209.188.1]) by smtp.gmail.com with ESMTPSA id p7-20020a170903248700b001a68d45e52dsm6090709plw.249.2023.04.16.20.52.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 16 Apr 2023 20:52:41 -0700 (PDT) Date: Mon, 17 Apr 2023 12:52:32 +0900 From: Sergey Senozhatsky To: Yu Zhao Cc: Sergey Senozhatsky , Minchan Kim , Andrew Morton , Yosry Ahmed , linux-kernel@vger.kernel.org, linux-mm@kvack.org Subject: Re: [PATCHv4 0/4] zsmalloc: fine-grained fullness and new compaction algorithm Message-ID: <20230417035232.GM25053@google.com> References: <20230304034835.2082479-1-senozhatsky@chromium.org> <20230416151853.GK25053@google.com> <20230417024446.GL25053@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On (23/04/16 20:55), Yu Zhao wrote: > > Do you run some specific test? > > E.g., > tools/testing/selftests/kvm/max_guest_memory_test -c 112 -m 800 -s 800 > with 112 CPUs and ~770GB DRAM + 32GB zram. Hmm ... Something like this maybe? The src zspage pointer is not NULL-ed after non-empty zspage is put back to corresponding fullness list. --- @@ -2239,8 +2241,8 @@ static unsigned long __zs_compact(struct zs_pool *pool, if (fg == ZS_INUSE_RATIO_0) { free_zspage(pool, class, src_zspage); pages_freed += class->pages_per_zspage; - src_zspage = NULL; } + src_zspage = NULL; if (get_fullness_group(class, dst_zspage) == ZS_INUSE_RATIO_100 || spin_is_contended(&pool->lock)) {