00001 /***************************************************************************** 00002 00003 Copyright (C) 1995, 2009, Innobase Oy. All Rights Reserved. 00004 00005 This program is free software; you can redistribute it and/or modify it under 00006 the terms of the GNU General Public License as published by the Free Software 00007 Foundation; version 2 of the License. 00008 00009 This program is distributed in the hope that it will be useful, but WITHOUT 00010 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS 00011 FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. 00012 00013 You should have received a copy of the GNU General Public License along with 00014 this program; if not, write to the Free Software Foundation, Inc., 51 Franklin 00015 St, Fifth Floor, Boston, MA 02110-1301 USA 00016 00017 *****************************************************************************/ 00018 00019 /**************************************************/ 00027 #pragma once 00028 #ifndef os0proc_h 00029 #define os0proc_h 00030 00031 #include "univ.i" 00032 00033 #ifdef UNIV_LINUX 00034 #include <sys/ipc.h> 00035 #include <sys/shm.h> 00036 #endif 00037 00038 typedef void* os_process_t; 00039 typedef unsigned long int os_process_id_t; 00040 00041 extern ibool os_use_large_pages; 00042 /* Large page size. This may be a boot-time option on some platforms */ 00043 extern ulint os_large_page_size; 00044 00045 /****************************************************************/ 00051 UNIV_INTERN 00052 ulint 00053 os_proc_get_number(void); 00054 /*====================*/ 00055 /****************************************************************/ 00058 UNIV_INTERN 00059 void* 00060 os_mem_alloc_large( 00061 /*===============*/ 00062 ulint* n); 00063 /****************************************************************/ 00065 UNIV_INTERN 00066 void 00067 os_mem_free_large( 00068 /*==============*/ 00069 void *ptr, 00071 ulint size); 00074 #ifndef UNIV_NONINL 00075 #include "os0proc.ic" 00076 #endif 00077 00078 #endif