Re: [RFC] Making compound pages mandatory

From: David Howells
Date: Wed Nov 17 2004 - 07:04:51 EST



> > So I'd suggest that we make compound pages conditional on a new
> > CONFIG_COMPOUND_PAGE and make that equal to HUGETLB_PAGE || !MMU.
>
> That sounds sane, and seems easily done in init/Kconfig. David?

That looks reasonable, I think.

Would you object to some more micro-optimisations:

(1) Allow struct page to be marked __attribute__((align(sizeof(long)*2))) on
archs that want it. On frv for instance this would allow the use of
double-register load/store instructions when accessing certain adjacent
pairs of members (such as page->lru.next and page->lru.prev). I think the
frv compiler will emit these when it knows it won't cause a misalignment
exception (8-byte accesses must be 8-byte aligned).

(2) Allow put_page() to be provided by the arch if desired. This would allow
me to do a better job of testing page flags and mucking around with the
refcount by writing it in assembly. This is sort of prerequisite on (1)
and the fact that accesses to page->_count are atomic and so are inline
asm anyway.

> [ There's too damn many Davids around. DavidH? Mr Howells? Dude? ]

I generally refer to all other Davids as Dave, apart from David Woodhouse who
should be referred to as "Fish":-P

DavidH would be okay.

David
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/