Partager via


JsGetRuntimeMemoryUsage Function

Gets the current memory usage for a runtime.

Syntax

STDAPI_(JsErrorCode) JsGetRuntimeMemoryUsage(  
   _In_ JsRuntimeHandle runtime,  
   _Out_ size_t *memoryUsage  
);  

Parameters

runtime
The runtime whose memory usage is to be retrieved.

memoryUsage
The runtime's current memory usage, in bytes.

Return Value

The code JsNoError if the operation succeeded, a failure code otherwise.

Remarks

Memory usage can be always be retrieved, regardless of whether or not the runtime is active on another thread.

Requirements

Header: jsrt.h

See Also

Reference (JavaScript Runtime)