Commit Graph

2 Commits

Author SHA1 Message Date
Daniel Axtens 90679884ef ISA-L: Only calculate gf tables on init, not every encode
Currently, the Galois Field multiplication tables are recalcuated
every time an encode is done. This is wasteful, as they are fixed
by k and m, which is set on init.

Calculate the tables only once, on init.

This trades off a little bit of per-context memory and creation
time for measurably faster encodes when using the same context.

On powerpc64le, when repeatedly encoding a 4kB file with pyeclib,
this increases the measured speed by over 10%.

Change-Id: I2f025aaee2d13cb1717a331e443e179ad5a13302
Signed-off-by: Daniel Axtens <dja@axtens.net>
2017-02-13 09:43:24 +11:00
Kota Tsuyuzaki 8d067ab2f6 ISA-L Cauchy support
This is for supporting ISA-L cauchy based matrix. The difference
from isa_l_rs_vand is only the matrix to use the encode/decode calculation.

As a known issue, isa_l_rs_vand backend has constraint for the
combinations of the available fragment to be able to decode/reconstuct.
(See related change in detail)

To avoid the constraint, this patch adds another isa-l backend to use
cauchy matrix and keep the backward compatibility, this is in
another isa_l_rs_cauchy namespace.

For implementation consieration, the code is almost same except the matrix
generation fucntion so that this patch makes isa_l_common.c file for
gathering common fucntions like init/encode/decode/reconstruct. And then the
common init funciton takes an extra args "gen_matrix_func_name" for entry
point to load the fucntion by dlsym from isa-l .so file.

Co-Authored-By: Clay Gerrard <clay.gerrard@gmail.com>

Related-Change: Icee788a0931fe692fe0de31fabc4ba450e338a87
Change-Id: I6eb150d9d0c3febf233570fa7729f9f72df2e9be
2016-12-06 17:08:55 -08:00