On Windows, 32-bit processes have 2GB of memory available, where some is used by the system. Debugging has shown that allocations might fail and cause crashes when memory usage is > ~1GB. We should start releasing memory before we reach 1GB.
Created attachment 295043 [details] Patch
<rdar://problem/27988989>
Comment on attachment 295043 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=295043&action=review r=me > Source/WebCore/platform/win/MemoryPressureHandlerWin.cpp:77 > + const int maxMemoryUsageBytes = 0.9 * 1024 * 1024 * 1024; So we trigger clean-up about 10% earlier than before? Seems reasonable. Would it make sense to convert this from a floating point calculation to just hard-coding the actual integer value that results from this math?
(In reply to comment #3) > Comment on attachment 295043 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=295043&action=review > > r=me > > > Source/WebCore/platform/win/MemoryPressureHandlerWin.cpp:77 > > + const int maxMemoryUsageBytes = 0.9 * 1024 * 1024 * 1024; > > So we trigger clean-up about 10% earlier than before? Seems reasonable. > > Would it make sense to convert this from a floating point calculation to > just hard-coding the actual integer value that results from this math? I checked the generated code, and the compiler will optimize this. Just let me know if you still want me to change it :) Thanks for reviewing!
Comment on attachment 295043 [details] Patch Clearing flags on attachment: 295043 Committed r208883: <http://trac.webkit.org/changeset/208883>
All reviewed patches have been landed. Closing bug.