📄 filecache.h
字号:
/* <LIC_AMD_STD> * Copyright (c) 2005 Advanced Micro Devices, Inc. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program 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 General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * * The full GNU General Public License is included in this distribution in the * file called COPYING * </LIC_AMD_STD> *//* <CTL_AMD_STD> * </CTL_AMD_STD> *//* <DOC_AMD_STD> * </DOC_AMD_STD> */#ifndef _FILECACHE_H_#define _FILECACHE_H_#include <stdio.h>#ifndef CFUNC# define CFUNC#endif#if defined(OS_Linux_HACK)# include <zlib.h># define fopen gzopen# define fclose gzclose# define fprintf gzprintftypedef gzFile CachedFILE;#elsetypedef FILE *CachedFILE;#endifextern CFUNC void CriticalSectionInit();extern CFUNC void CriticalSectionExit();// A File Cache interface. The cache keeps a bunch of files open by// name. It does not close the files until it needs to reuse the cache entry.// This works really well for the MAE instrumentation that writes output for// each macro block to a handful of different files. Without the cache, it// closes (causing flush) each file for each macro block. With the cache, the// system overhead goes way down.extern CFUNC CachedFILE FileCacheGet(const char*);extern CFUNC void FileCacheDone(CachedFILE);#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -