[SCM] WebKit Debian packaging branch, webkit-1.2, updated. upstream/1.1.90-6072-g9a69373
hclam at chromium.org
hclam at chromium.org
Wed Apr 7 23:24:43 UTC 2010
The following commit has been merged in the webkit-1.2 branch:
commit 966e1bb72ff8259acdc6c50d11a20660ceefc562
Author: hclam at chromium.org <hclam at chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Fri Nov 6 06:19:28 2009 +0000
Revert 50562 because it broke Chromium. Not reviewed since this is a build fix and revert.
Patch by Alpha Lam <hclam at chromium.org> on 2009-11-05
* bindings/v8/V8GCController.cpp:
(WebCore::V8GCController::gcEpilogue):
* bindings/v8/V8GCController.h:
* bindings/v8/V8Proxy.cpp:
(WebCore::V8Proxy::evaluate):
(WebCore::V8Proxy::runScript):
(WebCore::V8Proxy::callFunction):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@50588 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 770fa83..4ae7989 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,15 @@
+2009-11-05 Alpha Lam <hclam at chromium.org>
+
+ Revert 50562 because it broke Chromium. Not reviewed since this is a build fix and revert.
+
+ * bindings/v8/V8GCController.cpp:
+ (WebCore::V8GCController::gcEpilogue):
+ * bindings/v8/V8GCController.h:
+ * bindings/v8/V8Proxy.cpp:
+ (WebCore::V8Proxy::evaluate):
+ (WebCore::V8Proxy::runScript):
+ (WebCore::V8Proxy::callFunction):
+
2009-11-05 Adam Barth <abarth at webkit.org>
Reviewed by Sam Weinig.
diff --git a/WebCore/bindings/v8/V8GCController.cpp b/WebCore/bindings/v8/V8GCController.cpp
index bd545bb..a1dc819 100644
--- a/WebCore/bindings/v8/V8GCController.cpp
+++ b/WebCore/bindings/v8/V8GCController.cpp
@@ -416,17 +416,6 @@ ACTIVE_DOM_OBJECT_TYPES(MAKE_CASE)
}
};
-int V8GCController::workingSetEstimateMB = 0;
-
-namespace {
-
-int getMemoryUsageInMB()
-{
- return ChromiumBridge::memoryUsageMB();
-}
-
-} // anonymous namespace
-
void V8GCController::gcEpilogue()
{
v8::HandleScope scope;
@@ -436,8 +425,6 @@ void V8GCController::gcEpilogue()
GCEpilogueVisitor epilogueVisitor;
visitActiveDOMObjectsInCurrentThread(&epilogueVisitor);
- workingSetEstimateMB = getMemoryUsageInMB();
-
#ifndef NDEBUG
// Check all survivals are weak.
DOMObjectVisitor domObjectVisitor;
@@ -451,16 +438,4 @@ void V8GCController::gcEpilogue()
#endif
}
-void V8GCController::checkMemoryUsage()
-{
- const int lowUsageMB = 256; // If memory usage is below this threshold, do not bother forcing GC.
- const int highUsageMB = 1024; // If memory usage is above this threshold, force GC more aggresively.
- const int highUsageDeltaMB = 128; // Delta of memory usage growth (vs. last workingSetEstimateMB) to force GC when memory usage is high.
-
- int memoryUsageMB = getMemoryUsageInMB();
- if ((memoryUsageMB > lowUsageMB && memoryUsageMB > 2 * workingSetEstimateMB) || (memoryUsageMB > highUsageMB && memoryUsageMB > workingSetEstimateMB + highUsageDeltaMB))
- v8::V8::LowMemoryNotification();
-}
-
-
} // namespace WebCore
diff --git a/WebCore/bindings/v8/V8GCController.h b/WebCore/bindings/v8/V8GCController.h
index 484be24..7441bf0 100644
--- a/WebCore/bindings/v8/V8GCController.h
+++ b/WebCore/bindings/v8/V8GCController.h
@@ -78,12 +78,6 @@ namespace WebCore {
static void gcPrologue();
static void gcEpilogue();
-
- static void checkMemoryUsage();
-
- private:
- // Estimate of current working set.
- static int workingSetEstimateMB;
};
}
diff --git a/WebCore/bindings/v8/V8Proxy.cpp b/WebCore/bindings/v8/V8Proxy.cpp
index 161d630..defdb27 100644
--- a/WebCore/bindings/v8/V8Proxy.cpp
+++ b/WebCore/bindings/v8/V8Proxy.cpp
@@ -374,8 +374,6 @@ v8::Local<v8::Value> V8Proxy::evaluate(const ScriptSourceCode& source, Node* nod
{
ASSERT(v8::Context::InContext());
- V8GCController::checkMemoryUsage();
-
#if ENABLE(INSPECTOR)
if (InspectorTimelineAgent* timelineAgent = m_frame->page() ? m_frame->page()->inspectorTimelineAgent() : 0)
timelineAgent->willEvaluateScript(source.url().isNull() ? String() : source.url().string(), source.startLine());
@@ -420,7 +418,6 @@ v8::Local<v8::Value> V8Proxy::runScript(v8::Handle<v8::Script> script, bool isIn
if (script.IsEmpty())
return notHandledByInterceptor();
- V8GCController::checkMemoryUsage();
// Compute the source string and prevent against infinite recursion.
if (m_recursion >= kMaxRecursionDepth) {
v8::Local<v8::String> code = v8ExternalString("throw RangeError('Recursion too deep')");
@@ -475,7 +472,6 @@ v8::Local<v8::Value> V8Proxy::runScript(v8::Handle<v8::Script> script, bool isIn
v8::Local<v8::Value> V8Proxy::callFunction(v8::Handle<v8::Function> function, v8::Handle<v8::Object> receiver, int argc, v8::Handle<v8::Value> args[])
{
- V8GCController::checkMemoryUsage();
v8::Local<v8::Value> result;
{
V8ConsoleMessage::Scope scope;
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list