Browse Source

rolled back to kernel working on GTX960

cl-refactor
Jan Willem Penterman 9 years ago
parent
commit
e44de65f3c
  1. 2
      BuildInfo.h.in
  2. 3
      CMakeLists.txt
  3. 8
      ethminer/MinerAux.h
  4. 6
      libethash-cuda/ethash_cuda_miner.cpp

2
BuildInfo.h.in

@ -1,6 +1,6 @@
#pragma once
#define ETH_PROJECT_VERSION "@PROJECT_VERSION@"
#define ETH_PROJECT_VERSION "@PROJECT_VERSION@-genoil-@GENOIL_VERSION@"
#define ETH_COMMIT_HASH @ETH_COMMIT_HASH@
#define ETH_CLEAN_REPO @ETH_CLEAN_REPO@
#define ETH_BUILD_TYPE @ETH_BUILD_TYPE@

3
CMakeLists.txt

@ -2,6 +2,7 @@
cmake_minimum_required(VERSION 2.8.12)
set(PROJECT_VERSION "0.9.41")
set(GENOIL_VERSION "1.0.1")
if (${CMAKE_VERSION} VERSION_GREATER 3.0)
cmake_policy(SET CMP0042 OLD) # fix MACOSX_RPATH
cmake_policy(SET CMP0048 NEW) # allow VERSION argument in project()
@ -249,7 +250,7 @@ function(createBuildInfo)
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
COMMAND ${CMAKE_COMMAND} -DETH_SOURCE_DIR="${CMAKE_SOURCE_DIR}" -DETH_DST_DIR="${CMAKE_BINARY_DIR}"
-DETH_BUILD_TYPE="${_cmake_build_type}" -DETH_BUILD_PLATFORM="${ETH_BUILD_PLATFORM}"
-DPROJECT_VERSION="${PROJECT_VERSION}" -DETH_FATDB="${FATDB}"
-DPROJECT_VERSION="${PROJECT_VERSION}" -DGENOIL_VERSION="${GENOIL_VERSION}" -DETH_FATDB="${FATDB}"
-P "${ETH_SCRIPTS_DIR}/buildinfo.cmake"
)
include_directories(${CMAKE_CURRENT_BINARY_DIR})

8
ethminer/MinerAux.h

@ -266,14 +266,14 @@ public:
{
m_minerType = MinerType::CUDA;
cout << "Genoil's CUDA ethminer" << endl;
cout << "Genoil's CUDA ethminer " << ETH_PROJECT_VERSION << endl;
cout << "=====================================================================" << endl;
cout << "Forked from github.com/ethereum/cpp-ethereum" << endl;
cout << "Ported from Tim Hughes' OpenCL kernel" << endl;
cout << "With contributions from RoBiK, tpruvot and sp_ " << endl << endl;
cout << "Please consider donating a tiny fraction of the extra performance to:" << endl;
cout << "ETH: 0xeb9310b185455f863f526dab3d245809f6854b4d" << endl;
cout << "BTC: 1Nu2fMCEBjmnLzqb8qUJpKgq5RoEWFhNcW" << endl << endl;
cout << "Please consider a donation to:" << endl;
cout << "ETH: 0xeb9310b185455f863f526dab3d245809f6854b4d" << endl << endl;;
}
else if (arg == "--current-block" && i + 1 < argc)
m_currentBlock = stol(argv[++i]);

6
libethash-cuda/ethash_cuda_miner.cpp

@ -51,7 +51,7 @@
using namespace std;
unsigned const ethash_cuda_miner::c_defaultBlockSize = 128;
unsigned const ethash_cuda_miner::c_defaultGridSize = 2048; // * CL_DEFAULT_LOCAL_WORK_SIZE
unsigned const ethash_cuda_miner::c_defaultGridSize = 8192; // * CL_DEFAULT_LOCAL_WORK_SIZE
unsigned const ethash_cuda_miner::c_defaultNumStreams = 2;
#if defined(_WIN32)
@ -131,6 +131,10 @@ bool ethash_cuda_miner::configureGPU(
s_numStreams = _numStreams;
s_scheduleFlag = _scheduleFlag;
ETHCUDA_LOG(
"Using grid size " << s_gridSize << ", block size " << s_blockSize << endl
);
// by default let's only consider the DAG of the first epoch
uint64_t dagSize = ethash_get_datasize(_currentBlock);
uint64_t requiredSize = dagSize + _extraGPUMemory;

Loading…
Cancel
Save