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

Dependent libraries are absent on windows #3

Closed
JaynLau opened this issue Jun 8, 2022 · 9 comments
Closed

Dependent libraries are absent on windows #3

JaynLau opened this issue Jun 8, 2022 · 9 comments

Comments

@JaynLau
Copy link
Collaborator

JaynLau commented Jun 8, 2022

The dependent libraries LIBGCC_S_SEH-1.DLL and LIBSTDC++-6.DLL of NativeExecutor-x64.dll on windows (same on 32 bits system) are absent by default.

image

@JaynLau
Copy link
Collaborator Author

JaynLau commented Jun 8, 2022

Which version of mingw-gcc are you using? I need compatible mingw-gcc DLLs to test the solution.

@Roberto-Gentili
Copy link
Member

Roberto-Gentili commented Jun 8, 2022

Which version of mingw-gcc are you using? I need compatible mingw-gcc DLLs to test the solution.

Mingw 8.1.0 is used for the release. But I am releasing the new version of the Burningwave JVM Driver where the problem should be fixed: click here to see the progress.
If you are using Burningwave Core in the meantime I release the new version linked to the new Burningwave JVM Driver version you have to add this to your project:

<dependency>
    <groupId>org.burningwave</groupId>
    <artifactId>jvm-driver</artifactId>
    <version>8.1.0</version>
</dependency>

Let me know if it solves.

@JaynLau
Copy link
Collaborator Author

JaynLau commented Jun 8, 2022

The new DLL file was loaded successfully.

public class NativeExecutorLibLoadTest {
    public static void main(String[] args) {
        System.load("D:\\test\\NativeExecutor-x64.dll");
    }
}

Nice job!

@Roberto-Gentili
Copy link
Member

Thank you very much for your contribution. Burningwave JVM Driver's NativeExecutor is also capable of running on aarch64

@JaynLau
Copy link
Collaborator Author

JaynLau commented Jun 8, 2022

I did a new performance test for property access on jdk18 , the Burningwave JVM Driver's NativeExecutor is 8~12x faster than Narcissus. Both of them are based on JNI, is there any potential for performance improvement?

Benchmark                           Mode  Cnt        Score        Error   Units
get01_java_getName                 thrpt    5  2128351.065 ±  74044.483  ops/ms
get02_java_unsafe                  thrpt    5  2846238.581 ± 132301.972  ops/ms
get03_java_reflect_field           thrpt    5   182753.044 ±  28968.836  ops/ms
get04_java_reflect_getMethod       thrpt    5   137141.267 ±  16768.646  ops/ms
get05_java_invoke_varHandle        thrpt    5   168817.474 ±  10359.285  ops/ms
get06_java_invoke_getHandle        thrpt    5   202012.161 ±  50515.654  ops/ms
get07_java_invoke_getMethodHandle  thrpt    5   201015.559 ±  51183.238  ops/ms
get08_fieldAccess_name             thrpt    5   252810.286 ±  32768.620  ops/ms
get09_fieldAccess_index            thrpt    5  1425272.069 ±  18093.328  ops/ms
get10_methodAccess_name            thrpt    5   539337.043 ±  33062.343  ops/ms
get11_methodAccess_index           thrpt    5  1427615.352 ±   8237.573  ops/ms
get12_lambda_direct                thrpt    5  1412883.918 ±  33164.843  ops/ms
get13_lambda_fields_map            thrpt    5    77283.963 ±   1821.877  ops/ms
get14_reflects_get                 thrpt    5   162476.454 ±  20608.103  ops/ms
get15_jvm_driver_default           thrpt    5    41581.069 ±   1461.163  ops/ms
get16_jvm_driver_native            thrpt    5    16982.117 ±    369.449  ops/ms
get17_narcissus                    thrpt    5     2258.050 ±    121.033  ops/ms
get18_burningwave                  thrpt    5   180255.080 ±  16060.492  ops/ms
get19_burningwave_direct           thrpt    5    40617.747 ±    591.870  ops/ms
get20_burningwave_native_executor  thrpt    5    17394.136 ±    335.737  ops/ms
set01_java_setName                 thrpt    5  1007696.459 ±   8521.341  ops/ms
set02_java_unsafe                  thrpt    5   944449.969 ±  13842.098  ops/ms
set03_java_reflect_field           thrpt    5   151057.420 ±   4908.564  ops/ms
set04_java_reflect_setMethod       thrpt    5   125062.344 ±   2237.722  ops/ms
set05_java_invoke_varHandle        thrpt    5   168639.088 ±   1514.980  ops/ms
set06_java_invoke_setHandle        thrpt    5   199371.416 ±  32195.275  ops/ms
set07_java_invoke_setMethodHandle  thrpt    5   199195.644 ±  34596.830  ops/ms
set08_fieldAccess_name             thrpt    5   217216.306 ±   4400.018  ops/ms
set09_fieldAccess_index            thrpt    5   839790.554 ±  20571.623  ops/ms
set10_methodAccess_name            thrpt    5   118759.113 ±   7924.908  ops/ms
set11_methodAccess_index           thrpt    5   845086.701 ±  20002.237  ops/ms
set12_lambda_direct                thrpt    5   849925.530 ±  12502.299  ops/ms
set13_lambda_fields_map            thrpt    5    73733.279 ±   3575.869  ops/ms
set14_reflects_set                 thrpt    5   135721.616 ±  10151.304  ops/ms
set15_jvm_driver_default           thrpt    5    37480.005 ±   3478.883  ops/ms
set16_jvm_driver_native            thrpt    5    19672.880 ±    321.688  ops/ms
set17_narcissus                    thrpt    5     1580.701 ±     35.507  ops/ms
set18_burningwave                  thrpt    5   157602.092 ±   2529.233  ops/ms
set19_burningwave_direct           thrpt    5    39859.614 ±    999.843  ops/ms
set20_burningwave_native_executor  thrpt    5    19833.011 ±    396.308  ops/ms

@Roberto-Gentili
Copy link
Member

Roberto-Gentili commented Jun 8, 2022

Great job. The NativeExecutor is written in C++ while Naricissus in C: I don't know if it could depend on this or on some flag to pass to the compiler: could you open a discussion with these results on the Narcissus project to hear @lukehutch (the main developer) what he thinks?

@JaynLau
Copy link
Collaborator Author

JaynLau commented Jun 8, 2022

Discussion "Performance improvement" opened.

@Roberto-Gentili
Copy link
Member

Discussion "Performance improvement" opened.

Well done

@lukehutch
Copy link

To reiterate, Narcissus is already as fast as it will ever be. It is limited by the speed of JNI.

A future version may be able to use Panama, but I won't personally have the bandwidth to work on something like that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants