utils/gcm-ref (present_gf_pmull): Round width up to a multiple of 64 bits.
[catacomb] / utils / gcm-ref
index 0367241..bec00d7 100755 (executable)
@@ -258,6 +258,7 @@ def present_gf_pmull(tag, wd, x, w, n, what):
   if tag == TAG_PRODPIECE or tag == TAG_REDCFULL or tag == TAG_SHIFTED:
     return
   elif tag == TAG_INPUT_V or tag == TAG_KPIECE_V:
+    w = (w + 63)&~63
     bx = C.ReadBuffer(x.storeb(w/8))
     by = C.WriteBuffer()
     while bx.left: chunk = bx.get(8); by.put(chunk).put(chunk)