1
0
mirror of https://github.com/GOSTSec/sgminer synced 2025-01-22 12:34:27 +00:00

algorithm: initial structure definition.

This commit is contained in:
Noel Maersk 2014-03-06 20:55:56 +02:00
parent 11cf733ede
commit 776eec2e11
3 changed files with 28 additions and 0 deletions

View File

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

17
algorithm.c Normal file
View File

@ -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 Normal file
View File

@ -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 */