emscripten-core / emscripten-core/emscripten

How to avoid repeated downloading of dynamic library under multithreading

Đang mở
#17,537 1 bình luận 0 reaction 0 người được giao Xem trên GitHub
Ngôn ngữ chính
C++
Star
27.6k
Fork
3.6k
Merge trung bình
1 ngày 14 giờ
Pull request đã merge (30 ngày)
125

Mô tả

Version of emscripten/emsdk: 3.1.15

If I use Multi-Thread and Side-Module, my project can run successful. But my dynamic libraries(about 30MB) will download some times,
one in main thread and others by my worker.js(PTHREAD_POOL_SIZE=30), this will waste lots of time and network bandwidth(about 1G).

① But in fact, I should only need to load it once,it will be fast and more reasonable, how can I share thoes dynamic libraries for other thread?
② What's more, the path of the dynamic library has changed。 When I set my dynamic libraries as below.
var Module = {
dynamicLibraries : [
"libs/XXX.so",
.....
],
}
it downloads libraries from //libs in main thread, however,it downloads libraries from ///libs/ in worker.js thread。 so I need copyt it to other path.

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Hướng nghiên cứu

Tái tạo thiết lập side-module đa luồng với dynamicLibraries, so sánh các request của luồng chính và worker.js cùng các đường dẫn đã được phân giải của chúng. Được xem là hoàn tất khi xác định được liệu các thư viện có được tải xuống một lần hay không và liệu cùng một đường dẫn thư viện có hoạt động từ cả hai ngữ cảnh thực thi hay không.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Công nghệ
javascript, wasm
Lĩnh vực
build-system, web-dev
Loại issue
Lỗi
Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Cần làm rõ
Mức phù hợp với người mới
25/100

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.