fixed

Pure Haskell large fixed-width integers.
git clone git://git.ppad.tech/fixed.git
Log | Files | Refs | README | LICENSE

commit d46ec11d2102c5ea5b28fdb7a7d5da20d58f40c7
parent 568440d7d884e1ed680d3a8ebdd4bd18a2f5edcb
Author: Jared Tobin <jared@jtobin.io>
Date:   Thu, 23 Jan 2025 23:33:07 +0400

src: update profiler

Diffstat:
Msrc/Main.hs | 11++++-------
1 file changed, 4 insertions(+), 7 deletions(-)

diff --git a/src/Main.hs b/src/Main.hs @@ -20,18 +20,15 @@ main = do , 3741537094902495500 ] - re <- PA.newPrimArray 4 - PA.setPrimArray re 0 4 0 quo <- PA.newPrimArray 5 - let go !j + let go !j !acc | j == 10000 = pure () | otherwise = do PA.setPrimArray quo 0 5 0 - quotrem quo u d (Just re) - go (succ j) - go 0 + w <- quotrem quo u d + go (succ j) w + r <- go 0 zero q <- PA.unsafeFreezePrimArray quo - r <- PA.unsafeFreezePrimArray re print r print q