Просмотр исходного кода

Remove the unused (and in fact now incorrect) RDPF::size function

Ian Goldberg 1 год назад
Родитель
Сommit
777f3da468
2 измененных файлов с 0 добавлено и 22 удалено
  1. 0 15
      rdpf.cpp
  2. 0 7
      rdpf.hpp

+ 0 - 15
rdpf.cpp

@@ -242,21 +242,6 @@ RDPF::RDPF(MPCTIO &tio, yield_t &yield,
     }
 }
 
-// The number of bytes it will take to store a RDPF of the given depth
-size_t RDPF::size(nbits_t depth)
-{
-    return sizeof(seed) + depth*sizeof(DPFnode) + BITBYTES(depth) +
-        sizeof(unit_sum_inverse) + sizeof(scaled_sum) +
-        sizeof(scaled_xor);
-}
-
-// The number of bytes it will take to store this RDPF
-size_t RDPF::size() const
-{
-    uint8_t depth = cw.size();
-    return size(depth);
-}
-
 // Get the leaf node for the given input
 DPFnode RDPF::leaf(address_t input, size_t &aes_ops) const
 {

+ 0 - 7
rdpf.hpp

@@ -43,13 +43,6 @@ struct RDPF : public DPF {
     RDPF(MPCTIO &tio, yield_t &yield,
         RegXS target, nbits_t depth, bool save_expansion = false);
 
-    // The number of bytes it will take to store this RDPF
-    size_t size() const;
-
-    // The number of bytes it will take to store a RDPF of the given
-    // depth
-    static size_t size(nbits_t depth);
-
     // Do we have a precomputed expansion?
     inline bool has_expansion() const { return expansion.size() > 0; }