Remove BITMASK macro

Bu işleme şunda yer alıyor:
John M. Schanck 2020-09-09 16:52:51 -04:00 işlemeyi yapan: Kris Kwiatkowski
ebeveyn 1325ba6dff
işleme 6cf952a2ce
24 değiştirilmiş dosya ile 24 ekleme ve 42 silme

Dosyayı Görüntüle

@ -10,8 +10,7 @@
#include "vector.h"
#define CEIL_DIVIDE(a, b) (((a)/(b)) + ((a) % (b) == 0 ? 0 : 1)) /*!< Divide a by b and ceil the result*/
#define BITMASK(a, size) ((1UL << ((a) % (size))) - 1) /*!< Create a mask*/
#define CEIL_DIVIDE(a, b) (((a)+(b)-1)/(b)) /*!< Divide a by b and ceil the result*/
/*
#define PARAM_N Define the parameter n of the scheme

Dosyayı Görüntüle

@ -116,7 +116,7 @@ void PQCLEAN_HQC128_AVX2_vect_set_random(AES_XOF_struct *ctx, uint64_t *v) {
seedexpander(ctx, rand_bytes, VEC_N_SIZE_BYTES);
memcpy(v, rand_bytes, VEC_N_SIZE_BYTES);
v[VEC_N_SIZE_64 - 1] &= BITMASK(PARAM_N, 64);
v[VEC_N_SIZE_64 - 1] &= RED_MASK;
}

Dosyayı Görüntüle

@ -10,8 +10,7 @@
#include "vector.h"
#define CEIL_DIVIDE(a, b) (((a)/(b)) + ((a) % (b) == 0 ? 0 : 1)) /*!< Divide a by b and ceil the result*/
#define BITMASK(a, size) ((1UL << ((a) % (size))) - 1) /*!< Create a mask*/
#define CEIL_DIVIDE(a, b) (((a)+(b)-1)/(b)) /*!< Divide a by b and ceil the result*/
/*
#define PARAM_N Define the parameter n of the scheme

Dosyayı Görüntüle

@ -148,7 +148,7 @@ void PQCLEAN_HQC128_CLEAN_vect_set_random(AES_XOF_struct *ctx, uint64_t *v) {
seedexpander(ctx, rand_bytes, VEC_N_SIZE_BYTES);
memcpy(v, rand_bytes, VEC_N_SIZE_BYTES);
v[VEC_N_SIZE_64 - 1] &= BITMASK(PARAM_N, 64);
v[VEC_N_SIZE_64 - 1] &= RED_MASK;
}

Dosyayı Görüntüle

@ -10,8 +10,7 @@
#include "vector.h"
#define CEIL_DIVIDE(a, b) (((a)/(b)) + ((a) % (b) == 0 ? 0 : 1)) /*!< Divide a by b and ceil the result*/
#define BITMASK(a, size) ((1UL << ((a) % (size))) - 1) /*!< Create a mask*/
#define CEIL_DIVIDE(a, b) (((a)+(b)-1)/(b)) /*!< Divide a by b and ceil the result*/
/*
#define PARAM_N Define the parameter n of the scheme

Dosyayı Görüntüle

@ -116,7 +116,7 @@ void PQCLEAN_HQC192_AVX2_vect_set_random(AES_XOF_struct *ctx, uint64_t *v) {
seedexpander(ctx, rand_bytes, VEC_N_SIZE_BYTES);
memcpy(v, rand_bytes, VEC_N_SIZE_BYTES);
v[VEC_N_SIZE_64 - 1] &= BITMASK(PARAM_N, 64);
v[VEC_N_SIZE_64 - 1] &= RED_MASK;
}

Dosyayı Görüntüle

@ -10,8 +10,7 @@
#include "vector.h"
#define CEIL_DIVIDE(a, b) (((a)/(b)) + ((a) % (b) == 0 ? 0 : 1)) /*!< Divide a by b and ceil the result*/
#define BITMASK(a, size) ((1UL << ((a) % (size))) - 1) /*!< Create a mask*/
#define CEIL_DIVIDE(a, b) (((a)+(b)-1)/(b)) /*!< Divide a by b and ceil the result*/
/*
#define PARAM_N Define the parameter n of the scheme

Dosyayı Görüntüle

@ -148,7 +148,7 @@ void PQCLEAN_HQC192_CLEAN_vect_set_random(AES_XOF_struct *ctx, uint64_t *v) {
seedexpander(ctx, rand_bytes, VEC_N_SIZE_BYTES);
memcpy(v, rand_bytes, VEC_N_SIZE_BYTES);
v[VEC_N_SIZE_64 - 1] &= BITMASK(PARAM_N, 64);
v[VEC_N_SIZE_64 - 1] &= RED_MASK;
}

Dosyayı Görüntüle

@ -10,8 +10,7 @@
#include "vector.h"
#define CEIL_DIVIDE(a, b) (((a)/(b)) + ((a) % (b) == 0 ? 0 : 1)) /*!< Divide a by b and ceil the result*/
#define BITMASK(a, size) ((1UL << ((a) % (size))) - 1) /*!< Create a mask*/
#define CEIL_DIVIDE(a, b) (((a)+(b)-1)/(b)) /*!< Divide a by b and ceil the result*/
/*
#define PARAM_N Define the parameter n of the scheme

Dosyayı Görüntüle

@ -116,7 +116,7 @@ void PQCLEAN_HQC256_AVX2_vect_set_random(AES_XOF_struct *ctx, uint64_t *v) {
seedexpander(ctx, rand_bytes, VEC_N_SIZE_BYTES);
memcpy(v, rand_bytes, VEC_N_SIZE_BYTES);
v[VEC_N_SIZE_64 - 1] &= BITMASK(PARAM_N, 64);
v[VEC_N_SIZE_64 - 1] &= RED_MASK;
}

Dosyayı Görüntüle

@ -10,8 +10,7 @@
#include "vector.h"
#define CEIL_DIVIDE(a, b) (((a)/(b)) + ((a) % (b) == 0 ? 0 : 1)) /*!< Divide a by b and ceil the result*/
#define BITMASK(a, size) ((1UL << ((a) % (size))) - 1) /*!< Create a mask*/
#define CEIL_DIVIDE(a, b) (((a)+(b)-1)/(b)) /*!< Divide a by b and ceil the result*/
/*
#define PARAM_N Define the parameter n of the scheme

Dosyayı Görüntüle

@ -148,7 +148,7 @@ void PQCLEAN_HQC256_CLEAN_vect_set_random(AES_XOF_struct *ctx, uint64_t *v) {
seedexpander(ctx, rand_bytes, VEC_N_SIZE_BYTES);
memcpy(v, rand_bytes, VEC_N_SIZE_BYTES);
v[VEC_N_SIZE_64 - 1] &= BITMASK(PARAM_N, 64);
v[VEC_N_SIZE_64 - 1] &= RED_MASK;
}

Dosyayı Görüntüle

@ -11,9 +11,7 @@
#include "api.h"
#define CEIL_DIVIDE(a, b) (((a)/(b)) + ((a) % (b) == 0 ? 0 : 1)) /*!< Divide a by b and ceil the result*/
#define BITMASK(a, size) ((1UL << ((a) % (size))) - 1) /*!< Create a mask*/
#define CEIL_DIVIDE(a, b) (((a)+(b)-1)/(b)) /*!< Divide a by b and ceil the result*/
/*
#define PARAM_N Define the parameter n of the scheme

Dosyayı Görüntüle

@ -116,7 +116,7 @@ void PQCLEAN_HQCRMRS128_AVX2_vect_set_random(AES_XOF_struct *ctx, uint64_t *v) {
seedexpander(ctx, rand_bytes, VEC_N_SIZE_BYTES);
memcpy(v, rand_bytes, VEC_N_SIZE_BYTES);
v[VEC_N_SIZE_64 - 1] &= BITMASK(PARAM_N, 64);
v[VEC_N_SIZE_64 - 1] &= RED_MASK;
}

Dosyayı Görüntüle

@ -11,9 +11,7 @@
#include "api.h"
#define CEIL_DIVIDE(a, b) (((a)/(b)) + ((a) % (b) == 0 ? 0 : 1)) /*!< Divide a by b and ceil the result*/
#define BITMASK(a, size) ((1UL << ((a) % (size))) - 1) /*!< Create a mask*/
#define CEIL_DIVIDE(a, b) (((a)+(b)-1)/(b)) /*!< Divide a by b and ceil the result*/
/*
#define PARAM_N Define the parameter n of the scheme

Dosyayı Görüntüle

@ -148,7 +148,7 @@ void PQCLEAN_HQCRMRS128_CLEAN_vect_set_random(AES_XOF_struct *ctx, uint64_t *v)
seedexpander(ctx, rand_bytes, VEC_N_SIZE_BYTES);
memcpy(v, rand_bytes, VEC_N_SIZE_BYTES);
v[VEC_N_SIZE_64 - 1] &= BITMASK(PARAM_N, 64);
v[VEC_N_SIZE_64 - 1] &= RED_MASK;
}

Dosyayı Görüntüle

@ -11,9 +11,7 @@
#include "api.h"
#define CEIL_DIVIDE(a, b) (((a)/(b)) + ((a) % (b) == 0 ? 0 : 1)) /*!< Divide a by b and ceil the result*/
#define BITMASK(a, size) ((1UL << ((a) % (size))) - 1) /*!< Create a mask*/
#define CEIL_DIVIDE(a, b) (((a)+(b)-1)/(b)) /*!< Divide a by b and ceil the result*/
/*
#define PARAM_N Define the parameter n of the scheme

Dosyayı Görüntüle

@ -116,7 +116,7 @@ void PQCLEAN_HQCRMRS192_AVX2_vect_set_random(AES_XOF_struct *ctx, uint64_t *v) {
seedexpander(ctx, rand_bytes, VEC_N_SIZE_BYTES);
memcpy(v, rand_bytes, VEC_N_SIZE_BYTES);
v[VEC_N_SIZE_64 - 1] &= BITMASK(PARAM_N, 64);
v[VEC_N_SIZE_64 - 1] &= RED_MASK;
}

Dosyayı Görüntüle

@ -11,9 +11,7 @@
#include "api.h"
#define CEIL_DIVIDE(a, b) (((a)/(b)) + ((a) % (b) == 0 ? 0 : 1)) /*!< Divide a by b and ceil the result*/
#define BITMASK(a, size) ((1UL << ((a) % (size))) - 1) /*!< Create a mask*/
#define CEIL_DIVIDE(a, b) (((a)+(b)-1)/(b)) /*!< Divide a by b and ceil the result*/
/*
#define PARAM_N Define the parameter n of the scheme

Dosyayı Görüntüle

@ -148,7 +148,7 @@ void PQCLEAN_HQCRMRS192_CLEAN_vect_set_random(AES_XOF_struct *ctx, uint64_t *v)
seedexpander(ctx, rand_bytes, VEC_N_SIZE_BYTES);
memcpy(v, rand_bytes, VEC_N_SIZE_BYTES);
v[VEC_N_SIZE_64 - 1] &= BITMASK(PARAM_N, 64);
v[VEC_N_SIZE_64 - 1] &= RED_MASK;
}

Dosyayı Görüntüle

@ -11,9 +11,7 @@
#include "api.h"
#define CEIL_DIVIDE(a, b) (((a)/(b)) + ((a) % (b) == 0 ? 0 : 1)) /*!< Divide a by b and ceil the result*/
#define BITMASK(a, size) ((1UL << ((a) % (size))) - 1) /*!< Create a mask*/
#define CEIL_DIVIDE(a, b) (((a)+(b)-1)/(b)) /*!< Divide a by b and ceil the result*/
/*
#define PARAM_N Define the parameter n of the scheme

Dosyayı Görüntüle

@ -116,7 +116,7 @@ void PQCLEAN_HQCRMRS256_AVX2_vect_set_random(AES_XOF_struct *ctx, uint64_t *v) {
seedexpander(ctx, rand_bytes, VEC_N_SIZE_BYTES);
memcpy(v, rand_bytes, VEC_N_SIZE_BYTES);
v[VEC_N_SIZE_64 - 1] &= BITMASK(PARAM_N, 64);
v[VEC_N_SIZE_64 - 1] &= RED_MASK;
}

Dosyayı Görüntüle

@ -11,9 +11,7 @@
#include "api.h"
#define CEIL_DIVIDE(a, b) (((a)/(b)) + ((a) % (b) == 0 ? 0 : 1)) /*!< Divide a by b and ceil the result*/
#define BITMASK(a, size) ((1UL << ((a) % (size))) - 1) /*!< Create a mask*/
#define CEIL_DIVIDE(a, b) (((a)+(b)-1)/(b)) /*!< Divide a by b and ceil the result*/
/*
#define PARAM_N Define the parameter n of the scheme

Dosyayı Görüntüle

@ -148,7 +148,7 @@ void PQCLEAN_HQCRMRS256_CLEAN_vect_set_random(AES_XOF_struct *ctx, uint64_t *v)
seedexpander(ctx, rand_bytes, VEC_N_SIZE_BYTES);
memcpy(v, rand_bytes, VEC_N_SIZE_BYTES);
v[VEC_N_SIZE_64 - 1] &= BITMASK(PARAM_N, 64);
v[VEC_N_SIZE_64 - 1] &= RED_MASK;
}