mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Baolin Wang <baolin.wang@linux.alibaba.com>
To: Steven Rostedt <rostedt@goodmis.org>
Cc: akpm@linux-foundation.org, mingo@redhat.com, ziy@nvidia.com,
	shy828301@gmail.com, linux-mm@kvack.org,
	linux-kernel@vger.kernel.org
Subject: Re: [RFC PATCH 3/3] mm: compaction: Fix the migration stats in trace_mm_compaction_migratepages()
Date: Thu, 4 Nov 2021 17:18:52 +0800	[thread overview]
Message-ID: <b1ec38a9-7513-bd18-9243-60f92eaf0d07@linux.alibaba.com> (raw)
In-Reply-To: <20211103094232.32a14cf0@gandalf.local.home>



On 2021/11/3 21:42, Steven Rostedt wrote:
> On Wed,  3 Nov 2021 18:51:16 +0800
> Baolin Wang <baolin.wang@linux.alibaba.com> wrote:
> 
>> @@ -2398,10 +2399,10 @@ bool compaction_zonelist_suitable(struct alloc_context *ac, int order,
>>   
>>   		err = migrate_pages(&cc->migratepages, compaction_alloc,
>>   				compaction_free, (unsigned long)cc, cc->mode,
>> -				MR_COMPACTION, NULL);
>> +				MR_COMPACTION, &nr_succeeded);
>>   
>> -		trace_mm_compaction_migratepages(cc->nr_migratepages, err,
>> -							&cc->migratepages);
>> +		trace_mm_compaction_migratepages(cc->nr_migratepages,
>> +						 nr_succeeded);
> 
> Also, I'm surprised you don't just pass in 'cc' and do the dereferencing in
> the trace event macro. Accessing the pointers from the trace event and not
> dereferencing them to the tracepoint function moves the changes out of line
> here and helps with I$.
> 
> You could improve some of the other tracepoints that dereference 'cc' as
> well in that file.

Sure. Will do in a separate patch.

> 
> But as for this change, I'm good with it.
> 
> For the tracing aspect:
> 
> Reviewed-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
> 

Thanks.

      reply	other threads:[~2021-11-04  9:18 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-03 10:51 [RFC PATCH 0/3] Improve the migration stats Baolin Wang
2021-11-03 10:51 ` [RFC PATCH 1/3] mm: migrate: Fix the return value of migrate_pages() Baolin Wang
2021-11-04 15:33   ` Zi Yan
2021-11-05 10:17     ` Baolin Wang
2021-11-05 15:21       ` Zi Yan
2021-11-07  9:08         ` Baolin Wang
2021-11-03 10:51 ` [RFC PATCH 2/3] mm: migrate: Correct the hugetlb migration stats Baolin Wang
2021-11-04 15:35   ` Zi Yan
2021-11-03 10:51 ` [RFC PATCH 3/3] mm: compaction: Fix the migration stats in trace_mm_compaction_migratepages() Baolin Wang
2021-11-03 13:42   ` Steven Rostedt
2021-11-04  9:18     ` Baolin Wang [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=b1ec38a9-7513-bd18-9243-60f92eaf0d07@linux.alibaba.com \
    --to=baolin.wang@linux.alibaba.com \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=mingo@redhat.com \
    --cc=rostedt@goodmis.org \
    --cc=shy828301@gmail.com \
    --cc=ziy@nvidia.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

all inboxes | Powered by JetHome®