fpcmemdll.pp 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. {
  2. This file is part of the Free Pascal run time library.
  3. Copyright (c) 2006 by the Free Pascal development team.
  4. Shared memory manager
  5. See the file COPYING.FPC, included in this distribution,
  6. for details about the copyright.
  7. This program is distributed in the hope that it will be useful,
  8. but WITHOUT ANY WARRANTY; without even the implied warranty of
  9. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  10. **********************************************************************}
  11. {$mode objfpc}
  12. library fpcmemdll;
  13. Function SysGetmem(Size:ptrint):Pointer;
  14. begin
  15. Result:=System.SysGetmem(Size);
  16. end;
  17. Function SysFreemem(p:pointer):ptrint;
  18. begin
  19. Result:=System.SysFreemem(p);
  20. end;
  21. Function SysFreememSize(p:pointer;Size:ptrint):ptrint;
  22. begin
  23. Result:=System.SysFreememSize(p,Size);
  24. end;
  25. Function SysAllocMem(size:ptrint):Pointer;
  26. begin
  27. Result:=System.SysAllocMem(Size);
  28. end;
  29. Function SysReAllocMem(var p:pointer;size:ptrint):Pointer;
  30. begin
  31. Result:=System.SysReallocMem(p,Size);
  32. end;
  33. Function SysMemSize(p:pointer):ptrint;
  34. begin
  35. Result:=System.SysMemSize(p);
  36. end;
  37. function SysGetHeapStatus:THeapStatus;
  38. begin
  39. Result:=System.SysGetHeapStatus;
  40. end;
  41. function SysGetFPCHeapStatus:TFPCHeapStatus;
  42. begin
  43. Result:=System.SysGetFPCHeapStatus;
  44. end;
  45. exports
  46. SysGetmem,
  47. SysFreemem,
  48. SysFreememSize,
  49. SysAllocMem,
  50. SysReAllocMem,
  51. SysMemSize,
  52. SysGetHeapStatus,
  53. SysGetFPCHeapStatus;
  54. begin
  55. end.