google / google/lyra

v1.3.2 is much slower than v1.3.1 if it's built into WebAssembly

Open
#112 6 comments 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
4k
Forks
368
PR merge metrics
No merged PRs in 30d

Description

[NOTE] This is just an FYI issue as I know this project doesn't officially support WebAssembly.

As I mentioned in https://github.com/google/lyra/issues/49, [shiguredo/lyra-wasm](https://github.com/shiguredo/lyra-wasm) maintains a no-patch WebAssembly build of Lyra.
Today, I updated the Lyra version to 1.3.2 (https://github.com/shiguredo/lyra-wasm/pull/10). However, it turned out that the encoding and decoding peformance is degraded after the update.

The following table is a benchmark result from https://shiguredo.github.io/lyra-wasm/lyra-benchmark.html.
(elapsed times taken to encode / decode 10 seconds audio data)

| Browser | Lyra Version | Encode Time | Decode Time |
|-------------------|-------------|--------------:|-------------:|
| Chrome (m1 mac) | 1.3.1 | 550.230 ms | 804.230 ms |
| Chrome (m1 mac) | 1.3.2 | 898.375 ms | 1144.754 ms |
| Safari (m1 mac) | 1.3.1 | 596.880 ms | 866.779 ms |
| Safari (m1 mac) | 1.3.2 | 905.639 ms | 1168.120 ms |
| Firefox (m1 mac) | 1.3.1 | 540.199 ms | 800.540 ms |
| Firefox (m1 mac) | 1.3.2 | 609.940 ms | 1064.080 ms |
| Chrome (android) | 1.3.1 | 1002.769 ms | 1040.140 ms |
| Chrome (android) | 1.3.2 | 1398.920 ms | 1621.900 ms |

I don't know the reason of this performance drop.
Any information that helps alleviate this problem is more than welcomed.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.