From: Steven Rostedt <rostedt@goodmis.org>
To: Wonhyuk Yang <vvghjk1234@gmail.com>
Cc: Mel Gorman <mgorman@suse.de>, Ingo Molnar <mingo@redhat.com>,
Andrew Morton <akpm@linux-foundation.org>,
Baik Song An <bsahn@etri.re.kr>, Hong Yeon Kim <kimhy@etri.re.kr>,
Taeung Song <taeung@reallinux.co.kr>,
linuxgeek@linuxgeek.io, linux-kernel@vger.kernel.org,
linux-mm@kvack.org
Subject: Re: [Patch v2] [PATCH] mm/page_alloc: Fix tracepoint mm_page_alloc_zone_locked()
Date: Tue, 24 May 2022 21:22:00 -0400 [thread overview]
Message-ID: <20220524212200.207f02a5@gandalf.local.home> (raw)
In-Reply-To: <20220512025307.57924-1-vvghjk1234@gmail.com>
Sorry for the late reply, but I finally have time to catchup on my inbox.
On Thu, 12 May 2022 11:53:07 +0900
Wonhyuk Yang <vvghjk1234@gmail.com> wrote:
> --- a/mm/page_alloc.c
> +++ b/mm/page_alloc.c
> @@ -2476,6 +2476,9 @@ struct page *__rmqueue_smallest(struct zone *zone, unsigned int order,
> del_page_from_free_list(page, zone, current_order);
> expand(zone, page, order, current_order, migratetype);
> set_pcppage_migratetype(page, migratetype);
> + trace_mm_page_alloc_zone_locked(page, order, migratetype,
> + pcp_allowed_order(order) &&
> + migratetype < MIGRATE_PCPTYPES);
It would make more sense to put this logic into the TP_fast_assign() if
possible. This code is added at the location of execution, and even though
it may not run while tracing is disabled, it does affect icache.
Could you pass in the order (you already have migratetype) and then in the
trace event have:
TP_fast_assign(
__entry->pfn = page ? page_to_pfn(page) : -1UL;
__entry->order = order;
__entry->migratetype = migratetype;
+ __entry->percpu_refill = pcp_allowed_order(order) &&
migratetype < MIGRATE_PCPTYPES);
),
??
-- Steve
> return page;
> }
>
prev parent reply other threads:[~2022-05-25 1:22 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-12 2:53 [Patch v2] [PATCH] mm/page_alloc: Fix tracepoint mm_page_alloc_zone_locked() Wonhyuk Yang
2022-05-12 12:30 ` Mel Gorman
2022-05-25 1:22 ` Steven Rostedt [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=20220524212200.207f02a5@gandalf.local.home \
--to=rostedt@goodmis.org \
--cc=akpm@linux-foundation.org \
--cc=bsahn@etri.re.kr \
--cc=kimhy@etri.re.kr \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=linuxgeek@linuxgeek.io \
--cc=mgorman@suse.de \
--cc=mingo@redhat.com \
--cc=taeung@reallinux.co.kr \
--cc=vvghjk1234@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 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).