Open
Conversation
(It doesn't due to the bug in node/worker detection though)
In my tests, compiling C code with -Oz and then compiling Js with -Oz leads to _very_ small files and good performance.
* wasm: Adding the load_sql_file.js that the tests depend upon The worker test would theoretically work if run by itself The test files now work correctly if run individually Add package.json scripts to test the various compiled builds
|
This is awesome work. Thank you so much |
Owner
Author
|
You bet @mikeptweet! Thanks for the kind words. |
|
Any idea what the hold up is for getting this in the main branch? |
4 tasks
Compile sql.js to wasm instead of "just" asm.js
fixed some errors
Note that after the merge, and before the commit, I rebuilt with the latest version of Emscripten (emscripten-1.38.31) * master: (26 commits) fixed some errors Update README.md fix repl example fix examples Fix simple example Rename exported_runtime_methods and exported_functions Add a GUI/index.html to redirect to examples/GUI/index.html Ignore /sqlite-src and /cache folders Upgrade to Sqlite 3.28.0 Build with 1.38.30 of Emscripten Add example in Makefile showing how we could compile a worker-only wrapper Remove Node uncaughtException handler Minor: test_blob.js formatting Improve README for 1.0 Add and modify existing examples Fix loading of worker module Add latest compiled assets WIP: Update the README to show async usage and describe versions of the library Fix bugs with the modularization Rename most folders for clarity ... # Conflicts: # Makefile # dist/sql-asm-debug.js # dist/sql-wasm-debug.js # dist/worker.sql-asm-debug.js # dist/worker.sql-wasm-debug.js # js/sql-memory-growth.js # js/sql-wasm-debug.wasm # js/sql-wasm.js # js/sql-wasm.wasm # js/sql.js # js/worker.sql-wasm.js # js/worker.sql.js
logankeenan
added a commit
to logankeenan/sql.js
that referenced
this pull request
Nov 19, 2021
|
As with the release of https://github.com/sqlite/sqlite-wasm with OPFS persistence. Can we do the same optimizations that you did in this branch on sqlite-wasm github repo? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This builds upon my work in the WASM Branch: https://github.com/kripken/sql.js/pull/255
I have disabled a number of SQLite features and have optimized for size, bringing the wasm build down to 631KB (60KB loader file + 571KB wasm file).
(These files, when compressed (zip), are ~21KB and ~269KB, meaning the across-the-wire cost would be approx 290KB.)