Skip to content

Instantly share code, notes, and snippets.

View j1elo's full-sized avatar

Juan Navarro j1elo

View GitHub Profile
@j1elo
j1elo / 00-README.md
Created February 9, 2021 10:03 — forked from tdryer/00-README.md
How Linux approximates memory metrics

How Linux approximates memory metrics

Example

The program threads-memory.c (included below) starts 100 threads, allocates 1 MB of memory in each, and then pauses. How much memory is it using?

Let's find out by running it:

$ gcc -pthread threads-memory.c -o threads-memory