lkml.org 
[lkml]   [2003]   [Mar]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] Faster SWSUSP free page counting
Hi.

The speed difference depends of course upon the number of pages free and
the degree of fragmentation. I guess the easy answer is that it was
written and kept because it helped. Having talked to Andrew about the
use of page flags, I'll do some more changes before we put it to Linus -
I'll use a dynamically allocated bitmap instead of pageflags.

Regards,

Nigel

On Tue, 2003-03-18 at 20:20, Pavel Machek wrote:
> Hi!
>
> > This patch improves the speed of SWSUSP's count_and_copy_data_pages
> > function by generating a map of the free pages before iterating through
> > the list of pages. The net result is to go from O(n^2) to O(n), if I
> > remember my computer science correctly.
>
> Is the speed difference noticable?
>
> If yes than okay, but generate_free_page_map() should still be moved
> into kernel/suspend.c.
> Pavel
--
Nigel Cunningham
495 St Georges Road South, Hastings 4201, New Zealand

Be diligent to present yourself approved to God as a workman who does
not need to be ashamed, handling accurately the word of truth.
-- 2 Timothy 2:14, NASB.

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

\
 
 \ /
  Last update: 2005-03-22 13:34    [W:0.029 / U:0.920 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site