comrogue-pi/idl/comrogue/allocator.idl
Eric J. Bowersox 983d6f7f31 added some extra interfaces for heap support, and the code structures defined
in the IDL files necessitated some refinements to the PIDL parser and code
generator
2013-05-07 02:42:36 -06:00

43 lines
1.3 KiB
Plaintext

import "comrogue/objectbase.idl";
/*-------------------
* IMalloc interface
*-------------------
*/
[object, uuid(00000002-0000-0000-C000-000000000046)]
interface IMalloc : IUnknown
{
[unique] typedef IMalloc *PMALLOC;
PVOID Alloc([in] SIZE_T cb);
PVOID Realloc([in] PVOID pv, [in] SIZE_T cb);
void Free([in] PVOID pv);
SIZE_T GetSize([in] PVOID pv);
INT32 DidAlloc([in] PVOID pv);
void HeapMinimize(void);
}
/*----------------------
* IMallocSpy interface
*----------------------
*/
[object, uuid(0000001d-0000-0000-C000-000000000046)]
interface IMallocSpy: IUnknown
{
[unique] typedef IMallocSpy *PMALLOCSPY;
SIZE_T PreAlloc([in] SIZE_T cbRequest);
PVOID PostAlloc([in] PVOID pActual);
PVOID PreFree([in] PVOID pRequest, [in] BOOL fSpyed);
void PostFree([in] BOOL fSpyed);
SIZE_T PreRealloc([in] PVOID pRequest, [in] SIZE_T cbRequest, [out] PVOID *ppNewRequest, [in] BOOL fSpyed);
PVOID PostRealloc([in] PVOID pActual, [in] BOOL fSpyed);
PVOID PreGetSize([in] PVOID pRequest, [in] BOOL fSpyed);
SIZE_T PostGetSize([in] SIZE_T cbActual, [in] BOOL fSpyed);
PVOID PreDidAlloc([in] PVOID pRequest, [in] BOOL fSpyed);
INT32 PostDidAlloc([in] PVOID pRequest, [in] BOOL fSpyed, [in] INT32 fActual);
void PreHeapMinimize(void);
void PostHeapMinimize(void);
}