[<prev] [next>] [day] [month] [year] [list]
Message-ID: <CAJd=RBA8JSAckF0=jAdqtVCym3O1CAr97OObiqqvERQuYCgVNA@mail.gmail.com>
Date: Fri, 4 May 2012 21:38:33 +0800
From: Hillf Danton <dhillf@...il.com>
To: Alex Shi <alex.shi@...el.com>
Cc: tglx@...utronix.de, mingo@...hat.com, hpa@...or.com,
rostedt@...dmis.org, fweisbec@...il.com, bp@...64.org,
npiggin@...il.com, jeremy@...p.org, riel@...hat.com, luto@....edu,
avi@...hat.com, len.brown@...el.com, dhowells@...hat.com,
fenghua.yu@...el.com, yinghai@...nel.org, borislav.petkov@....com,
ak@...ux.intel.com, cpw@....com, steiner@....com,
Andrew Morton <akpm@...ux-foundation.org>,
LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATH v2 3/5] x86/tlb: fall back to flush all when meet a THP
large page
On Fri, May 4, 2012 at 9:00 PM, Alex Shi <alex.shi@...el.com> wrote:
> On 05/04/2012 08:11 PM, Hillf Danton wrote:
>
>> Hi Alex,
>>
>> if (vmflag & VM_EXEC)
>> tlb_entries = tlb_lli_4k[ENTRIES];
>> @@ -22,11 +23,15 @@ void flush_tlb_range(struct vm_area_stru
>> act_entries = tlb_entries > mm->total_vm ?
>> mm->total_vm : tlb_entries;
>>
>> - if ((end - start)/PAGE_SIZE > act_entries/FLUSHALL_BAR)
>> + pg_sz = (transparent_hugepage_enabled(vma) ||
>> + is_vm_hugetlb_page(vma)) ?
>> + HPAGE_SIZE : PAGE_SIZE;
>> +
>> + if ((end - start)/pg_sz > act_entries/FLUSHALL_BAR)
>
>
> Your patch should base on the second patch that expel the HUGETLB page.
>
The diff is only for showing idea.
> But the key fact is I did not find invlpg is help on HUGETLB.
Yep, I only assume flushing huge TLB is not far from regular TLB.
Powered by blists - more mailing lists