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

[VL] Tight Java-C++ object binding #3142

Closed
zhztheplayer opened this issue Sep 14, 2023 · 2 comments
Closed

[VL] Tight Java-C++ object binding #3142

zhztheplayer opened this issue Sep 14, 2023 · 2 comments
Labels
enhancement New feature or request stale stale

Comments

@zhztheplayer
Copy link
Member

zhztheplayer commented Sep 14, 2023

Description

PRs for #3077 will untangle codes to create a local execution context and decouple query execution from JniWrapper.

A remaining issue is that we still bind a lot of C++ objects to Java by explicit pointer transmission over JNI. We'd simplify the routine by using a JVM-native way like finalize() or weak references.

The prons if we do this:

  1. Simplify JNI codes
  2. (probably) The objects can be collected on-demand rather than when task ends

Since #3077 is mostly about centralizing the object management, this would be a separate topic aside but more or less related to #3077.

@zhztheplayer zhztheplayer added the enhancement New feature or request label Sep 14, 2023
@zhztheplayer
Copy link
Member Author

@Yohahaha I'll take this following your PRs.

@zhztheplayer
Copy link
Member Author

Let's use 39a5162 's approach until it's needed to be improved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request stale stale
Projects
None yet
Development

No branches or pull requests

1 participant