1 /***********************************************************************/ 2 /* Open Visualization Data Explorer */ 3 /* (C) Copyright IBM Corp. 1989,1999 */ 4 /* ALL RIGHTS RESERVED */ 5 /* This code licensed under the */ 6 /* "IBM PUBLIC LICENSE - Open Visualization Data Explorer" */ 7 /***********************************************************************/ 8 9 #include <dxconfig.h> 10 11 12 #ifndef tdmMemory_h 13 #define tdmMemory_h 14 /* 15 * 16 * $Header: /src/master/dx/src/exec/hwrender/hwMemory.h,v 1.4 2002/03/21 02:59:11 rhh Exp $ 17 */ 18 19 20 #ifdef TDM_MEMORY_TRACING 21 22 #ifndef PREPROC 23 #define _LINE_ __LINE__ 24 #endif 25 26 Pointer _tdmAllocate(unsigned int n, char * file, int LINE); 27 Pointer _tdmAllocateZero(unsigned int n, char * file, int LINE); 28 Pointer _tdmAllocateLocal(unsigned int n, char * file, int LINE); 29 Pointer _tdmAllocateLocalZero(unsigned int n, char * file, int LINE); 30 Pointer _tdmReAllocate(Pointer x, unsigned int n, char * file, int LINE); 31 Error _tdmFree(Pointer x, char * file, int LINE); 32 Error _tdmCheckAllocTable(int); 33 34 #define tdmAllocate(n) _tdmAllocate(n,__FILE__,_LINE_) 35 #define tdmAllocateZero(n) _tdmAllocateZero(n,__FILE__,_LINE_) 36 #define tdmAllocateLocal(n) _tdmAllocateLocal(n,__FILE__,_LINE_) 37 #define tdmAllocateLocalZero(n) _tdmAllocateLocalZero(n,__FILE__,_LINE_) 38 #define tdmReAllocate(x,n) _tdmReAllocate(x,n,__FILE__,_LINE_) 39 #define tdmFree(x) _tdmFree(x,__FILE__,_LINE_) 40 #define tdmCheckAllocTable(flag) _tdmCheckAllocTable(flag) 41 42 43 #else 44 45 #define tdmAllocate(n) DXAllocate(n) 46 #define tdmAllocateZero(n) DXAllocateZero(n) 47 #define tdmAllocateLocal(n) DXAllocateLocal(n) 48 #define tdmAllocateLocalZero(n) DXAllocateLocalZero(n) 49 #define tdmReAllocate(x,n) DXReAllocate(x,n) 50 #define tdmFree(x) DXFree(x) 51 #define tdmCheckAllocTable(flag) 52 53 #endif 54 55 56 57 58 59 60 #endif 61