Browse Source

algorithm: initial structure definition.

build-mingw
Noel Maersk 11 years ago
parent
commit
776eec2e11
  1. 1
      Makefile.am
  2. 17
      algorithm.c
  3. 10
      algorithm.h

1
Makefile.am

@ -41,6 +41,7 @@ sgminer_SOURCES += driver-opencl.c driver-opencl.h @@ -41,6 +41,7 @@ sgminer_SOURCES += driver-opencl.c driver-opencl.h
sgminer_SOURCES += ocl.c ocl.h
sgminer_SOURCES += findnonce.c findnonce.h
sgminer_SOURCES += adl.c adl.h adl_functions.h
sgminer_SOURCES += algorithm.c algorithm.h
sgminer_SOURCES += scrypt.c scrypt.h
sgminer_SOURCES += kernel/*.cl

17
algorithm.c

@ -0,0 +1,17 @@ @@ -0,0 +1,17 @@
/*
* Copyright 2014 sgminer developers
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 3 of the License, or (at
* your option) any later version. See COPYING for more details.
*/
#include "algorithm.h"
#include <inttypes.h>
typedef struct algorithm_t {
char name[32]; /* Human-readable identifier */
uint8_t nfactor; /* N factor (CPU/Memory tradeoff parameter) */
} algorithm_t;

10
algorithm.h

@ -0,0 +1,10 @@ @@ -0,0 +1,10 @@
#ifndef ALGORITHM_H
#define ALGORITHM_H
/* Describes the Scrypt parameters and hashing functions used to mine
* a specific coin.
*/
typedef struct algorithm_t algorithm_t;
#endif /* ALGORITHM_H */
Loading…
Cancel
Save