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

Basic test benchmark for WebAssembly integration. #216

Merged
merged 4 commits into from
Dec 15, 2018

Conversation

twifkak
Copy link
Member

@twifkak twifkak commented Dec 13, 2018

This is not nearly as efficient as a native build of the transform
binary, due to bugs such as http://crbug.com/853685 and
golang/go#27462, but serves as a starting
point for further investigation.

There have been a few optimizations already:

  • Keeping one long-lived process open to amortize the bootstrapping
    cost across requests.
  • Batching the "requests" to the wasm code via Promise.all. (This can
    be seen by adding a log statement just before the call to exports.run
    in wasm_exec.js.)

Another potential problem to investigate the cost of is the lack of
cross-heap GC.

This is not nearly as efficient as a native build of the transform
binary, due to bugs such as http://crbug.com/853685 and
golang/go#27462, but serves as a starting
point for further investigation.

There have been a few optimizations already:
 - Keeping one long-lived process open to amortize the bootstrapping
   cost across requests.
 - Batching the "requests" to the wasm code via Promise.all. (This can
   be seen by adding a log statement just before the call to exports.run
   in wasm_exec.js.)

Another potential problem to investigate the cost of is the lack of
cross-heap GC.
@twifkak twifkak requested a review from alin04 December 13, 2018 03:38
@twifkak twifkak requested a review from torch2424 December 13, 2018 03:38
@twifkak
Copy link
Member Author

twifkak commented Dec 13, 2018

internal bug http://b/119071852

This excludes it from the Travis build, which is on go1.10 (since that is
our current supported version).
Copy link

@torch2424 torch2424 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 😄 But I think the approval should come from @alin04

@twifkak twifkak merged commit 3102960 into ampproject:master Dec 15, 2018
@twifkak twifkak deleted the wasm branch December 15, 2018 02:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants