mem: report DPMI memory - #133
Conversation
Show total, used and free DPMI memory and the largest free DPMI block (int 31h AX=0500h), as separate lines under EMS rather than as a row of the table: depending on the host, DPMI memory is either taken from XMS or is a pool of its own, so adding it to the totals could count it twice. Fields the host reports as -1 are skipped. This makes memory held by the shell itself visible: under dosemu2 the stub's DPMI loader keeps a 16Mb heap for the whole session, which shows up as ~19Mb used before any program is run. Co-Authored-By: Claude <noreply@anthropic.com>
|
As a result, Cause: djdev64 is packaged with The fix belongs in djdev64 packaging (e.g. |
|
Why rebuild dosemu2? |
|
Because the The one way to avoid touching dosemu2 is to make djdev64's version sort above 0.5, e.g. |
|
Thanks! |
Before:
memsaid nothing about DPMI memory. So there was no way to see that the shell already holds about 19 MB of the DPMI pool before any program runs.After: under the EMS lines,
memprints the total, used and free DPMI memory and the largest free DPMI block:That output is from dosemu2 with the current stub. The stub's SmallerC DPMI loader keeps its default 16 MB
-maxheapfor the whole session. When the same comcom64 is relinked with a stub built with-maxheap 0x80000,Used DPMI memorydrops to 3,320K.How: the numbers come from
__dpmi_get_free_memory_information()(int 31h AX=0500h). A field the host reports as -1 is skipped. These are separate lines, not a table row. Some hosts take DPMI memory out of XMS and others (dosemu2) keep a separate pool, so adding it to the totals could count the same memory twice. The labels don't collide with the onestest/func_comcom_internal.pyin dosemu2 parses.🤖 Generated with Claude Code