Analyzer libc-mallinfo

Name

libc-mallinfo - Information about memory allocations performed by malloc and related functions

This analyzer retrieves detailed information about memory allocations performed by malloc and related functions through the mallinfo interface. It captures metrics including arena size, allocated bytes, free bytes, mmap usage, and fragmentation statistics. The analyzer presents this data in tabular format, providing insights into glibc memory allocator behavior and heap management efficiency. This is useful for diagnosing memory fragmentation issues and understanding the internal state of the memory allocator.

Resource Category

Memory.

Application Type & Technical Stack

  • All

Command Line Syntax

The analyzer can be invoked directly on the command-line via the orxray utility from the openresty-xray-cli software package.

Alternatively, the analyzer can also be invoked manually or automatically on the web console UI of OpenResty XRay (like on the Advanced web page).

# PID is the target process PID.
orxray analyzer run libc-mallinfo -p PID

# trace a shell command directly
orxray analyzer run libc-mallinfo -c SHELL_CMD

Tracing Multiple Processes

Not supported.

Output Formats

  • Tables
  • Plain Texts

Author

The OpenResty Inc. Team.

Copyright (C) by OpenResty Inc. All rights reserved.