> From: Hillf Danton <[email protected]> > Subject: [RFC PATCH 1/3] mm, reclaim: make should_continue_reclaim perform > dryrun detection > > Address the issue of should_continue_reclaim continuing true too often > for __GFP_RETRY_MAYFAIL attempts when !nr_reclaimed and nr_scanned. > This could happen during hugetlb page allocation causing stalls for > minutes or hours. > > We can stop reclaiming pages if compaction reports it can make a progress. > A code reshuffle is needed to do that. And it has side-effects, however, > with allocation latencies in other cases but that would come at the cost > of potential premature reclaim which has consequences of itself. > > We can also bail out of reclaiming pages if we know that there are not > enough inactive lru pages left to satisfy the costly allocation. > > We can give up reclaiming pages too if we see dryrun occur, with the > certainty of plenty of inactive pages. IOW with dryrun detected, we are > sure we have reclaimed as many pages as we could. > > Cc: Mike Kravetz <[email protected]> > Cc: Mel Gorman <[email protected]> > Cc: Michal Hocko <[email protected]> > Cc: Vlastimil Babka <[email protected]> > Cc: Johannes Weiner <[email protected]> > Signed-off-by: Hillf Danton <[email protected]>
Acked-by: Mel Gorman <[email protected]> Thanks Hillf -- Mel Gorman SUSE Labs

