* [Cluster-devel] [GFS2 PATCH] GFS2: Don't add rgrp glocks to the lru
[not found] <512846443.16088997.1434133529467.JavaMail.zimbra@redhat.com>
@ 2015-06-12 18:29 ` Bob Peterson
2015-06-15 11:19 ` Steven Whitehouse
0 siblings, 1 reply; 2+ messages in thread
From: Bob Peterson @ 2015-06-12 18:29 UTC (permalink / raw)
To: cluster-devel.redhat.com
Hi,
The glocks used for resource groups often come and go hundreds of
thousands of times per second. Adding them to the lru list just
adds unnecessary contention for the lru_lock spin_lock, especially
considering we're almost certainly going to re-use the glock and
take it back off the lru microseconds later. We never want the
glock shrinker to cull them anyway. This patch bypasses adding
them to the lru.
Regards,
Bob Peterson
Red Hat File Systems
Signed-off-by: Bob Peterson <rpeterso@redhat.com>
---
diff --git a/fs/gfs2/glock.c b/fs/gfs2/glock.c
index 0fa8062..1db06a5 100644
--- a/fs/gfs2/glock.c
+++ b/fs/gfs2/glock.c
@@ -1076,7 +1076,8 @@ void gfs2_glock_dq(struct gfs2_holder *gh)
!test_bit(GLF_DEMOTE, &gl->gl_flags))
fast_path = 1;
}
- if (!test_bit(GLF_LFLUSH, &gl->gl_flags) && demote_ok(gl))
+ if (!test_bit(GLF_LFLUSH, &gl->gl_flags) && demote_ok(gl) &&
+ gl->gl_name.ln_type != LM_TYPE_RGRP)
gfs2_glock_add_to_lru(gl);
trace_gfs2_glock_queue(gh, 0);
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [Cluster-devel] [GFS2 PATCH] GFS2: Don't add rgrp glocks to the lru
2015-06-12 18:29 ` [Cluster-devel] [GFS2 PATCH] GFS2: Don't add rgrp glocks to the lru Bob Peterson
@ 2015-06-15 11:19 ` Steven Whitehouse
0 siblings, 0 replies; 2+ messages in thread
From: Steven Whitehouse @ 2015-06-15 11:19 UTC (permalink / raw)
To: cluster-devel.redhat.com
Hi,
On 12/06/15 19:29, Bob Peterson wrote:
> Hi,
>
> The glocks used for resource groups often come and go hundreds of
> thousands of times per second. Adding them to the lru list just
> adds unnecessary contention for the lru_lock spin_lock, especially
> considering we're almost certainly going to re-use the glock and
> take it back off the lru microseconds later. We never want the
> glock shrinker to cull them anyway. This patch bypasses adding
> them to the lru.
>
> Regards,
>
> Bob Peterson
> Red Hat File Systems
>
> Signed-off-by: Bob Peterson <rpeterso@redhat.com>
Acked-by: Steven Whitehouse <swhiteho@redhat.com>
Steve.
> ---
> diff --git a/fs/gfs2/glock.c b/fs/gfs2/glock.c
> index 0fa8062..1db06a5 100644
> --- a/fs/gfs2/glock.c
> +++ b/fs/gfs2/glock.c
> @@ -1076,7 +1076,8 @@ void gfs2_glock_dq(struct gfs2_holder *gh)
> !test_bit(GLF_DEMOTE, &gl->gl_flags))
> fast_path = 1;
> }
> - if (!test_bit(GLF_LFLUSH, &gl->gl_flags) && demote_ok(gl))
> + if (!test_bit(GLF_LFLUSH, &gl->gl_flags) && demote_ok(gl) &&
> + gl->gl_name.ln_type != LM_TYPE_RGRP)
> gfs2_glock_add_to_lru(gl);
>
> trace_gfs2_glock_queue(gh, 0);
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-06-15 11:19 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <512846443.16088997.1434133529467.JavaMail.zimbra@redhat.com>
2015-06-12 18:29 ` [Cluster-devel] [GFS2 PATCH] GFS2: Don't add rgrp glocks to the lru Bob Peterson
2015-06-15 11:19 ` Steven Whitehouse
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).