mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Peng Zhang <zhangpeng.00@bytedance.com>
To: Ethan Zhao <haifeng.zhao@linux.intel.com>,
	joro@8bytes.org, will@kernel.org
Cc: iommu@lists.linux.dev, linux-kernel@vger.kernel.org,
	robin.murphy@arm.com
Subject: Re: [PATCH v2] iommu/iova: Optimize alloc_iova with rbtree_augmented
Date: Fri, 26 Aug 2022 18:28:39 +0800	[thread overview]
Message-ID: <4527c925-076b-a477-4ff8-697d75f16761@bytedance.com> (raw)
In-Reply-To: <a2479500-479a-22ef-3bd2-90606a26a35e@linux.intel.com>


> Though only 3-4 drivers use alloc_iova() directly, in my understanding
> 
> your test has simulated the worst case, rcache doesn't work at all,
> 
> "alloc_iova" +“remove_iova” number looks great for worst case.

There is another case, when the size to allocate greater to 2^5, even if 
alloc_iova_fast() is used, alloc_iova() will always be called because 
the maximum iova size that rcache supports to allocate is 32.
IOVA_RANGE_CACHE_MAX_SIZE specifies the maximum size.

Thanks,

Peng

  reply	other threads:[~2022-08-26 10:28 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-24  9:51 Peng Zhang
2022-08-24 12:30 ` Ethan Zhao
2022-08-25  8:10   ` [External] " Peng Zhang
2022-08-26  8:58     ` Ethan Zhao
2022-08-26 10:28       ` Peng Zhang [this message]
2022-09-01 10:45         ` John Garry
2022-09-02  3:30           ` Peng Zhang
2022-09-21  1:15 ` wangjie (L)
2022-09-21  3:55   ` Peng Zhang
2022-09-21 10:54     ` wangjie (L)

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4527c925-076b-a477-4ff8-697d75f16761@bytedance.com \
    --to=zhangpeng.00@bytedance.com \
    --cc=haifeng.zhao@linux.intel.com \
    --cc=iommu@lists.linux.dev \
    --cc=joro@8bytes.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=robin.murphy@arm.com \
    --cc=will@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®