Bug 189201 - IDBRequest and IDBCursor should not hold strong references to JSValue
Summary: IDBRequest and IDBCursor should not hold strong references to JSValue
Status: RESOLVED CONFIGURATION CHANGED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore Misc. (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: youenn fablet
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-08-31 11:07 PDT by youenn fablet
Modified: 2019-04-05 17:36 PDT (History)
10 users (show)

See Also:


Attachments
Patch (23.36 KB, patch)
2018-08-31 11:18 PDT, youenn fablet
no flags Details | Formatted Diff | Diff
Patch (23.37 KB, patch)
2018-08-31 13:42 PDT, youenn fablet
no flags Details | Formatted Diff | Diff
Archive of layout-test-results from ews107 for mac-sierra-wk2 (2.98 MB, application/zip)
2018-08-31 17:08 PDT, EWS Watchlist
no flags Details
Archive of layout-test-results from ews124 for ios-simulator-wk2 (2.41 MB, application/zip)
2018-08-31 17:49 PDT, EWS Watchlist
no flags Details
Patch (26.07 KB, patch)
2018-08-31 22:51 PDT, youenn fablet
no flags Details | Formatted Diff | Diff
Patch (26.14 KB, patch)
2018-09-01 08:03 PDT, youenn fablet
no flags Details | Formatted Diff | Diff
Archive of layout-test-results from ews100 for mac-sierra (2.35 MB, application/zip)
2018-09-01 09:09 PDT, EWS Watchlist
no flags Details
Patch (28.37 KB, patch)
2018-09-04 10:52 PDT, youenn fablet
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description youenn fablet 2018-08-31 11:07:53 PDT
As can be seen from some IDB tests, this creates memory leaks.
Instead use JSValueInWrappedObject.
Comment 1 youenn fablet 2018-08-31 11:18:13 PDT
Created attachment 348654 [details]
Patch
Comment 2 youenn fablet 2018-08-31 13:42:35 PDT
Created attachment 348669 [details]
Patch
Comment 3 Alex Christensen 2018-08-31 13:44:02 PDT
Comment on attachment 348669 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=348669&action=review

> Source/WebCore/Modules/indexeddb/IDBCursor.h:104
>      // FIXME: The following uses of JSC::Strong are incorrect and can lead to storage leaks
>      // due to reference cycles; we should use JSValueInWrappedObject instead.

This comment should be removed.
Comment 4 EWS Watchlist 2018-08-31 17:08:06 PDT
Comment on attachment 348669 [details]
Patch

Attachment 348669 [details] did not pass mac-wk2-ews (mac-wk2):
Output: https://webkit-queues.webkit.org/results/9055070

New failing tests:
imported/w3c/web-platform-tests/IndexedDB/interleaved-cursors-small.html
imported/w3c/web-platform-tests/IndexedDB/interleaved-cursors-large.html
Comment 5 EWS Watchlist 2018-08-31 17:08:08 PDT
Created attachment 348684 [details]
Archive of layout-test-results from ews107 for mac-sierra-wk2

The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews.
Bot: ews107  Port: mac-sierra-wk2  Platform: Mac OS X 10.12.6
Comment 6 EWS Watchlist 2018-08-31 17:49:52 PDT
Comment on attachment 348669 [details]
Patch

Attachment 348669 [details] did not pass ios-sim-ews (ios-simulator-wk2):
Output: https://webkit-queues.webkit.org/results/9055166

New failing tests:
imported/w3c/web-platform-tests/IndexedDB/interleaved-cursors-small.html
imported/w3c/web-platform-tests/IndexedDB/interleaved-cursors-large.html
Comment 7 EWS Watchlist 2018-08-31 17:49:54 PDT
Created attachment 348692 [details]
Archive of layout-test-results from ews124 for ios-simulator-wk2

The attached test failures were seen while running run-webkit-tests on the ios-sim-ews.
Bot: ews124  Port: ios-simulator-wk2  Platform: Mac OS X 10.13.4
Comment 8 youenn fablet 2018-08-31 22:51:44 PDT
Created attachment 348707 [details]
Patch
Comment 9 youenn fablet 2018-09-01 08:03:05 PDT
Created attachment 348712 [details]
Patch
Comment 10 EWS Watchlist 2018-09-01 09:09:05 PDT
Comment on attachment 348712 [details]
Patch

Attachment 348712 [details] did not pass mac-ews (mac):
Output: https://webkit-queues.webkit.org/results/9062021

New failing tests:
imported/w3c/web-platform-tests/IndexedDB/interleaved-cursors-small.html
Comment 11 EWS Watchlist 2018-09-01 09:09:07 PDT
Created attachment 348714 [details]
Archive of layout-test-results from ews100 for mac-sierra

The attached test failures were seen while running run-webkit-tests on the mac-ews.
Bot: ews100  Port: mac-sierra  Platform: Mac OS X 10.12.6
Comment 12 youenn fablet 2018-09-04 10:52:42 PDT
Created attachment 348826 [details]
Patch