Mail Archives: djgpp/1997/05/06/03:40:55
nikki wrote:
>
> true, but it gives no clue as to why it failed. surely when you have 120 meg
> of virtual memory it's no big deal to ask for 9meg of that? and even on a 16meg
> machine there should be that amount of real memory. is it perhaps better to
> ask for it in smaller chunks rather than as one contiguous block? i just fail
> to understand why it could fail when it had so much available to it.
I have no idea why this could be happening if you really do have that
much memory. Certainly, _go32_dpmi_remaining_virtual_memory() isn't
going to help you solve it. ;) Hmm... well, here are some
possibilities:
- You're running your program under Win95 with a low DPMI memory
allocation for DOS programs. Edit the DOS box properties sheet and
increase the DPMI memory setting (you can type in up to 65535k).
- You're losing a large amount of memory due to malloc()'s internal
rounding. malloc() rounds all memory requests to the next higher power
of 2, meaning that if you ask for five 9 megabyte blocks, you'll really
be getting five 16 meg blocks.
- You're running under a crippled DPMI host like QDPMI from QEMM v7.52
or earlier, which had known problems with virtual memory.
- You're using the PMODE extender, which does not support virtual
memory.
- You have turned off the use of virtual memory in your program by
setting the _CRT0_FLAG_LOCK_MEMORY flag or using cwsdpr0 as your DPMI
host.
--
---------------------------------------------------------------------
| John M. Aldrich, aka Fighteer I | mailto:fighteer AT cs DOT com |
| Descent 2: The Infinite Abyss - The greatest Internet game of all |
| time just got better! This time, you're going all the way down...|
---------------------------------------------------------------------
- Raw text -