-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathcaldgemm_cpu.h
57 lines (51 loc) · 1.98 KB
/
caldgemm_cpu.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
/**
* Interface of the CALDGEMM library.
*
* Copyright 2015:
* - David Rohr ([email protected])
* - Matthias Bach ([email protected])
* - Matthias Kretz ([email protected])
*
* This file is part of CALDGEMM.
*
* CALDGEMM is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* CALDGEMM is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with CALDGEMM. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef caldgemm_cpu_H
#define caldgemm_cpu_H
#include "caldgemm.h"
class caldgemm_cpu : public caldgemm
{
public:
caldgemm_cpu();
virtual ~caldgemm_cpu();
private:
virtual int UseOutputPthreads();
virtual int UseInputPthreads();
virtual int UseMutexPerDevice();
virtual int DGEMM_prepare_backend(size_t k, int j, unsigned int num_device, bool prepareM, bool prepareN, bool buffersSufficiant, bool buffersSufficiant0 CALDGEMM_DIVBUFA);
virtual int Initialize (bool nocalinit);
virtual int ValidateRuntime();
virtual int CheckDevices();
virtual int InitDevices();
virtual int ReinitDevices();
virtual int InitConstantData(double alpha);
virtual int ExecuteKernels(caldgemm::DGEMMPrepareAndExecuteTask& Task, int blockm, int blockn);
virtual int ExitRuntime();
virtual int ExitDevices();
virtual int WaitForEvent(int, int, int);
virtual int FetchResult(int device, int j, int m, int n, int mustlock = 0);
virtual int CheckDMAQueue(int device, int forcej = -1);
virtual int RunMergeBuffers(double* dst, int device, int j, int width, int height, int gpu_width, int gpu_height, int pitch);
};
#endif