RESOLVED FIXED 126805
[iOS] Fix GCController::releaseExecutableMemory
https://bugs.webkit.org/show_bug.cgi?id=126805
Summary [iOS] Fix GCController::releaseExecutableMemory
Joseph Pecoraro
Reported 2014-01-10 21:07:16 PST
GCController::releaseExecutableMemory uses JSDOMWindow::commonVM()->dynamicGlobalObject which no longer exists. It moved to VMEntryScope->globalObject. Can the same trick still be applied?
Attachments
[PATCH] Proposed Fix (2.02 KB, patch)
2014-01-10 21:10 PST, Joseph Pecoraro
sam: review+
Joseph Pecoraro
Comment 1 2014-01-10 21:10:01 PST
Created attachment 220919 [details] [PATCH] Proposed Fix JSC folks, does this look correct? Should I be null checking JSDOMWindow::commonVM()->entryScope now instead of JSDOMWindow::commonVM()->entryScope->globalObject()? This is one of the iOS in OpenSource build errors.
Sam Weinig
Comment 2 2014-01-10 21:43:55 PST
Comment on attachment 220919 [details] [PATCH] Proposed Fix View in context: https://bugs.webkit.org/attachment.cgi?id=220919&action=review > Source/WebCore/bindings/js/GCController.cpp:37 > > +#if PLATFORM(IOS) > +#include <runtime/VMEntryScope.h> > +#endif Seems like while you are here, you might as well make this function not iOS specific as it seems generally useful (and you can remove the #ifdefs)!
Mark Lam
Comment 3 2014-01-10 21:56:39 PST
Comment on attachment 220919 [details] [PATCH] Proposed Fix View in context: https://bugs.webkit.org/attachment.cgi?id=220919&action=review r=me with the needed fixes. > Source/WebCore/bindings/js/GCController.cpp:120 > + ASSERT(!JSDOMWindow::commonVM()->entryScope->globalObject()); This is not right. The entryScope will be NULL if we haven’t entered the VM to run any JS code. Hence, the assertion you want is: ASSERT(!JSDOMWindow::commonVM()->entryScope); > Source/WebCore/bindings/js/GCController.cpp:123 > + if (JSDOMWindow::commonVM()->entryScope->globalObject()) Similarly here, what you want is: if (JSDOMDOMWindow::commonVM()->entryScope)
Joseph Pecoraro
Comment 4 2014-01-10 22:53:47 PST
Landed in <http://trac.webkit.org/changeset/161747>. And follow fix to in <http://trac.webkit.org/changeset/161748> cause even though I thought I tested building Mac, my terminal tricked me into thinking it compiled!
Note You need to log in before you can comment on or make changes to this bug.