[][src]Function isa_l::ec_encode_data_owned

#[must_use]pub fn ec_encode_data_owned<T>(
    len: usize,
    k: usize,
    rows: usize,
    gftbls: impl AsRef<[u8]>,
    data: impl AsRef<[T]>
) -> Vec<Vec<u8>> where
    T: AsRef<[u8]>, 

Generate or decode erasure codes on blocks of data, runs appropriate version.

Given a list of source data blocks, generate one or multiple blocks of encoded data as specified by a matrix of GF(2^8) coefficients. When given a suitable set of coefficients, this function will perform the fast generation or decoding of Reed-Solomon type erasure codes.

This function determines what instruction sets are enabled and selects the appropriate version at runtime.

Arguments:

  • len: Length of each block of data (vector) of source or dest data.
  • k: The number of vector sources or rows in the generator matrix for coding.
  • rows: The number of output vectors to concurrently encode/decode.
  • gftbls: Input tables generated from coding coefficients in ec_init_tables(). Must be of size 32 * k * rows
  • data: Source input slices.