Sketch of an interface that bypasses the HostObject code#621
Closed
AnsisMalins wants to merge 2 commits intoClearFoundry:masterfrom
AnsisMalins:iv8hostobject
Closed
Sketch of an interface that bypasses the HostObject code#621AnsisMalins wants to merge 2 commits intoClearFoundry:masterfrom AnsisMalins:iv8hostobject
AnsisMalins wants to merge 2 commits intoClearFoundry:masterfrom
AnsisMalins:iv8hostobject
Conversation
Contributor
Author
|
If you prefer, instead of modifying the types in V8SplitProxyHelpers.cs, I could create lookalikes like Unsafe.StdString, etc. for the public API. |
Collaborator
|
Hi @AnsisMalins, Thanks for posting your PR. As we discussed elsewhere, a number of enhancements intended to reduce managed heap pressure are in the works for ClearScript 7.5. Based on a quick look, your proposal is very much like our upcoming Fast Proxy API, which similarly features a new host object interface that supports the passing of arguments in their unmanaged form, enabling zero-allocation host member access. Thanks again! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Here is my current proposed solution to getting rid of all GC allocations when calling methods on host objects from JavaScript. The client code would implement the IV8HostObject interface and deal with all the callbacks itself. Functionality would be added to all the Std and V8 types in V8SplitProxyHelpers.cs so that they could be manipulated without GC allocations.
Please tell me if you would merge anything like this.