| TIP: Click on subject to list as thread! | ANSI |
| echo: | |
|---|---|
| to: | |
| from: | |
| date: | |
| subject: | Toolkit 1.3 from Devcon |
Hello Mike,
On May 29 16:07 96, Mike Bilow of 1:323/107 wrote:
MB> I can assure you that OS/2 does not even allocate address
MB> space when such allocations are requested. You can watch
MB> this inside a device driver, and you see that the segment
MB> limits are set to the actual allocated amount in the
MB> descriptor table. I have never seen different behavior
MB> under any version of OS/2.
PLEASE:
DosAllocMem(&p1,1,READ/WRITE)
DosAllocMEm(&p2,1,READ/WRITE)
p2-p1 == 64K
2) look at theseue/2, lookt at OS/2 memu ... whatever you want, look into
the new (DevCon9, DevCon10) toolkit docs : OS/2 ALLOCATES 64K address space
AT LEAST on every allocation!
here is a sample program (which also commits the memory) and OS/2 memu and
THESEUE/2 traces (theseus/2 traces the internal memory tables):
==============
#define INCL_DOS
#include
#include
#include
main(int argc, char *argv[], char *envp[])
{
APIRET rc;
PVOID pvBase;
rc = DosAllocMem(&pvBase, 1, PAG_COMMIT|PAG_READ|PAG_WRITE);
if( !rc )
*((PCHAR)pvBase) = '\0';
printf("%p / rc=%d\n",pvBase,rc);
rc = DosAllocMem(&pvBase, 1, PAG_COMMIT|PAG_READ|PAG_WRITE);
if( !rc )
*((PCHAR)pvBase) = '\0';
printf("%p / rc=%d\n",pvBase,rc);
rc = DosAllocMem(&pvBase, 1, PAG_COMMIT|PAG_READ|PAG_WRITE);
if( !rc )
*((PCHAR)pvBase) = '\0';
printf("%p / rc=%d\n",pvBase,rc);
getch();
return 0;
}
==============
icc Test.c
E0000 / rc=0
F0000 / rc=0
1C0000 / rc=0
OS20MEMU.EXE: (WARP connect)
Details: ||
Linear Shared Maximum In Swapped Not Created
Address / Priv. Size Memory / Disc. Accessed By
ÄÄÄÄÄÄÄÄ ÄÄÄÄÄÄÄ ÄÄÄÄÄÄÄ ÄÄÄÄÄÄÄ ÄÄÄÄÄÄÄ ÄÄÄÄÄÄÄÄ ÄÄÄÄÄÄÄ
e0000 Private 64 4 0 0 TEST
f0000 Private 64 4 0 0 TEST
1c0000 Private 64 4 0 0 TEST
WARP FP5 (and prior versions).
THESEUE/2:
Private Object Summary for 'TEST':
Object Allocated Committed Present Swapped
address memory memory memory memory Description
00010000 00010000 00006000 00006000 00000000 TEST #0001 (shared code)
00020000 00010000 00001000 00001000 00000000 TEST #0002 (shared code)
00030000 00010000 00001000 00001000 00000000 TEST #0003 (shared code)
00040000 00010000 00001000 00001000 00000000 TEST #0004 (shared data)
00050000 00010000 00001000 00000000 00000000 TEST #0005 (private)
00060000 00010000 00009000 00003000 00000000 TEST #0006 (private)
00070000 00010000 00002000 00002000 00000000 User Environment (hmte)
00080000 00010000 00001000 00001000 00000000 Thread
Information Block (hmte)
00090000 00010000 00001000 00001000 00000000 stack (hmte [system owner])
000A0000 00010000 00010000 00004000 00000000 TEST allocated it
000B0000 00010000 00010000 00001000 00000000 TEST allocated it
000C0000 00010000 0000F000 00001000 00000000 DOSCALL1 allocated it
000D0000 00010000 00002000 00001000 00000000 TEST allocated it
>000E0000 00010000 00001000 00001000 00000000 TEST allocated it
000F0000 00010000 00000000 00000000 00000000 Device Driver 3
(hmte [system owner])
>00100000 00010000 00001000 00001000 00000000 TEST allocated it
>00110000 00010000 00001000 00001000 00000000 TEST allocated it
00120000 03EE0000 Free
-------- -------- -------- --------
Totals: 00110000 0004B000 0001A000 00000000 (in bytes)
1088 300 104 0 (in Kbytes)
1.063 0.293 0.102 0.000 (in Mbytes)
Number of objects = 17.
Analysis of 'Free' areas:
There are 1 free blocks which total 03EE0000 (64384K or 62.875M)
The largest 1 free areas are:
address size
00120000 03EE0000 (64384K or 62.875M)
WARP GA (OS/2 MEMU)
110000 / rc=0
120000 / rc=0
130000 / rc=0
-------- ------- ------- ------- ------- -------- -------
110000 Private 64 4 0 0 TEST
120000 Private 64 4 0 0 TEST
130000 Private 64 4 0 0 TEST
WARPED!, Mario
--- Msgedsq/2 2.2e
* Origin: LC/32 Development Team-Vienna-Austria (2:310/14.11)SEEN-BY: 50/99 270/101 620/243 711/401 409 410 413 430 808 809 934 955 SEEN-BY: 712/407 515 517 628 713/888 800/1 @PATH: 310/14 1 24/999 888 396/1 270/101 712/515 711/808 934 |
|
| SOURCE: echomail via fidonet.ozzmosis.com | |
Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.