flat assembler
Message board for the users of flat assembler.
Index
> Projects and Ideas > multiprecision calculator for win64 Goto page Previous 1, 2 |
Author |
|
bitRAKE 09 Aug 2013, 13:50
So, you just want to know if a number is a perfect square? If so, then return square root? Otherwise, I'm confused.
This thread seems to cover both fast exclusion and calculation: http://board.flatassembler.net/topic.php?p=134231#134231 Multiple limb algorithms will use a fast approximation, and newtons method. A good initial guess is just to clip the binary string to half the length. _________________ ¯\(°_o)/¯ “languages are not safe - uses can be” Bjarne Stroustrup |
|||
09 Aug 2013, 13:50 |
|
tthsqe 09 Aug 2013, 14:54
Yes - if it is a perfect square, it should return the square root, otherwise fail.
I really though you had a purely integer clever solution... |
|||
09 Aug 2013, 14:54 |
|
tthsqe 10 Aug 2013, 13:11
Alright, the new version checks if sqrt(x) and x/y are integers during evaluation. It also has an SSA-based optimizer which can speed up loops by about 30%.
|
|||
10 Aug 2013, 13:11 |
|
Goto page Previous 1, 2 < Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.