ManaPlus
src
utils
cpu.h
Go to the documentation of this file.
1
/*
2
* The ManaPlus Client
3
* Copyright (C) 2013-2019 The ManaPlus Developers
4
* Copyright (C) 2019-2021 Andrei Karas
5
*
6
* This file is part of The ManaPlus Client.
7
*
8
* This program is free software; you can redistribute it and/or modify
9
* it under the terms of the GNU General Public License as published by
10
* the Free Software Foundation; either version 2 of the License, or
11
* any later version.
12
*
13
* This program is distributed in the hope that it will be useful,
14
* but WITHOUT ANY WARRANTY; without even the implied warranty of
15
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
* GNU General Public License for more details.
17
*
18
* You should have received a copy of the GNU General Public License
19
* along with this program. If not, see <http://www.gnu.org/licenses/>.
20
*/
21
22
#ifndef UTILS_CPU_H
23
#define UTILS_CPU_H
24
25
#include "
localconsts.h
"
26
27
namespace
Cpu
28
{
29
enum
30
{
31
FEATURE_EMPTY
= 0,
32
FEATURE_MMX
= 1,
33
FEATURE_SSE
= 2,
34
FEATURE_SSE2
= 4,
35
FEATURE_SSSE3
= 8,
36
FEATURE_SSE4
= 16,
37
FEATURE_SSE42
= 32,
38
FEATURE_AVX
= 64,
39
FEATURE_AVX2
= 128
40
};
41
42
void
detect
();
43
44
void
printFlags
();
45
46
uint32_t
getFlags
();
47
}
// namespace Cpu
48
49
#endif
// UTILS_CPU_H
localconsts.h
Cpu
Definition:
cpu.h:28
Cpu::getFlags
uint32_t getFlags()
Definition:
cpu.cpp:176
Cpu::FEATURE_SSE42
@ FEATURE_SSE42
Definition:
cpu.h:37
Cpu::FEATURE_MMX
@ FEATURE_MMX
Definition:
cpu.h:32
Cpu::FEATURE_AVX
@ FEATURE_AVX
Definition:
cpu.h:38
Cpu::FEATURE_SSE
@ FEATURE_SSE
Definition:
cpu.h:33
Cpu::FEATURE_AVX2
@ FEATURE_AVX2
Definition:
cpu.h:39
Cpu::FEATURE_SSE2
@ FEATURE_SSE2
Definition:
cpu.h:34
Cpu::FEATURE_SSE4
@ FEATURE_SSE4
Definition:
cpu.h:36
Cpu::FEATURE_SSSE3
@ FEATURE_SSSE3
Definition:
cpu.h:35
Cpu::FEATURE_EMPTY
@ FEATURE_EMPTY
Definition:
cpu.h:31
Cpu::printFlags
void printFlags()
Definition:
cpu.cpp:152
Cpu::detect
void detect()
Definition:
cpu.cpp:46
Generated on Wed Mar 17 2021 19:19:10 for ManaPlus by
1.9.1