Int 12h Report Memory Size
Reports the number of contiguous 1K memory blocks in the system
(up to 640K).
Entry No parameters
Return AX = Memory size (up to 640K)
──────────────────────────────────────────────────────────────────
This service determines memory by either examining the DIP
switches on the system board or using the value stored in the CMOS
battery, depending on the type of machine.
The value returned in AX is the same as that stored at memory
location 0040h:0013h, which is initialized during the power-up
tests.
This is the amount of memory available to the entire system. This
is not the amount of memory available to the user's program. Use
Int 21h, function 48h, to determine the amount of memory available
to a user's program.
To determine the amount of memory above the 1024K address range,
use Int 15h, Service 88h.
If the CMOS battery memory value or the DIP switch value is
greater than the actual amount of memory, then the actual amount
of memory is returned by this interrupt.