I think the speed could be improved a lot but it will take time.
What are you replacing the int10 and Long with?
Can you test my latest update?
I'm afraid that using Long class for all math isn't good. I think that better use Long only in
mul and
sqr functions. Then we can remove all unnecessary optimizations from Long class.
But fastest approach must forgive about Long class and use only JS-friendly math. I have working(and fast, more faster than latest version on github)
sign function, but can't solve problems with verify, so continue my work.