include/SDL_cpuinfo.h
author Ozkan Sezer <sezeroz@gmail.com>
Thu, 10 May 2018 08:47:00 +0300
branchSDL-1.2
changeset 11979 d684a767e240
parent 6137 4720145f848b
permissions -rw-r--r--
backport fixes for bug #4159
slouken@739
     1
/*
slouken@739
     2
    SDL - Simple DirectMedia Layer
slouken@6137
     3
    Copyright (C) 1997-2012 Sam Lantinga
slouken@739
     4
slouken@739
     5
    This library is free software; you can redistribute it and/or
slouken@1312
     6
    modify it under the terms of the GNU Lesser General Public
slouken@739
     7
    License as published by the Free Software Foundation; either
slouken@1312
     8
    version 2.1 of the License, or (at your option) any later version.
slouken@739
     9
slouken@739
    10
    This library is distributed in the hope that it will be useful,
slouken@739
    11
    but WITHOUT ANY WARRANTY; without even the implied warranty of
slouken@739
    12
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
slouken@1312
    13
    Lesser General Public License for more details.
slouken@739
    14
slouken@1312
    15
    You should have received a copy of the GNU Lesser General Public
slouken@1312
    16
    License along with this library; if not, write to the Free Software
slouken@1312
    17
    Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
slouken@739
    18
slouken@739
    19
    Sam Lantinga
slouken@739
    20
    slouken@libsdl.org
slouken@739
    21
*/
slouken@739
    22
slouken@4217
    23
/**
slouken@4217
    24
 *  @file SDL_cpuinfo.h
slouken@4217
    25
 *  CPU feature detection for SDL
slouken@4217
    26
 */
slouken@739
    27
slouken@739
    28
#ifndef _SDL_cpuinfo_h
slouken@739
    29
#define _SDL_cpuinfo_h
slouken@739
    30
slouken@1402
    31
#include "SDL_stdinc.h"
slouken@1402
    32
slouken@739
    33
#include "begin_code.h"
slouken@739
    34
/* Set up for C function definitions, even when using C++ */
slouken@739
    35
#ifdef __cplusplus
slouken@739
    36
extern "C" {
slouken@739
    37
#endif
slouken@739
    38
slouken@4217
    39
/** This function returns true if the CPU has the RDTSC instruction */
slouken@1426
    40
extern DECLSPEC SDL_bool SDLCALL SDL_HasRDTSC(void);
slouken@745
    41
slouken@4217
    42
/** This function returns true if the CPU has MMX features */
slouken@1426
    43
extern DECLSPEC SDL_bool SDLCALL SDL_HasMMX(void);
slouken@739
    44
slouken@4217
    45
/** This function returns true if the CPU has MMX Ext. features */
slouken@1426
    46
extern DECLSPEC SDL_bool SDLCALL SDL_HasMMXExt(void);
slouken@785
    47
slouken@4217
    48
/** This function returns true if the CPU has 3DNow features */
slouken@1426
    49
extern DECLSPEC SDL_bool SDLCALL SDL_Has3DNow(void);
slouken@739
    50
slouken@4217
    51
/** This function returns true if the CPU has 3DNow! Ext. features */
slouken@1426
    52
extern DECLSPEC SDL_bool SDLCALL SDL_Has3DNowExt(void);
slouken@785
    53
slouken@4217
    54
/** This function returns true if the CPU has SSE features */
slouken@1426
    55
extern DECLSPEC SDL_bool SDLCALL SDL_HasSSE(void);
slouken@739
    56
slouken@4217
    57
/** This function returns true if the CPU has SSE2 features */
slouken@1426
    58
extern DECLSPEC SDL_bool SDLCALL SDL_HasSSE2(void);
slouken@785
    59
slouken@4217
    60
/** This function returns true if the CPU has AltiVec features */
slouken@1426
    61
extern DECLSPEC SDL_bool SDLCALL SDL_HasAltiVec(void);
slouken@778
    62
slouken@739
    63
/* Ends C function definitions when using C++ */
slouken@739
    64
#ifdef __cplusplus
slouken@739
    65
}
slouken@739
    66
#endif
slouken@739
    67
#include "close_code.h"
slouken@739
    68
slouken@739
    69
#endif /* _SDL_cpuinfo_h */