This commit is contained in:
Jay D Dee
2017-07-24 21:38:32 -04:00
parent f8907677f6
commit ec4f6028a2
18 changed files with 158 additions and 183 deletions

View File

@@ -8,28 +8,12 @@
#define DATA_ALIGN(x) __declspec(align(16)) x
#endif
#include "compat.h"
#include "simd-compat.h"
#include "algo/sha/sha3-defs.h"
/*
* NIST API Specific types.
*/
//typedef unsigned char BitSequence;
//#ifdef HAS_64
// typedef u64 DataLength;
//#else
// typedef unsigned long DataLength;
//#endif
// can't find u32 or fft-t
#include <stdint.h>
typedef uint32_t u32;
typedef int fft_t;
//typedef enum { SUCCESS = 0, FAIL = 1, BAD_HASHBITLEN = 2} HashReturn;
typedef struct {
unsigned int hashbitlen;
unsigned int blocksize;

View File

@@ -1,5 +1,5 @@
#ifndef __COMPAT_H__
#define __COMPAT_H__
#ifndef __SIMD_COMPAT_H__
#define __SIMD_COMPAT_H__
#include <limits.h>
@@ -24,14 +24,7 @@
*/
#include <stdint.h>
#ifdef UINT32_MAX
typedef uint32_t u32;
#else
typedef uint_fast32_t u32;
#endif
typedef unsigned long long u64;
#include "algo/sha/brg_types.h"
#define C32(x) ((u32)(x))