mirror of
https://github.com/arnaucube/poulpy.git
synced 2026-02-10 13:16:44 +01:00
Ref. + AVX code & generic tests + benches (#85)
This commit is contained in:
committed by
GitHub
parent
99b9e3e10e
commit
56dbd29c59
@@ -50,8 +50,8 @@ where
|
||||
}
|
||||
|
||||
impl<D: DataMut> FillUniform for LWECiphertextCompressed<D> {
|
||||
fn fill_uniform(&mut self, source: &mut Source) {
|
||||
self.data.fill_uniform(source);
|
||||
fn fill_uniform(&mut self, log_bound: usize, source: &mut Source) {
|
||||
self.data.fill_uniform(log_bound, source);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -124,15 +124,9 @@ where
|
||||
Module<B>: ZnFillUniform,
|
||||
{
|
||||
fn decompress(&mut self, module: &Module<B>, other: &LWECiphertextCompressed<DR>) {
|
||||
debug_assert_eq!(self.size(), other.size());
|
||||
let mut source: Source = Source::new(other.seed);
|
||||
module.zn_fill_uniform(
|
||||
self.n(),
|
||||
other.basek(),
|
||||
&mut self.data,
|
||||
0,
|
||||
other.k(),
|
||||
&mut source,
|
||||
);
|
||||
module.zn_fill_uniform(self.n(), other.basek(), &mut self.data, 0, &mut source);
|
||||
(0..self.size()).for_each(|i| {
|
||||
self.data.at_mut(0, i)[0] = other.data.at(0, i)[0];
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user