Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1720398

Re: [Question]: try to fix contention between expire_timers and try_to_del_timer_sync

From Vikram Mulukutla <markivx@codeaurora.org>
Newsgroups linux.kernel
Subject Re: [Question]: try to fix contention between expire_timers and try_to_del_timer_sync
Date 2017-08-25 22:30 +0200
Message-ID <uitoS-ek-13@gated-at.bofh.it> (permalink)
References (5 earlier) <u8iO5-7Od-1@gated-at.bofh.it> <u9iM2-6Kb-9@gated-at.bofh.it> <uaxIZ-76G-1@gated-at.bofh.it> <ueP4C-4UD-11@gated-at.bofh.it> <uisM9-8cd-17@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw



On 2017-08-25 12:48, Vikram Mulukutla wrote:

> 
> If I understand the code correctly, the upper 32 bits of an ARM64 
> virtual
> address will overflow when 1 is added to it, and so we'll keep WFE'ing 
> on
> every subsequent cpu_relax invoked from the same PC, until we cross the
> hard-coded threshold, right?
> 

Oops, misread that. Second time we enter cpu_relax from the same PC, we
do a WFE. Then we stop doing the WFE until we hit the threshold using 
the
per-cpu counter. So with a higher threshold, we wait for more 
cpu_relax()
calls before starting the WFE again.

So a lower threshold implies we should hit WFE branch sooner. It seems
that since my test keeps the while loop going for a full 5 seconds, a 
lower
threshold will obviously result in more WFEs and lower the 
lock-acquired-count.

I guess we want a high threshold but not so high that the little CPU has
to wait a while before the big CPU counts up to the threshold, is that 
correct?

Thanks,
Vikram

-- 
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum,
a Linux Foundation Collaborative Project

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Re: [Question]: try to fix contention between expire_timers and  try_to_del_timer_sync Will Deacon <will.deacon@arm.com> - 2017-08-15 20:50 +0200
  Re: [Question]: try to fix contention between expire_timers and  try_to_del_timer_sync Vikram Mulukutla <markivx@codeaurora.org> - 2017-08-25 21:50 +0200
    Re: [Question]: try to fix contention between expire_timers and  try_to_del_timer_sync Vikram Mulukutla <markivx@codeaurora.org> - 2017-08-25 22:30 +0200
    Re: [Question]: try to fix contention between expire_timers and  try_to_del_timer_sync Vikram Mulukutla <markivx@codeaurora.org> - 2017-08-29 01:20 +0200
      Re: [Question]: try to fix contention between expire_timers and  try_to_del_timer_sync qiaozhou <qiaozhou@asrmicro.com> - 2017-09-06 13:30 +0200

csiph-web