All of lore.kernel.org
 help / color / mirror / Atom feed
From: Rik van Riel <riel@redhat.com>
To: rajman mekaco <rajman.mekaco@gmail.com>
Cc: Ingo Molnar <mingo@redhat.com>,
	Peter Zijlstra <peterz@infradead.org>,
	Paul Gortmaker <paul.gortmaker@windriver.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>,
	Minchan Kim <minchan.kim@gmail.com>,
	Christoph Lameter <cl@gentwo.org>,
	linux-kernel@vger.kernel.org, linux-mm@kvack.org
Subject: Re: [PATCH 1/1] mlock: split the shmlock_user_lock spinlock into per user_struct spinlock
Date: Thu, 10 May 2012 18:30:38 -0400	[thread overview]
Message-ID: <4FAC418E.6060500@redhat.com> (raw)
In-Reply-To: <CAMYGaxqxb=XR8R26h4e2URA2hG2M3j9V4u0DLJ9ifmkZKJa+eg@mail.gmail.com>

On 05/10/2012 11:39 AM, rajman mekaco wrote:
> On Thu, May 10, 2012 at 8:24 PM, Rik van Riel<riel@redhat.com>  wrote:
>> On 05/10/2012 09:34 AM, rajman mekaco wrote:
>>
>>> Any updates on this ?
>>
>>
>> There is still no usecase to demonstrate a problem, so no real
>> justification to merge the patch.  Coming up with such a usecase
>> is up to the submitter of the patch.
>
> Maybe you didn't read my last email:
> If 2 different user-mode processes executing on 2 CPUs under 2 different
> users want to access the same shared memory through the
> shmctl(SHM_LOCK) / shmget(SHM_HUGETLB) / usr_shm_lock
> primitives, they could compete/spin even though their user_structs
> are different.
>
> Can you please correct me if I am missing some crucial point of understanding ?

Mlock is a very very expensive operation.

Updating the mlock statistics is a very cheap operation.

Does this spinlock ever show up contention wise?

-- 
All rights reversed

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

WARNING: multiple messages have this Message-ID (diff)
From: Rik van Riel <riel@redhat.com>
To: rajman mekaco <rajman.mekaco@gmail.com>
Cc: Ingo Molnar <mingo@redhat.com>,
	Peter Zijlstra <peterz@infradead.org>,
	Paul Gortmaker <paul.gortmaker@windriver.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>,
	Minchan Kim <minchan.kim@gmail.com>,
	Christoph Lameter <cl@gentwo.org>,
	linux-kernel@vger.kernel.org, linux-mm@kvack.org
Subject: Re: [PATCH 1/1] mlock: split the shmlock_user_lock spinlock into per user_struct spinlock
Date: Thu, 10 May 2012 18:30:38 -0400	[thread overview]
Message-ID: <4FAC418E.6060500@redhat.com> (raw)
In-Reply-To: <CAMYGaxqxb=XR8R26h4e2URA2hG2M3j9V4u0DLJ9ifmkZKJa+eg@mail.gmail.com>

On 05/10/2012 11:39 AM, rajman mekaco wrote:
> On Thu, May 10, 2012 at 8:24 PM, Rik van Riel<riel@redhat.com>  wrote:
>> On 05/10/2012 09:34 AM, rajman mekaco wrote:
>>
>>> Any updates on this ?
>>
>>
>> There is still no usecase to demonstrate a problem, so no real
>> justification to merge the patch.  Coming up with such a usecase
>> is up to the submitter of the patch.
>
> Maybe you didn't read my last email:
> If 2 different user-mode processes executing on 2 CPUs under 2 different
> users want to access the same shared memory through the
> shmctl(SHM_LOCK) / shmget(SHM_HUGETLB) / usr_shm_lock
> primitives, they could compete/spin even though their user_structs
> are different.
>
> Can you please correct me if I am missing some crucial point of understanding ?

Mlock is a very very expensive operation.

Updating the mlock statistics is a very cheap operation.

Does this spinlock ever show up contention wise?

-- 
All rights reversed

  parent reply	other threads:[~2012-05-10 22:30 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-05-03 17:34 [PATCH 1/1] mlock: split the shmlock_user_lock spinlock into per user_struct spinlock rajman mekaco
2012-05-03 17:34 ` rajman mekaco
2012-05-03 18:07 ` Rik van Riel
2012-05-03 18:07   ` Rik van Riel
2012-05-03 20:27   ` Rik van Riel
2012-05-03 20:27     ` Rik van Riel
2012-05-04  1:12     ` rajman mekaco
2012-05-04  1:12       ` rajman mekaco
2012-05-10 13:34       ` rajman mekaco
2012-05-10 13:34         ` rajman mekaco
2012-05-10 14:54         ` Rik van Riel
2012-05-10 14:54           ` Rik van Riel
2012-05-10 15:39           ` rajman mekaco
2012-05-10 15:39             ` rajman mekaco
2012-05-10 16:48             ` rajman mekaco
2012-05-10 16:48               ` rajman mekaco
2012-05-10 22:30             ` Rik van Riel [this message]
2012-05-10 22:30               ` Rik van Riel
2012-05-12  3:10               ` rajman mekaco
2012-05-12  3:10                 ` rajman mekaco
2012-05-03 19:31 ` Peter Zijlstra
2012-05-03 19:31   ` Peter Zijlstra
2012-05-03 20:26   ` Rik van Riel
2012-05-03 20:26     ` Rik van Riel

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=4FAC418E.6060500@redhat.com \
    --to=riel@redhat.com \
    --cc=akpm@linux-foundation.org \
    --cc=cl@gentwo.org \
    --cc=kosaki.motohiro@jp.fujitsu.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=minchan.kim@gmail.com \
    --cc=mingo@redhat.com \
    --cc=paul.gortmaker@windriver.com \
    --cc=peterz@infradead.org \
    --cc=rajman.mekaco@gmail.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.