-
Notifications
You must be signed in to change notification settings - Fork 5.9k
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
*: support compiling tidb to wasm #13069
Conversation
Signed-off-by: lucklove <gnu.crazier@gmail.com>
c29ee56
to
85d64a8
Compare
This PR works now, but need a little work to do until I remove "WIP".
|
util/mathutil/mathutil_js.go
Outdated
const MaxInt = int(MaxUint >> 1) | ||
const MinInt = -MaxInt - 1 | ||
|
||
func MaxUint64(x, y uint64) uint64 { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please add comments for the export functions and vars
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, thanks for reminding
Signed-off-by: lucklove <gnu.crazier@gmail.com>
Codecov Report
@@ Coverage Diff @@
## master #13069 +/- ##
================================================
+ Coverage 80.1771% 80.1779% +0.0008%
================================================
Files 483 482 -1
Lines 121516 120911 -605
================================================
- Hits 97428 96944 -484
+ Misses 16330 16234 -96
+ Partials 7758 7733 -25 |
Signed-off-by: lucklove <gnu.crazier@gmail.com>
I just inspected https://play.tidb.io and was a bit weird seeing a 13Mb css file Any reason on naming it |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please declare the minimum browser support version for running TiDB wasm in PR description.
If needed, add some check logic when load the index.html
page, prompt some information about unsupported browser
.
@syrusakbary thanks for comment. |
Oh no! Thanks for the info :) |
@syrusakbary thanks for suggestion. I'll add a comment to makefile |
known issue: golang1.13 can't produce large wasm correctly |
Signed-off-by: lucklove <gnu.crazier@gmail.com>
Signed-off-by: lucklove <gnu.crazier@gmail.com>
Signed-off-by: lucklove <gnu.crazier@gmail.com>
Signed-off-by: lucklove <gnu.crazier@gmail.com>
Signed-off-by: 5kbpers <tangminghua@pingcap.com>
Signed-off-by: 5kbpers <tangminghua@pingcap.com>
Signed-off-by: 5kbpers <tangminghua@pingcap.com>
Signed-off-by: 5kbpers <tangminghua@pingcap.com>
This PR is ready to merge, PTAL, thx! @zz-jason @siddontang @ngaut |
@@ -78,3 +80,5 @@ require ( | |||
go 1.13 | |||
|
|||
replace github.com/pingcap/check => github.com/tiancaiamao/check v0.0.0-20191119042138-8e73d07b629d | |||
|
|||
replace github.com/coreos/go-systemd => github.com/5kbpers/go-systemd v0.0.0-20191209150347-994f05092cc6 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note: here we forked go-systemd
for building WASM.
Signed-off-by: lucklove <gnu.crazier@gmail.com>
9c50c3b
to
ad57699
Compare
We have fixed TiDB's Wasm compatibility problem and moved this feature to a standalone repo, closing this PR. |
Signed-off-by: lucklove gnu.crazier@gmail.com
What problem does this PR solve?
This PR make it possible to compile tidb to wasm and use tidb in browser.
What is changed and how it works?
Check List
Tests
Code changes
Side effects
Related changes
Release note