Why is less memory shown inside of my Boxes virtual machine than was allocated?

I was doing some measurements on RAM consumed by different window managers and desktop environments. I allocated a small amount of RAM (that’s important because when RAM amount is large OS loads unnecessary modules). Reading btop measurements I was sure that this amount was 715 MiB and was ready to put that info to the data of my research, but later I opened WM settings and it showed that 768 MiB was allocated.


When I created other virtual machines for other operating systems I allocated exactly 715 MiB, but the system tools (this time “TinyCore System Stats”) show only 713 MiB total being availible (I remember on one machine 715 was down to around 680).

Why is total RAM differ in different sources? What number is used by the OS when it allocates resources and is relevant to the research?

Becuase some memory is needed by the BIOS.
If you look at the dmesg output you can see logs describing the memory usage at boot.

For example from one of VMs, for example:

[    0.000000] BIOS-provided physical RAM map:
[    0.000000] BIOS-e820: [mem 0x0000000000000000-0x000000000002ffff] usable
[    0.000000] BIOS-e820: [mem 0x0000000000030000-0x000000000004ffff] reserved
[    0.000000] BIOS-e820: [mem 0x0000000000050000-0x000000000009efff] usable
[    0.000000] BIOS-e820: [mem 0x000000000009f000-0x000000000009ffff] reserved
[    0.000000] BIOS-e820: [mem 0x0000000000100000-0x000000007e8ecfff] usable
[    0.000000] BIOS-e820: [mem 0x000000007e8ed000-0x000000007eb6cfff] reserved
[    0.000000] BIOS-e820: [mem 0x000000007eb6d000-0x000000007eb7efff] ACPI data
[    0.000000] BIOS-e820: [mem 0x000000007eb7f000-0x000000007ebfefff] ACPI NVS
[    0.000000] BIOS-e820: [mem 0x000000007ebff000-0x000000007effffff] usable
[    0.000000] BIOS-e820: [mem 0x000000007f000000-0x000000007fffffff] reserved
[    0.000000] BIOS-e820: [mem 0x00000000e0000000-0x00000000efffffff] reserved
[    0.000000] BIOS-e820: [mem 0x00000000feffc000-0x00000000feffffff] reserved
[    0.000000] BIOS-e820: [mem 0x0000000100000000-0x000000017fffffff] usable

The reserved memory is not usage by the linux kernel.