SASC
DVBSoftCAM

parallel_032_4char.h File Reference

Go to the source code of this file.

Classes

struct  group_t
struct  batch_t

Defines

#define GROUP_PARALLELISM   32
#define BYTES_PER_BATCH   4

Typedefs

typedef struct group_t group
typedef struct batch_t batch

Functions

static group FF0 ()
static group FF1 ()
static group FFAND (group a, group b)
static group FFOR (group a, group b)
static group FFXOR (group a, group b)
static group FFNOT (group a)
static void FFTABLEIN (unsigned char *tab, int g, unsigned char *data)
static void FFTABLEOUT (unsigned char *data, unsigned char *tab, int g)
static void FFTABLEOUTXORNBY (int n, unsigned char *data, unsigned char *tab, int g)
static batch B_FFAND (batch a, batch b)
static batch B_FFOR (batch a, batch b)
static batch B_FFXOR (batch a, batch b)
static batch B_FFN_ALL_29 ()
static batch B_FFN_ALL_02 ()
static batch B_FFN_ALL_04 ()
static batch B_FFN_ALL_10 ()
static batch B_FFN_ALL_40 ()
static batch B_FFN_ALL_80 ()
static batch B_FFSH8L (batch a, int n)
static batch B_FFSH8R (batch a, int n)
static void M_EMPTY (void)

Define Documentation

#define BYTES_PER_BATCH   4

Definition at line 107 of file parallel_032_4char.h.

#define GROUP_PARALLELISM   32

Definition at line 26 of file parallel_032_4char.h.


Typedef Documentation

typedef struct batch_t batch

Definition at line 105 of file parallel_032_4char.h.

typedef struct group_t group

Definition at line 24 of file parallel_032_4char.h.


Function Documentation

static batch B_FFAND ( batch  a,
batch  b 
) [inline, static]

Definition at line 109 of file parallel_032_4char.h.

References batch_t::s1, batch_t::s2, batch_t::s3, and batch_t::s4.

                                            {
  batch res;
  res.s1=a.s1&b.s1;
  res.s2=a.s2&b.s2;
  res.s3=a.s3&b.s3;
  res.s4=a.s4&b.s4;
  return res;
}
static batch B_FFN_ALL_02 ( ) [inline, static]

Definition at line 145 of file parallel_032_4char.h.

References batch_t::s1, batch_t::s2, batch_t::s3, and batch_t::s4.

                                  {
  batch res;
  res.s1=0x02;
  res.s2=0x02;
  res.s3=0x02;
  res.s4=0x02;
  return res;
}
static batch B_FFN_ALL_04 ( ) [inline, static]

Definition at line 153 of file parallel_032_4char.h.

References batch_t::s1, batch_t::s2, batch_t::s3, and batch_t::s4.

                                  {
  batch res;
  res.s1=0x04;
  res.s2=0x04;
  res.s3=0x04;
  res.s4=0x04;
  return res;
}
static batch B_FFN_ALL_10 ( ) [inline, static]

Definition at line 161 of file parallel_032_4char.h.

References batch_t::s1, batch_t::s2, batch_t::s3, and batch_t::s4.

                                  {
  batch res;
  res.s1=0x10;
  res.s2=0x10;
  res.s3=0x10;
  res.s4=0x10;
  return res;
}
static batch B_FFN_ALL_29 ( ) [inline, static]

Definition at line 137 of file parallel_032_4char.h.

References batch_t::s1, batch_t::s2, batch_t::s3, and batch_t::s4.

                                  {
  batch res;
  res.s1=0x29;
  res.s2=0x29;
  res.s3=0x29;
  res.s4=0x29;
  return res;
}
static batch B_FFN_ALL_40 ( ) [inline, static]

Definition at line 169 of file parallel_032_4char.h.

References batch_t::s1, batch_t::s2, batch_t::s3, and batch_t::s4.

                                  {
  batch res;
  res.s1=0x40;
  res.s2=0x40;
  res.s3=0x40;
  res.s4=0x40;
  return res;
}
static batch B_FFN_ALL_80 ( ) [inline, static]

Definition at line 177 of file parallel_032_4char.h.

References batch_t::s1, batch_t::s2, batch_t::s3, and batch_t::s4.

                                  {
  batch res;
  res.s1=0x80;
  res.s2=0x80;
  res.s3=0x80;
  res.s4=0x80;
  return res;
}
static batch B_FFOR ( batch  a,
batch  b 
) [inline, static]

Definition at line 118 of file parallel_032_4char.h.

References batch_t::s1, batch_t::s2, batch_t::s3, and batch_t::s4.

                                           {
  batch res;
  res.s1=a.s1|b.s1;
  res.s2=a.s2|b.s2;
  res.s3=a.s3|b.s3;
  res.s4=a.s4|b.s4;
  return res;
}
static batch B_FFSH8L ( batch  a,
int  n 
) [inline, static]

