When WTF::releaseFastMallocFreeMemory() is invoked, the variables free_committed_pages_ and min_free_committed_pages_since_last_scavenge_ are not updated for the released pages.
Created attachment 97867 [details] Patch to update scavenger counts in ReleaseFreeList
Attachment 97867 [details] did not pass style-queue: Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Source/JavaScriptCore/ChangeLog', u'Source..." exit_code: 1 Source/JavaScriptCore/ChangeLog:1: ChangeLog entry has no bug number [changelog/bugnumber] [5] Source/JavaScriptCore/wtf/FastMalloc.cpp:1360: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:1360: min_pages is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:1360: max_pages is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:1364: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2122: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2127: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2128: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2142: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2148: Place brace on its own line for function definitions. [whitespace/braces] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2148: TCMalloc_PageHeap::CheckList is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2152: Place brace on its own line for function definitions. [whitespace/braces] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2152: TCMalloc_PageHeap::CheckList is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2152: min_pages is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2152: max_pages is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2153: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2163: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2167: Place brace on its own line for function definitions. [whitespace/braces] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2167: TCMalloc_PageHeap::ReleaseFreeList is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2171: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Total errors found: 20 in 2 files If any of these errors are false positives, please file a bug against check-webkit-style.
Comment on attachment 97867 [details] Patch to update scavenger counts in ReleaseFreeList Attachment 97867 [details] did not pass qt-ews (qt): Output: http://queues.webkit.org/results/8910658
Created attachment 97871 [details] Updated patch - fixes qt failure
Attachment 97871 [details] did not pass style-queue: Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Source/JavaScriptCore/ChangeLog', u'Source..." exit_code: 1 Source/JavaScriptCore/ChangeLog:1: ChangeLog entry has no bug number [changelog/bugnumber] [5] Source/JavaScriptCore/wtf/FastMalloc.cpp:1360: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:1360: min_pages is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:1360: max_pages is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:1364: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2122: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2127: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2141: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2147: Place brace on its own line for function definitions. [whitespace/braces] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2147: TCMalloc_PageHeap::CheckList is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2151: Place brace on its own line for function definitions. [whitespace/braces] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2151: TCMalloc_PageHeap::CheckList is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2151: min_pages is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2151: max_pages is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2152: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2162: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2166: Place brace on its own line for function definitions. [whitespace/braces] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2166: TCMalloc_PageHeap::ReleaseFreeList is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2170: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Total errors found: 19 in 2 files If any of these errors are false positives, please file a bug against check-webkit-style.
Comment on attachment 97871 [details] Updated patch - fixes qt failure View in context: https://bugs.webkit.org/attachment.cgi?id=97871&action=review >> Source/JavaScriptCore/ChangeLog:1 >> +2011-06-20 Michael Saboff <msaboff@apple.com> > > ChangeLog entry has no bug number [changelog/bugnumber] [5] Stylebot is right about this! >>>> Source/JavaScriptCore/wtf/FastMalloc.cpp:1360 >>>> + size_t CheckList(Span* list, Length min_pages, Length max_pages, bool decommitted); >>> >>> Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] >> >> min_pages is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] > > max_pages is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] We need to tell the Stylebot that this file is imported code with an unusual style.
Created attachment 97890 [details] Updated Patch with bug reference in ChangeLog
Attachment 97890 [details] did not pass style-queue: Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Source/JavaScriptCore/ChangeLog', u'Source..." exit_code: 1 Source/JavaScriptCore/wtf/FastMalloc.cpp:1360: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:1360: min_pages is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:1360: max_pages is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:1364: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2122: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2127: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2141: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2147: Place brace on its own line for function definitions. [whitespace/braces] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2147: TCMalloc_PageHeap::CheckList is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2151: Place brace on its own line for function definitions. [whitespace/braces] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2151: TCMalloc_PageHeap::CheckList is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2151: min_pages is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2151: max_pages is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2152: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2162: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2166: Place brace on its own line for function definitions. [whitespace/braces] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2166: TCMalloc_PageHeap::ReleaseFreeList is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2170: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Total errors found: 18 in 2 files If any of these errors are false positives, please file a bug against check-webkit-style.
Comment on attachment 97890 [details] Updated Patch with bug reference in ChangeLog View in context: https://bugs.webkit.org/attachment.cgi?id=97890&action=review This ChangeLog would benefit from an explanation of *why* ReleaseFreeList needs to update these variables, and not just the *what* of updating them. What was the symptom when the variables weren't updated? > Source/JavaScriptCore/wtf/FastMalloc.cpp:2149 > return true; > } Can this be right (returning true for size_t)?
Created attachment 97932 [details] Patch with updates from comment #9
Attachment 97932 [details] did not pass style-queue: Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Source/JavaScriptCore/ChangeLog', u'Source..." exit_code: 1 Source/JavaScriptCore/wtf/FastMalloc.cpp:1360: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:1360: min_pages is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:1360: max_pages is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:1364: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2122: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2127: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2141: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2147: Place brace on its own line for function definitions. [whitespace/braces] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2147: TCMalloc_PageHeap::CheckList is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2148: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2151: Place brace on its own line for function definitions. [whitespace/braces] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2151: TCMalloc_PageHeap::CheckList is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2151: min_pages is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2151: max_pages is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2152: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2162: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/JavaScriptCore/wtf/FastMalloc.cpp:2166: Place brace on its own line for function definitions. [whitespace/braces] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2166: TCMalloc_PageHeap::ReleaseFreeList is incorrectly named. Don't use underscores in your identifier names. [readability/naming] [4] Source/JavaScriptCore/wtf/FastMalloc.cpp:2170: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Total errors found: 19 in 2 files If any of these errors are false positives, please file a bug against check-webkit-style.
> What was the symptom when the variables weren't updated? The symptom is that sometimes the scavenger wakes up every 2 seconds and scans the heap, even though there's no work to do. ^ I think you should put this statement in the ChangeLog.
Comment on attachment 97932 [details] Patch with updates from comment #9 r=me
Committed r89716: <http://trac.webkit.org/changeset/89716>