- 8C306BD23D12315A8D62F760968B2CF32BDA6F49279B3F995DF7A100587C7B273E79C327C295521E42BEDA4D1E0A9F0E7F4C5293D57E92843B82C69A353F4687
+ 83D6EB138AF7DBBE49A29FBD4AF186EA79F8D4441FD84814316E84C20DE20614F7B9D69B3BD8E160BA37FC6C30B83AEC2CCC26600E289D87225C677686C6072B
ffa/libffa/fz_barr.adb
(2 . 7)(2 . 7)
537 ------------------------------------------------------------------------------
538 -- This file is part of 'Finite Field Arithmetic', aka 'FFA'. --
539 -- --
540 -- (C) 2018 Stanislav Datskovskiy ( www.loper-os.org ) --
541 -- (C) 2019 Stanislav Datskovskiy ( www.loper-os.org ) --
542 -- http://wot.deedbot.org/17215D118B7239507FAFED98B98228A001ABFFC7.html --
543 -- --
544 -- You do not have, nor can you ever acquire the right to use, copy or --
(255 . 10)(255 . 10)
546 -- Result is initially zero (and will stay zero if Modulus = 1)
547 FZ_Clear(XReduced);
548
549 -- (1) Ns := X >> Jm
550 -- (1) Xs := X >> Jm
551 FZ_Quiet_ShiftRight(N => X, ShiftedN => Xs, Count => Bar.J);
552
553 -- (2) Z := X * Bm
554 -- (2) Z := Xs * Bm
555 FZ_Multiply_Unbuffered(X => Bar.B, Y => Xs, XY => Z);
556
557 -- (3) Zs := Z >> 2Wm - Jm (already thrown lower Wm, so only Wm - Jm now)