Refactor Lattice Layer
-
Create lattice/lat-hal.h
fromlattice/backend.h
-
Create new folder hal
(in both src and include)-
Move dcrtpolyinterface.h
intohal
folder -
New folder hexl
-
New folder default
(this is DCRTPolyImpl<>) -
Would also have other accelerators at this level (not here of course)
-
-
Move the logic for select DCRTPoly into hal//backend.h -
break-up src/core/lib/lattice/dcrtpoly-impl.cpp
and move the Hexl stuff to hal/hexl folder, and DCRTPolyImpl to hal/default...⚠ but leave the ILDCRTParams in this file.
Click to expand
Break this up into seperate files
#if defined(WITH_INTEL_HEXL) // Hardware specialization
using M2DCRTPoly = HexlDCRTPoly<M2Vector>;
using M4DCRTPoly = HexlDCRTPoly<M4Vector>;
#ifdef WITH_NTL
using M6DCRTPoly = HexlDCRTPoly<M6Vector>;
#endif
using DCRTPoly = HexlDCRTPoly<BigVector>;
#else // Default case
using M2DCRTPoly = DCRTPolyImpl<M2Vector>;
using M4DCRTPoly = DCRTPolyImpl<M4Vector>;
#ifdef WITH_NTL
using M6DCRTPoly = DCRTPolyImpl<M6Vector>;
#endif
using DCRTPoly = DCRTPolyImpl<BigVector>;
#endif
@dsuponitskiy & @jsaylor1 will work on this.
Edited by Jonathan Saylor