lttng-dev.lists.lttng.org archive mirror
 help / color / mirror / Atom feed
From: Mathieu Desnoyers via lttng-dev <lttng-dev@lists.lttng.org>
To: Lego Lin <lego.lin@gmail.com>
Cc: lttng-dev <lttng-dev@lists.lttng.org>
Subject: Re: [lttng-dev] Using rculist for dirty tracking
Date: Fri, 7 Aug 2020 12:36:27 -0400 (EDT)	[thread overview]
Message-ID: <1009482720.2512.1596818187667.JavaMail.zimbra@efficios.com> (raw)
In-Reply-To: <CALR1Az+iE_0smhqj2saNsc0+KFPVSrH+ki59gKc4NjVvYdVkQA@mail.gmail.com>


[-- Attachment #1.1: Type: text/plain, Size: 1843 bytes --]

----- On Aug 7, 2020, at 3:24 AM, lttng-dev <lttng-dev@lists.lttng.org> wrote: 

> Hi,
> I am new for using rcu and I need some helps for integrating user space rcu into
> my project for solving performance issue.
> In my project, I create 2 link list - one for free pool, one for using pool.
> Free pool used to hold a segment of memory that no-one use.
> Using pool used to hold a segment of memory that someone use.
> Originally, I use a pthread_spin_lock to protect
> 1. alloc memory segment from free pool, and move memory segment from free pool
> to using pool
> 2. free memory segment from using pool, and move memory segment from free pool
> to using pool

I suspect we would need to know the entire intended design here in order to start 
a discussion. What operations are doing list traversals ? What operations are doing 
updates ? How frequently are each respective operation done ? Do you intend to 
keep your spin lock to protect concurrent list updates, and if not how do you plan on 
protecting concurrent updates ? 

What are the performance issues you are experiencing exactly ? 

Thanks, 

Mathieu 

> For RCU, I change the list_move_tail as following
> cds_list_for_each_entry_safe(cur, next, &(membk_pool->bk_free_pool), entry_pool)
> {
> cds_list_del_rcu(&cur->entry_pool);
> urcu_bp_synchronize_rcu();
> cds_list_add_tail_rcu(&ret->entry_pool, &(membk_pool->bk_using_pool));
> }

> Is it ok to use scenario like this?

> Meanwhile, that are some advance list operation API:
> 1. list_first_entry
> 2. list_first_entry_or_null
> Is it possible to integrate these into current urcu?

> Thanks

> _______________________________________________
> lttng-dev mailing list
> lttng-dev@lists.lttng.org
> https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

-- 
Mathieu Desnoyers 
EfficiOS Inc. 
http://www.efficios.com 

[-- Attachment #1.2: Type: text/html, Size: 3291 bytes --]

[-- Attachment #2: Type: text/plain, Size: 156 bytes --]

_______________________________________________
lttng-dev mailing list
lttng-dev@lists.lttng.org
https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

      reply	other threads:[~2020-08-07 16:36 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-07  7:24 [lttng-dev] Using rculist for dirty tracking Lego Lin via lttng-dev
2020-08-07 16:36 ` Mathieu Desnoyers via lttng-dev [this message]

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=1009482720.2512.1596818187667.JavaMail.zimbra@efficios.com \
    --to=lttng-dev@lists.lttng.org \
    --cc=lego.lin@gmail.com \
    --cc=mathieu.desnoyers@efficios.com \
    /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;
as well as URLs for NNTP newsgroup(s).