-from .log2 import floor_log2
+from nmigen_gf.reference.log2 import floor_log2
def cldivrem(n, d, width):
-from .clmul import clmul
+from nmigen_gf.reference.clmul import clmul
def clmulh(a, b, XLEN):
-from .clmul import clmul
+from nmigen_gf.reference.clmul import clmul
def clmulh(a, b, XLEN):
-from .state import ST
+from nmigen_gf.reference.state import ST
def decode_reducing_polynomial():
-from .decode_reducing_polynomial import decode_reducing_polynomial
-from .cldivrem import degree
+from nmigen_gf.reference.decode_reducing_polynomial import decode_reducing_polynomial
+from nmigen_gf.reference.cldivrem import degree
def gfbinv(a):
-from .state import ST
-from .decode_reducing_polynomial import decode_reducing_polynomial
-from .clmul import clmul
-from .cldivrem import cldivrem
+from nmigen_gf.reference.state import ST
+from nmigen_gf.reference.decode_reducing_polynomial import decode_reducing_polynomial
+from nmigen_gf.reference.clmul import clmul
+from nmigen_gf.reference.cldivrem import cldivrem
def gfbmadd(a, b, c):
-from .state import ST
-from .decode_reducing_polynomial import decode_reducing_polynomial
-from .clmul import clmul
-from .cldivrem import cldivrem
+from nmigen_gf.reference.state import ST
+from nmigen_gf.reference.decode_reducing_polynomial import decode_reducing_polynomial
+from nmigen_gf.reference.clmul import clmul
+from nmigen_gf.reference.cldivrem import cldivrem
def gfbmul(a, b):
-from .state import ST
+from nmigen_gf.reference.state import ST
def gfbredpoly(immed):
-from .state import ST
+from nmigen_gf.reference.state import ST
def gfpadd(a, b):
-from .state import ST
+from nmigen_gf.reference.state import ST
def gfpinv(a):
-from .state import ST
+from nmigen_gf.reference.state import ST
def gfpmadd(a, b, c):
-from .state import ST
+from nmigen_gf.reference.state import ST
def gfpmsub(a, b, c):
-from .state import ST
+from nmigen_gf.reference.state import ST
def gfpmsubr(a, b, c):
-from .state import ST
+from nmigen_gf.reference.state import ST
def gfpmul(a, b):
-from .state import ST
+from nmigen_gf.reference.state import ST
def gfpsub(a, b):
-from .log2 import floor_log2
+from nmigen_gf.reference.log2 import floor_log2
from threading import local
-from .state import ST
-from .cldivrem import cldivrem
-from .clmul import clmul
-from .gfbmul import gfbmul
-from .gfbmadd import gfbmadd
-from .gfbinv import gfbinv
-from .gfpadd import gfpadd
-from .gfpsub import gfpsub
-from .gfpmul import gfpmul
-from .gfpinv import gfpinv
-from .gfpmadd import gfpmadd
-from .gfpmsub import gfpmsub
-from .gfpmsubr import gfpmsubr
-from .pack_poly import pack_poly, unpack_poly
+from nmigen_gf.reference.state import ST
+from nmigen_gf.reference.cldivrem import cldivrem
+from nmigen_gf.reference.clmul import clmul
+from nmigen_gf.reference.gfbmul import gfbmul
+from nmigen_gf.reference.gfbmadd import gfbmadd
+from nmigen_gf.reference.gfbinv import gfbinv
+from nmigen_gf.reference.gfpadd import gfpadd
+from nmigen_gf.reference.gfpsub import gfpsub
+from nmigen_gf.reference.gfpmul import gfpmul
+from nmigen_gf.reference.gfpinv import gfpinv
+from nmigen_gf.reference.gfpmadd import gfpmadd
+from nmigen_gf.reference.gfpmsub import gfpmsub
+from nmigen_gf.reference.gfpmsubr import gfpmsubr
+from nmigen_gf.reference.pack_poly import pack_poly, unpack_poly
import unittest