tarantool / tarantool/doc

Document `box.malloc.info()`

Open
#3,443 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

2.11
Dominant language
CSS
Stars
15
Forks
49
Avg merge
1d 13h
Merged PRs (30d)
3

Description

box.malloc.info() is a function that returns a table with two fields:

tarantool> box.malloc.info()
---
- size: 2498560
  used: 1835726
...

The used value is the total amount of memory in bytes allocated by
Tarantool for internal data structures with malloc().

The size value is the total amount of memory in bytes allocated from
the system by the malloc() allocator. It may not be less than used.

The function may be used before box.cfg() is called.

Currently, the function is available only on Linux. On other systems it
reports zero memory usage ({size = 0, used = 0}).

Requested by @locker in https://github.com/tarantool/tarantool/commit/d34a0cbce27f98c72340311ac2fed3ad9639f6cf.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start from the existing documentation entry point for box.malloc.info(), using the behavior described in this issue and the referenced commit for context. Document the returned size and used fields, availability before box.cfg(), and the zero-value behavior on non-Linux systems; done means these details are published in the appropriate API reference.

Written by the indexing model from the issue text.

Assessment

Domain
documentation
Issue type
Documentation
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.