mirror of
https://github.com/arnaucube/poulpy.git
synced 2026-02-10 13:16:44 +01:00
Add circuit bootstrapping encrypt sk tmp_bytes
This commit is contained in:
@@ -51,6 +51,10 @@ impl CircuitBootstrappingKeyInfos for CircuitBootstrappingKeyLayout {
|
|||||||
}
|
}
|
||||||
|
|
||||||
pub trait CircuitBootstrappingKeyEncryptSk<BRA: BlindRotationAlgo, BE: Backend> {
|
pub trait CircuitBootstrappingKeyEncryptSk<BRA: BlindRotationAlgo, BE: Backend> {
|
||||||
|
fn circuit_bootstrapping_key_encrypt_sk_tmp_bytes<A>(&self, infos: &A) -> usize
|
||||||
|
where
|
||||||
|
A: CircuitBootstrappingKeyInfos;
|
||||||
|
|
||||||
#[allow(clippy::too_many_arguments)]
|
#[allow(clippy::too_many_arguments)]
|
||||||
fn circuit_bootstrapping_key_encrypt_sk<D, S0, S1>(
|
fn circuit_bootstrapping_key_encrypt_sk<D, S0, S1>(
|
||||||
&self,
|
&self,
|
||||||
@@ -123,6 +127,15 @@ where
|
|||||||
+ GLWESecretPreparedFactory<BE>,
|
+ GLWESecretPreparedFactory<BE>,
|
||||||
Scratch<BE>: ScratchTakeCore<BE>,
|
Scratch<BE>: ScratchTakeCore<BE>,
|
||||||
{
|
{
|
||||||
|
fn circuit_bootstrapping_key_encrypt_sk_tmp_bytes<A>(&self, infos: &A) -> usize
|
||||||
|
where
|
||||||
|
A: CircuitBootstrappingKeyInfos,
|
||||||
|
{
|
||||||
|
self.glwe_automorphism_key_encrypt_sk_tmp_bytes(&infos.atk_infos())
|
||||||
|
.max(self.blind_rotation_key_encrypt_sk_tmp_bytes(&infos.brk_infos()))
|
||||||
|
.max(self.gglwe_to_ggsw_key_encrypt_sk_tmp_bytes(&infos.tsk_infos()))
|
||||||
|
}
|
||||||
|
|
||||||
fn circuit_bootstrapping_key_encrypt_sk<D, S0, S1>(
|
fn circuit_bootstrapping_key_encrypt_sk<D, S0, S1>(
|
||||||
&self,
|
&self,
|
||||||
res: &mut CircuitBootstrappingKey<D, BRA>,
|
res: &mut CircuitBootstrappingKey<D, BRA>,
|
||||||
|
|||||||
Reference in New Issue
Block a user