C# Class BitMaker.Miner.Gpu.GpuMiner

CPU miner base class which provides a place to plug in the search algorithm.
Inheritance: IMiner
Show file Open project: wasabii/BitMaker Class Usage Examples

Public Methods

Method Description
GpuMiner ( IMinerContext context, GpuDevice gpu ) : System

Initializes a new instance.

Start ( ) : void

Starts a single thread to pull and process work.

Stop ( ) : void

Stops the miner from running.

Private Methods

Method Description
InitializeOpenCL ( ) : void

Attempts to initialize OpenCL for the selected GPU.

PrepareWork ( Work work, byte &round1Blocks, uint &round1State, byte &round2Blocks, uint &round2State ) : void

Prepares the buffers for processing a work item.

Progress ( Work work, long hashes ) : bool

Reports progress and checks for whether we should terminate the current work item.

Work ( Work work ) : void

Attempts to solve the given work with the specified solver. Returns true if a solution is found. work is updated to reflect the solution.

WorkThread ( ) : void

Entry point for a standard work thread.

Method Details

GpuMiner() public method

Initializes a new instance.
public GpuMiner ( IMinerContext context, GpuDevice gpu ) : System
context IMinerContext
gpu GpuDevice
return System

Start() public method

Starts a single thread to pull and process work.
public Start ( ) : void
return void

Stop() public method

Stops the miner from running.
public Stop ( ) : void
return void