RESOLVED FIXED 69311
Add static ClassInfo structs to classes that override JSCell::getCallData
https://bugs.webkit.org/show_bug.cgi?id=69311
Summary Add static ClassInfo structs to classes that override JSCell::getCallData
Mark Hahnenberg
Reported 2011-10-03 18:03:26 PDT
In order for the dynamic lookup on the method table to work properly, every class that implements its own version of the function in question (in this case, getCallData) needs to provide its own static ClassInfo structure, otherwise the wrong method will be called (the next parent in the class hierarchy that defines its own ClassInfo). We therefore need to add new structures to those classes that override getCallData but don't yet have them.
Attachments
Patch (11.57 KB, patch)
2011-10-03 18:45 PDT, Mark Hahnenberg
no flags
Patch (13.17 KB, patch)
2011-10-04 15:11 PDT, Mark Hahnenberg
darin: review+
webkit.review.bot: commit-queue-
Mark Hahnenberg
Comment 1 2011-10-03 18:45:53 PDT
Darin Adler
Comment 2 2011-10-04 09:28:50 PDT
Comment on attachment 109567 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=109567&action=review > Source/JavaScriptCore/ChangeLog:9 > + Added ClassInfo structs to each class that defined its own getCallData > + function but did not already have its own ClassInfo struct. This is a Are these structs used yet, or is that a task for a separate patch? > Source/JavaScriptCore/runtime/Error.cpp:207 > + virtual CallType getCallDataVirtual(CallData& callData) > { > return getCallData(this, callData); > } Typically we don’t want virtual functions to also have inline function definitions. Not new in this patch and probably not a problem since we’ll be deleting this soon.
Mark Hahnenberg
Comment 3 2011-10-04 11:07:42 PDT
> Are these structs used yet, or is that a task for a separate patch? These structs are not yet used, but they are a preliminary step for bug 69186 to make it easier to review.
WebKit Review Bot
Comment 4 2011-10-04 12:21:07 PDT
Comment on attachment 109567 [details] Patch Clearing flags on attachment: 109567 Committed r96630: <http://trac.webkit.org/changeset/96630>
WebKit Review Bot
Comment 5 2011-10-04 12:21:11 PDT
All reviewed patches have been landed. Closing bug.
Mark Hahnenberg
Comment 6 2011-10-04 13:41:02 PDT
Reopening because the patch caused assertion failures in validateCell due to fact that not all of the new ClassInfo structs are being used in their associated Structures due to a lack of createStructure methods in these classes. Rolled out and will resubmit with fixes.
Mark Hahnenberg
Comment 7 2011-10-04 15:11:04 PDT
WebKit Review Bot
Comment 8 2011-10-04 19:18:55 PDT
Comment on attachment 109701 [details] Patch Rejecting attachment 109701 [details] from commit-queue. Failed to run "['/mnt/git/webkit-commit-queue/Tools/Scripts/webkit-patch', '--status-host=queues.webkit.org', '-..." exit_code: 2 Last 500 characters of output: d29926bb419ebfc3b2635e2e00063b7421874f88 r96672 = b07c6f5e8ee25b998824c8fae4991c8b2df68c6c Done rebuilding .git/svn/refs/remotes/origin/master/.rev_map.268f45cc-cd09-0410-ab3c-d52691b4dbfc First, rewinding head to replay your work on top of it... Fast-forwarded master to refs/remotes/origin/master. Updating chromium port dependencies using gclient... ________ running '/usr/bin/python gyp_webkit' in '/mnt/git/webkit-commit-queue/Source/WebKit/chromium' Updating webkit projects from gyp files... Full output: http://queues.webkit.org/results/9944597
Mark Hahnenberg
Comment 9 2011-10-04 19:46:46 PDT
Note You need to log in before you can comment on or make changes to this bug.