GDSX (Extended General Device Support) Manual

Service Routines
Extended General Device Support (GDSX) Manual529931-001
8-33
GETEXTPOOLX
WDS := 100;
@GLOBAL^SHARED^PTR := GETEXTPOOL(1, WDS);
GLOBAL^SHARED^PTR ':=' "+ Let all tasks see this !+";
END;
.
END; ! of USER^START;
PROC DEVICE^HANDLER(.......);
INT .EXT WORK^PTR;
INT WDS, N;
.
.
@WORK^PTR := @GLOBAL^SHARED^PTR;
IF WORK^PTR = "+" THEN !All user tasks can see
!this data
BEGIN
WORK^PTR ':=' " "; !Spaces on first time thru
!Allocate a second buffer of 100 words.
@TASK^SHARED^PTR := GETEXTPOOL(1, 100);
TASK^SHARED^PTR ':=' "5";
.
.
END
ELSE
BEGIN !We are not the first D^H task to be created
@WORK^PTR := @TASK^SHARED^PTR;
IF WORK^PTR = "5" THEN
BEGIN
.
.
CALL PUTEXTPOOL(1, @WORK^PTR);
GETEXTPOOLX
This procedure allocates extended memory pool space for the calling task. Unlike
GETEXTPOOL, GETEXTPOOLX can be used for allocating more than 64 KB of
memory space. The upper limit for the configuration parameters MAXCPSIZE and
TASKCPSIZE is increased to 65000 to support checkpointing of pools larger than
64KB size. The upper limit for the configuration parameters POOLSIZE and
TASKPOOLSIZE is set to 65000.
For more information, see Memory Pools on page 2-24.
address returned value
INT .EXT:value
address := GETEXTPOOLX ( pool !
i
,size ) ; !
i