Definition at line 186 of file parallel_032_4char.h.

References batch_t::s1, batch_t::s2, batch_t::s3, and batch_t::s4.

                                           {
  batch res;
  res.s1=a.s1<<n;
  res.s2=a.s2<<n;
  res.s3=a.s3<<n;
  res.s4=a.s4<<n;
  return res;
}
static batch B_FFSH8R ( batch  a,
int  n 
) [inline, static]

Definition at line 195 of file parallel_032_4char.h.

References batch_t::s1, batch_t::s2, batch_t::s3, and batch_t::s4.

                                           {
  batch res;
  res.s1=a.s1>>n;
  res.s2=a.s2>>n;
  res.s3=a.s3>>n;
  res.s4=a.s4>>n;
  return res;
}
static batch B_FFXOR ( batch  a,
batch  b 
) [inline, static]

Definition at line 127 of file parallel_032_4char.h.

References batch_t::s1, batch_t::s2, batch_t::s3, and batch_t::s4.

                                            {
  batch res;
  res.s1=a.s1^b.s1;
  res.s2=a.s2^b.s2;
  res.s3=a.s3^b.s3;
  res.s4=a.s4^b.s4;
  return res;
}
static group FF0 ( ) [inline, static]

Definition at line 28 of file parallel_032_4char.h.

References group_t::s1, group_t::s2, group_t::s3, and group_t::s4.

                         {
  group res;
  res.s1=0x0;
  res.s2=0x0;
  res.s3=0x0;
  res.s4=0x0;
  return res;
}
static group FF1 ( ) [inline, static]

Definition at line 37 of file parallel_032_4char.h.

References group_t::s1, group_t::s2, group_t::s3, and group_t::s4.

                         {
  group res;
  res.s1=0xff;
  res.s2=0xff;
  res.s3=0xff;
  res.s4=0xff;
  return res;
}
static group FFAND ( group  a,
group  b 
) [inline, static]

Definition at line 46 of file parallel_032_4char.h.

References group_t::s1, group_t::s2, group_t::s3, and group_t::s4.

                                          {
  group res;
  res.s1=a.s1&b.s1;
  res.s2=a.s2&b.s2;
  res.s3=a.s3&b.s3;
  res.s4=a.s4&b.s4;
  return res;
}
static group FFNOT ( group  a) [inline, static]

Definition at line 73 of file parallel_032_4char.h.

References group_t::s1, group_t::s2, group_t::s3, and group_t::s4.

                                  {
  group res;
  res.s1=~a.s1;
  res.s2=~a.s2;
  res.s3=~a.s3;
  res.s4=~a.s4;
  return res;
}
static group FFOR ( group  a,
group  b 
) [inline, static]

Definition at line 55 of file parallel_032_4char.h.

References group_t::s1, group_t::s2, group_t::s3, and group_t::s4.

                                         {
  group res;
  res.s1=a.s1|b.s1;
  res.s2=a.s2|b.s2;
  res.s3=a.s3|b.s3;
  res.s4=a.s4|b.s4;
  return res;
}
static void FFTABLEIN ( unsigned char *  tab,
int  g,
unsigned char *  data 
) [inline, static]

Definition at line 85 of file parallel_032_4char.h.

References data.

                                                                            {
  *(((int *)tab)+g)=*((int *)data);
  *(((int *)tab)+32+g)=*(((int *)data)+1);
}
static void FFTABLEOUT ( unsigned char *  data,
unsigned char *  tab,
int  g 
) [inline, static]

Definition at line 90 of file parallel_032_4char.h.

                                                                             {
  *((int *)data)=*(((int *)tab)+g);
  *(((int *)data)+1)=*(((int *)tab)+32+g);
}
static void FFTABLEOUTXORNBY ( int  n,
unsigned char *  data,
unsigned char *  tab,
int  g 
) [inline, static]

Definition at line 95 of file parallel_032_4char.h.

References j.

                                                                                          {
  int j;
  for(j=0;j<n;j++){
    *(data+j)^=*(tab+4*(g+(j>=4?32-1:0))+j);
  }
}
static group FFXOR ( group  a,
group  b 
) [inline, static]

Definition at line 64 of file parallel_032_4char.h.

References group_t::s1, group_t::s2, group_t::s3, and group_t::s4.

                                          {
  group res;
  res.s1=a.s1^b.s1;
  res.s2=a.s2^b.s2;
  res.s3=a.s3^b.s3;
  res.s4=a.s4^b.s4;
  return res;
}
static void M_EMPTY ( void  ) [inline, static]

Definition at line 205 of file parallel_032_4char.h.

                                {
}
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines