DPDK patches and discussions
 help / color / mirror / Atom feed
From: Thomas Monjalon <thomas.monjalon@6wind.com>
To: Pashupati Kumar <kumarp@brocade.com>
Cc: "dev@dpdk.org" <dev@dpdk.org>
Subject: Re: [dpdk-dev] Bit spinlocks in DPDK
Date: Fri, 06 Dec 2013 23:24:27 +0100	[thread overview]
Message-ID: <4656219.tgqzelRNOJ@x220> (raw)
In-Reply-To: <6895EAE0CA8DEE40B92D7CA88BB521F332BA572E7A@HQ1-EXCH02.corp.brocade.com>

06/12/2013 14:12, Pashupati Kumar :
> From: Thomas Monjalon
> > 06/12/2013 13:04, Pashupati Kumar :
> > > We use bit spinlocks extensively to have compact data structures.  Are
> > > there any plans for adding them to DPDK in some future release?
> > 
> > Not sure to understand your request.
> > Are you looking for that?
> > 	http://dpdk.org/doc/api/rte__spinlock_8h.html
>
> I am looking for spinlocks that use a single bit (bit 31) of a 32 bit word
> for locking. The rest of the bits in the word are left undisturbed.  This
> enables more compact data structures as only 1 bit is consumed for the
> lock.

Oh yes, like test_and_set_bit_lock() in Linux:
	http://lxr.free-electrons.com/source/arch/ia64/include/asm/bitops.h?v=3.12#L205

I think that a patch would be appreciated :)

PS: please try to answer below the question. It's far easier to read.
-- 
Thomas

  reply	other threads:[~2013-12-06 22:22 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-06 21:04 Pashupati Kumar
2013-12-06 22:02 ` Thomas Monjalon
2013-12-06 22:12   ` Pashupati Kumar
2013-12-06 22:24     ` Thomas Monjalon [this message]
2013-12-06 22:54       ` Pashupati Kumar
2013-12-07 17:54       ` François-Frédéric Ozog
2013-12-19 16:41         ` Thomas Monjalon
2013-12-20 15:39         ` Thomas Monjalon
2013-12-20 16:00           ` François-Frédéric Ozog
2013-12-20 16:36             ` Stephen Hemminger

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=4656219.tgqzelRNOJ@x220 \
    --to=thomas.monjalon@6wind.com \
    --cc=dev@dpdk.org \
    --cc=kumarp@brocade.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).