Bug 238176 - [JSC] Use Data CallIC in unlinked DFG
Summary: [JSC] Use Data CallIC in unlinked DFG
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: 2022-03-21 17:51 PDT by Yusuke Suzuki
Modified: 2022-03-25 12:09 PDT (History)
7 users (show)

See Also:


Attachments
Patch (24.46 KB, patch)
2022-03-21 17:51 PDT, Yusuke Suzuki
no flags Details | Formatted Diff | Diff
Patch (24.46 KB, patch)
2022-03-23 15:07 PDT, Yusuke Suzuki
no flags Details | Formatted Diff | Diff
Patch (25.26 KB, patch)
2022-03-23 18:10 PDT, Yusuke Suzuki
ews-feeder: commit-queue-
Details | Formatted Diff | Diff
Patch (25.19 KB, patch)
2022-03-23 18:51 PDT, Yusuke Suzuki
no flags Details | Formatted Diff | Diff
Patch (27.76 KB, patch)
2022-03-24 03:33 PDT, Yusuke Suzuki
no flags Details | Formatted Diff | Diff
Patch (28.16 KB, patch)
2022-03-24 14:36 PDT, Yusuke Suzuki
no flags Details | Formatted Diff | Diff
Patch (28.93 KB, patch)
2022-03-24 17:12 PDT, Yusuke Suzuki
saam: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Yusuke Suzuki 2022-03-21 17:51:00 PDT
[JSC] Use Data CallIC in unlinked DFG
Comment 1 Yusuke Suzuki 2022-03-21 17:51:16 PDT
Created attachment 455309 [details]
Patch
Comment 2 Yusuke Suzuki 2022-03-23 15:07:30 PDT
Created attachment 455566 [details]
Patch
Comment 3 Yusuke Suzuki 2022-03-23 18:10:37 PDT
Created attachment 455590 [details]
Patch
Comment 4 Yusuke Suzuki 2022-03-23 18:51:02 PDT
Created attachment 455595 [details]
Patch
Comment 5 Yusuke Suzuki 2022-03-24 03:33:14 PDT
Created attachment 455630 [details]
Patch
Comment 6 Yusuke Suzuki 2022-03-24 14:36:31 PDT
Created attachment 455685 [details]
Patch
Comment 7 Yusuke Suzuki 2022-03-24 17:12:55 PDT
Created attachment 455709 [details]
Patch
Comment 8 Saam Barati 2022-03-24 18:51:51 PDT
Comment on attachment 455709 [details]
Patch

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

r=me with comments

> Source/JavaScriptCore/dfg/DFGSpeculativeJIT64.cpp:836
> +                GPRTemporary callLinkInfoTemp(this, JITCompiler::selectScratchGPR(calleeGPR, GPRInfo::regT0));

This looks wrong to me. I think we want this GPRTemporary to stay around longer than the scope of this if statement, otherwise we might reuse this register.

> Source/JavaScriptCore/dfg/DFGSpeculativeJIT64.cpp:889
> +            GPRTemporary callLinkInfoTemp(this, JITCompiler::selectScratchGPR(calleeGPR, GPRInfo::regT0));

This looks wrong to me. I think we want this GPRTemporary to stay around longer than the scope of this if statement, otherwise we might reuse this register.
Comment 9 Yusuke Suzuki 2022-03-24 23:13:34 PDT
Comment on attachment 455709 [details]
Patch

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

>> Source/JavaScriptCore/dfg/DFGSpeculativeJIT64.cpp:836
>> +                GPRTemporary callLinkInfoTemp(this, JITCompiler::selectScratchGPR(calleeGPR, GPRInfo::regT0));
> 
> This looks wrong to me. I think we want this GPRTemporary to stay around longer than the scope of this if statement, otherwise we might reuse this register.

Discussed with Saam. This is intentional one to allocate non-callee-save register from DFG register bank.

>> Source/JavaScriptCore/dfg/DFGSpeculativeJIT64.cpp:889
>> +            GPRTemporary callLinkInfoTemp(this, JITCompiler::selectScratchGPR(calleeGPR, GPRInfo::regT0));
> 
> This looks wrong to me. I think we want this GPRTemporary to stay around longer than the scope of this if statement, otherwise we might reuse this register.

Ditto.
Comment 10 Yusuke Suzuki 2022-03-25 12:09:00 PDT
Committed r291875 (248877@trunk): <https://commits.webkit.org/248877@trunk>
Comment 11 Radar WebKit Bug Importer 2022-03-25 12:09:16 PDT
<rdar://problem/90850205>