Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[JSC] Inline op_to_this for global object case #15134

Conversation

Constellation
Copy link
Member

@Constellation Constellation commented Jun 21, 2023

5b9fce6

[JSC] Inline op_to_this for global object case
https://bugs.webkit.org/show_bug.cgi?id=258343
rdar://problem/111089057

Reviewed by Alexey Shvayka.

This patch inlines non-object-allocating simple ToThis operation in DFG and FTL.
And we drop OverridesToThis bit, which is no longer necessary.

* Source/JavaScriptCore/dfg/DFGAbstractInterpreterInlines.h:
(JSC::DFG::isToThisAnIdentity):
* Source/JavaScriptCore/dfg/DFGSpeculativeJIT.cpp:
* Source/JavaScriptCore/ftl/FTLLowerDFGToB3.cpp:
(JSC::FTL::DFG::LowerDFGToB3::compileToThis):
* Source/JavaScriptCore/runtime/JSBigInt.h:
* Source/JavaScriptCore/runtime/JSCast.h:
* Source/JavaScriptCore/runtime/JSScope.h:
* Source/JavaScriptCore/runtime/JSString.h:
* Source/JavaScriptCore/runtime/JSType.h:
* Source/JavaScriptCore/runtime/JSTypeInfo.h:
(JSC::TypeInfo::perCellBit):
(JSC::TypeInfo::overridesToThis const): Deleted.
* Source/JavaScriptCore/runtime/Symbol.h:

Canonical link: https://commits.webkit.org/265373@main

69e507a

Misc iOS, tvOS & watchOS macOS Linux Windows
βœ… πŸ§ͺ style βœ… πŸ›  ios βœ… πŸ›  mac βœ… πŸ›  wpe βœ… πŸ›  wincairo
βœ… πŸ›  ios-sim βœ… πŸ›  mac-AS-debug βœ… πŸ§ͺ wpe-wk2
βœ… πŸ§ͺ webkitperl βœ… πŸ§ͺ ios-wk2 βœ… πŸ§ͺ api-mac βœ… πŸ›  gtk
βœ… πŸ§ͺ ios-wk2-wpt βœ… πŸ§ͺ mac-wk1 βœ… πŸ§ͺ gtk-wk2
βœ… πŸ›  πŸ§ͺ jsc βœ… πŸ§ͺ api-ios βœ… πŸ§ͺ mac-wk2 βœ… πŸ§ͺ api-gtk
βœ… πŸ›  πŸ§ͺ jsc-arm64 βœ… πŸ›  tv   πŸ§ͺ mac-AS-debug-wk2 βœ… πŸ›  jsc-armv7
βœ… πŸ›  tv-sim βœ… πŸ§ͺ jsc-armv7-tests
βœ… πŸ›  watch βœ… πŸ›  jsc-mips
βœ… πŸ›  πŸ§ͺ unsafe-merge βœ… πŸ›  watch-sim βœ… πŸ§ͺ jsc-mips-tests

@Constellation Constellation requested a review from a team as a code owner June 21, 2023 09:00
@Constellation Constellation self-assigned this Jun 21, 2023
@Constellation Constellation added the JavaScriptCore For bugs in JavaScriptCore, the JS engine used by WebKit, other than kxmlcore issues. label Jun 21, 2023
@hyjorc1
Copy link
Contributor

hyjorc1 commented Jun 21, 2023

LGTM

@Constellation Constellation added the unsafe-merge-queue Applied to send a pull request to merge-queue, but skip building and testing label Jun 21, 2023
https://bugs.webkit.org/show_bug.cgi?id=258343
rdar://problem/111089057

Reviewed by Alexey Shvayka.

This patch inlines non-object-allocating simple ToThis operation in DFG and FTL.
And we drop OverridesToThis bit, which is no longer necessary.

* Source/JavaScriptCore/dfg/DFGAbstractInterpreterInlines.h:
(JSC::DFG::isToThisAnIdentity):
* Source/JavaScriptCore/dfg/DFGSpeculativeJIT.cpp:
* Source/JavaScriptCore/ftl/FTLLowerDFGToB3.cpp:
(JSC::FTL::DFG::LowerDFGToB3::compileToThis):
* Source/JavaScriptCore/runtime/JSBigInt.h:
* Source/JavaScriptCore/runtime/JSCast.h:
* Source/JavaScriptCore/runtime/JSScope.h:
* Source/JavaScriptCore/runtime/JSString.h:
* Source/JavaScriptCore/runtime/JSType.h:
* Source/JavaScriptCore/runtime/JSTypeInfo.h:
(JSC::TypeInfo::perCellBit):
(JSC::TypeInfo::overridesToThis const): Deleted.
* Source/JavaScriptCore/runtime/Symbol.h:

Canonical link: https://commits.webkit.org/265373@main
@webkit-commit-queue webkit-commit-queue force-pushed the eng/JSC-Inline-op_to_this-for-global-object-case branch from 69e507a to 5b9fce6 Compare June 21, 2023 20:55
@webkit-commit-queue
Copy link
Collaborator

Committed 265373@main (5b9fce6): https://commits.webkit.org/265373@main

Reviewed commits have been landed. Closing PR #15134 and removing active labels.

@webkit-commit-queue webkit-commit-queue merged commit 5b9fce6 into WebKit:main Jun 21, 2023
@webkit-commit-queue webkit-commit-queue removed the unsafe-merge-queue Applied to send a pull request to merge-queue, but skip building and testing label Jun 21, 2023
@Constellation Constellation deleted the eng/JSC-Inline-op_to_this-for-global-object-case branch June 21, 2023 21:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
JavaScriptCore For bugs in JavaScriptCore, the JS engine used by WebKit, other than kxmlcore issues.
Projects
None yet
5 participants