Bug 223678 - [JSC] Rope string equal operation should first check length
Summary: [JSC] Rope string equal operation should first check length
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Yusuke Suzuki
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2021-03-24 00:52 PDT by Yusuke Suzuki
Modified: 2021-03-24 03:50 PDT (History)
8 users (show)

See Also:


Attachments
Patch (1.43 KB, patch)
2021-03-24 00:53 PDT, Yusuke Suzuki
mark.lam: review+
ews-feeder: commit-queue-
Details | Formatted Diff | Diff
Patch (2.67 KB, patch)
2021-03-24 01:35 PDT, Yusuke Suzuki
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Yusuke Suzuki 2021-03-24 00:52:39 PDT
[JSC] Rope string equal operation should first check length
Comment 1 Yusuke Suzuki 2021-03-24 00:53:20 PDT
Created attachment 424102 [details]
Patch
Comment 2 Mark Lam 2021-03-24 01:04:37 PDT
Comment on attachment 424102 [details]
Patch

r=me.  I’m surprised we aren’t already doing this.
Comment 3 Ryosuke Niwa 2021-03-24 01:09:43 PDT
Comment on attachment 424102 [details]
Patch

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

> Source/JavaScriptCore/ChangeLog:8
> +        This can avoid eagerly resolving rope strings if it is not necessary.

lol, this is hilarious!
Comment 4 Yusuke Suzuki 2021-03-24 01:19:07 PDT
stress/redefine-property-same-value-exception-check.js is failing, just because this relies on the fact that this function resolves rope string (and throwing OOM error). We should fix the test.
Comment 5 Yusuke Suzuki 2021-03-24 01:35:27 PDT
Created attachment 424105 [details]
Patch
Comment 6 Yusuke Suzuki 2021-03-24 02:54:40 PDT
Failed stress/redefine-property-same-value-exception-check.js test is fixed, and ensured in jsc-armv7-tests result.
Comment 7 Yusuke Suzuki 2021-03-24 02:56:22 PDT
Committed r274935 (235693@main): <https://commits.webkit.org/235693@main>
Comment 8 Radar WebKit Bug Importer 2021-03-24 02:57:13 PDT
<rdar://problem/75777656>