Traits§
- CnvP
VecAlloc - Allocates prepared convolution operands (
CnvPVecL,CnvPVecR). - CnvP
VecBytes Of - Returns the byte sizes for prepared convolution operands.
- Convolution
- Bivariate convolution over
Z[X, Y] mod (X^N + 1)whereY = 2^{-K}. - Host
BufMut - Host-visible borrowed scratch region for a backend.
- MatZnx
Alloc - Allocates backend-owned
MatZnxlayouts. - Module
LogN - Query
log2(N)with a default implementation derived fromModuleN::n. - ModuleN
- Query the ring degree
Nof aModule. - Module
New - Instantiate a new crate::layouts::Module.
- NegacyclicFFT
- Abstract precomputed table for the negacyclic (reim) FFT and its inverse.
- NegacyclicFFT
New - Extension of
NegacyclicFFTthat also provides a constructor. - Scalar
ZnxAlloc - Allocates backend-owned
ScalarZnxlayouts. - Scalar
ZnxFill Binary Block Backend - Scalar
ZnxFill Binary Block Source Backend - Scalar
ZnxFill Binary HwBackend - Scalar
ZnxFill Binary HwSource Backend - Scalar
ZnxFill Binary Prob Backend - Scalar
ZnxFill Binary Prob Source Backend - Scalar
ZnxFill Ternary HwBackend - Scalar
ZnxFill Ternary HwSource Backend - Scalar
ZnxFill Ternary Prob Backend - Scalar
ZnxFill Ternary Prob Source Backend - Scratch
Arena Take Basic - Backend-native arena allocation of typed HAL layouts.
- Scratch
Available - Returns how many bytes left can be taken from the scratch.
- Scratch
Owned Alloc - Allocates a new crate::layouts::ScratchOwned of
sizealigned bytes. - Scratch
Owned Borrow - Borrows an owned scratch buffer as a backend-native arena.
- SvpApply
Dft - Apply a scalar-vector product between
a[a_col]andb[b_col]and stores the result onres[res_col]. - SvpApply
DftTo Dft - Apply a scalar-vector product between
a[a_col]andb[b_col]and stores the result onres[res_col]. - SvpApply
DftTo DftAssign - Apply a scalar-vector product between
res[res_col]anda[a_col]and stores the result onres[res_col]. - SvpP
PolAlloc - Allocates as crate::layouts::SvpPPol.
- SvpP
PolBytes Of - Returns the size in bytes to allocate a crate::layouts::SvpPPol.
- SvpP
PolCopy Backend - Copy one prepared scalar polynomial column into another.
- SvpPrepare
- Prepare a crate::layouts::ScalarZnx into an crate::layouts::SvpPPol.
- VecZnx
AddAssign Backend - VecZnx
AddConst Assign Backend - VecZnx
AddConst Into Backend - VecZnx
AddInto Backend - VecZnx
AddNormal Backend - VecZnx
AddNormal Source Backend - VecZnx
AddScalar Assign Backend - VecZnx
AddScalar Into Backend - VecZnx
Alloc - Allocates backend-owned
VecZnxlayouts. - VecZnx
Automorphism Assign Backend - VecZnx
Automorphism Assign TmpBytes - VecZnx
Automorphism Backend - VecZnx
BigAdd Assign - VecZnx
BigAdd Into - VecZnx
BigAdd Normal - Add a discrete normal distribution on res.
- VecZnx
BigAdd Normal Backend - VecZnx
BigAdd Small Assign - VecZnx
BigAdd Small Into Backend - VecZnx
BigAlloc - Allocates as crate::layouts::VecZnxBig.
- VecZnx
BigAutomorphism - VecZnx
BigAutomorphism Assign - VecZnx
BigAutomorphism Assign TmpBytes - Returns scratch bytes required for in-place automorphism on
VecZnxBig. - VecZnx
BigBytes Of - Returns the size in bytes to allocate a crate::layouts::VecZnxBig.
- VecZnx
BigFrom Bytes - Consume a vector of bytes into a crate::layouts::VecZnxBig. User must ensure that bytes is memory aligned and that its length is equal to VecZnxBigBytesOf::bytes_of_vec_znx_big.
- VecZnx
BigFrom Small Backend - Converts a coefficient-domain
VecZnxcolumn into aVecZnxBigcolumn. - VecZnx
BigInner SumBackend - Sums coefficients from a selected
VecZnxBigcolumn and stores each limb’s result in one destination coefficient. - VecZnx
BigNegate - Negates the selected column of
aand stores the result inres. - VecZnx
BigNegate Assign - Negates the selected column of
resin-place. - VecZnx
BigNormalize - Normalizes a
VecZnxBiginto a coefficient-domainVecZnxwith the target base and offset. - VecZnx
BigNormalize TmpBytes - Returns scratch bytes required for
VecZnxBigNormalize. - VecZnx
BigSub - VecZnx
BigSub Assign - VecZnx
BigSub Negate Assign - VecZnx
BigSub SmallA Backend - VecZnx
BigSub Small Assign - VecZnx
BigSub SmallB Backend - VecZnx
BigSub Small Negate Assign - VecZnx
Copy Backend - VecZnx
Copy Range Backend - VecZnx
DftAdd Assign - In-place addition in DFT domain:
res += a. - VecZnx
DftAdd Into - Element-wise addition of two
VecZnxDftvectors. - VecZnx
DftAdd Scaled Assign - In-place scaled addition in DFT domain:
res += a * a_scale. - VecZnx
DftAlloc - Allocates a
VecZnxDft. - VecZnx
DftApply - Applies the forward DFT to a coefficient-domain
VecZnx, storing the result in aVecZnxDft. - VecZnx
DftBytes Of - Returns the byte size required for a
VecZnxDft. - VecZnx
DftCopy - Copies selected limbs from one
VecZnxDftto another. - VecZnx
DftFrom Bytes - Wraps a byte buffer into a
VecZnxDft. - VecZnx
DftSub - Element-wise subtraction of two
VecZnxDftvectors. - VecZnx
DftSub Assign - In-place subtraction in DFT domain:
res -= a. - VecZnx
DftSub Negate Assign - In-place negated subtraction in DFT domain:
res = a - res. - VecZnx
DftZero - Zeroes all limbs of the selected column in DFT domain.
- VecZnx
Extract Coeff Backend - VecZnx
Fill Normal Backend - VecZnx
Fill Normal Source Backend - Fills the selected column with a discrete Gaussian noise vector
scaled by
2^{-k}with standard deviationsigma, bounded to[-bound, bound]. - VecZnx
Fill Uniform Backend - VecZnx
Fill Uniform Source Backend - VecZnx
Hadamard Product Scalar ZnxBackend - VecZnx
Idft Apply - Applies the inverse DFT, converting a
VecZnxDftinto aVecZnxBig(extended precision). - VecZnx
Idft Apply TmpA - Inverse DFT using
aas temporary storage (avoids extra scratch). - VecZnx
Idft Apply TmpBytes - Returns scratch bytes required for
VecZnxIdftApply. - VecZnx
LshAdd Coeff Into Backend - VecZnx
LshAdd Into Backend - VecZnx
LshAssign Backend - VecZnx
LshBackend - VecZnx
LshCoeff Backend - VecZnx
LshSub Backend - VecZnx
LshTmp Bytes - Returns scratch bytes required for left-shift operations.
- VecZnx
Merge Rings Backend - VecZnx
Merge Rings TmpBytes - VecZnx
MulXp Minus OneAssign Backend - VecZnx
MulXp Minus OneAssign TmpBytes - VecZnx
MulXp Minus OneBackend - Multiplies the selected column by
(X^p - 1)inZ[X]/(X^N + 1). - VecZnx
Negate Assign Backend - VecZnx
Negate Backend - VecZnx
Normalize - VecZnx
Normalize Assign Backend - VecZnx
Normalize Coeff Assign Backend - VecZnx
Normalize Coeff Backend - VecZnx
Normalize TmpBytes - VecZnx
Rotate Assign Backend - VecZnx
Rotate Assign TmpBytes - VecZnx
Rotate Backend - VecZnx
RshAdd Coeff Into Backend - VecZnx
RshAdd Into Backend - VecZnx
RshAssign Backend - VecZnx
RshBackend - VecZnx
RshCoeff Backend - VecZnx
RshSub Backend - VecZnx
RshSub Coeff Into Backend - VecZnx
RshTmp Bytes - Returns scratch bytes required for right-shift operations.
- VecZnx
Scalar Product - Computes the element-wise (Hadamard) product
res[k] = a[k] * b[k]for allkand stores each product as aScalarBigvalue inres. UseVecZnxBigInnerSumBackendafterwards to reduce to a single scalar. - VecZnx
Split Ring Backend - VecZnx
Split Ring TmpBytes - VecZnx
SubAssign Backend - VecZnx
SubBackend - VecZnx
SubNegate Assign Backend - VecZnx
SubScalar Assign Backend - VecZnx
SubScalar Backend - VecZnx
Switch Ring Backend - Switches ring degree between
aandresby truncation or zero-padding. - VecZnx
Zero Backend - VmpApply
Dft - Applies the vector-matrix product
VecZnx x VmpPMat -> VecZnxDft. - VmpApply
DftTmp Bytes - Returns scratch bytes required for
VmpApplyDft. - VmpApply
DftTo Dft - VmpApply
DftTo DftAccumulate - VmpApply
DftTo DftAccumulate TmpBytes - Returns scratch bytes required for
VmpApplyDftToDftAccumulate. - VmpApply
DftTo DftTmp Bytes - Returns scratch bytes required for
VmpApplyDftToDft. - VmpP
MatAlloc - Allocates a
VmpPMat. - VmpP
MatBytes Of - Returns the byte size required for a
VmpPMat. - VmpPrepare
- Prepares a coefficient-domain
MatZnxinto a DFT-domainVmpPMat. - VmpPrepare
TmpBytes - Returns scratch bytes required for
VmpPrepare. - VmpZero
- Zeroes all entries of a
VmpPMat.