wasmer-java
wasmer-java copied to clipboard
Bump wasmer dependencies to 2.0.0
Since wasmer-runtime doesn't exist anymore in 2.0, I wonder what this should look like.
Or maybe it's time to rewrite wasmer-java to more closely follow the new API introduced with 1.0?
Hello, Yes we are planning to rewrite the extension to improve its API. But your PR is valid though :-), thnaks!
Hm. It's about 30% slower on instantiating modules in a tight loop because the global store is gone. Also, after about 16300 instantiations (suspicious number, I know..) it fails with
Exception in thread "main" java.lang.RuntimeException: Failed to instantiate the module: Insufficient resources: Failed to create memory: Error when allocating memory: System call failed: Cannot allocate memory (os error 12)
but that's the same with 1.0.2.
@jcaesar The number caught my eye: 16300 is the exact number that I read a few minutes ago in this repo: https://github.com/cretz/asmble#caveats (search for 16300). I wonder if it's related somehow? Unsure what the Java wrapper does under the hood but figured I'd toss this here.
I think that's coincidence. I never measured the exact number though, it might be 0x4000, e.g.
(Cleaning up my open PRs. 3.0 will be out soon, too.)