[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAHz2CGWJjU5U=pDuyzX=L+gev4cpNxkjCnVAvRpY=vO35tBDLg@mail.gmail.com>
Date: Tue, 29 Apr 2014 00:23:41 +0800
From: Jianyu Zhan <nasa4836@...il.com>
To: Peter Zijlstra <peterz@...radead.org>
Cc: Michal Hocko <mhocko@...e.cz>,
Andrew Morton <akpm@...ux-foundation.org>,
kirill.shutemov@...ux.intel.com, Rik van Riel <riel@...hat.com>,
Jiang Liu <liuj97@...il.com>,
Johannes Weiner <hannes@...xchg.org>,
Mel Gorman <mgorman@...e.de>,
Andrea Arcangeli <aarcange@...hat.com>, sasha.levin@...cle.com,
liwanp@...ux.vnet.ibm.com, khalid.aziz@...cle.com,
"linux-mm@...ck.org" <linux-mm@...ck.org>,
LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH RFC 2/2] mm: introdule compound_head_by_tail()
On Mon, Apr 28, 2014 at 11:55 PM, Peter Zijlstra <peterz@...radead.org> wrote:
> What version,
the code snipt in question is extracted from v3.15-rc3.
for the (1) check in previous email, its assembled code looks like:
--- (1) snipt ---
mov (%rdi),%rax (a)
test $0x80,%ah (b)
jne 754 <put_compound_page+0x74> (c)
--- (1) snipt ---
(a) %rdi is the struct page pointer
(b) check if PG_tail(0x80) set(likely not set, we tell the compiler)
(c) if set, jump; not set, fall through (good, credit to our hint)
===================================================
for the (3) check in previous email, its assembled code looks like:
--- (3) snipt ---
mov (%rdi),%rax (A)
mov %rdi,%r12
test $0x80,%ah (B)
jne 8f8 <put_compound_page+0x218> (C)
--- (3) snipt ---
(A) %rdi is the struct page pointer
(B) check if PG_tail(0x80) set(likely set in this case, but we
tell compiler unlikely)
(C) if set, jump; not set, fall through (god! it would better
not jump if set, but we
tell compiler unlikely, so it happily did as we told it)
# all code are compiled by gcc (GCC) 4.8.2
> and why didn't your changelog include this useful information?
Sorry, I would have done so. I will resend the patch.
Thanks,
Jianyu Zhan
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists