Trailing-Edge
-
PDP-10 Archives
-
BB-P363B-SM_1985
-
mcb/mcbda/mdatas.bli
There is 1 other file named mdatas.bli in the archive. Click here to see a list.
MODULE TASK ( !Display task memory.
IDENT = '003010',
LANGUAGE (BLISS16, BLISS36)
) =
BEGIN
!
! COPYRIGHT (c) 1980, 1981, 1982
! DIGITAL EQUIPMENT CORPORATION
! Maynard, Massachusetts
!
! This software is furnished under a license and may be used
! and copied only in accordance with the terms of such license
! and with the inclusion of the above copyright notice. This
! software or any other copies thereof may not be provided or
! otherwise made available to any other person. No title to
! and ownership of the software is hereby transferred.
!
! The information in this software is subject to change
! without notice and should not be construed as a commitment
! by DIGITAL EQUIPMENT CORPORATION.
!
! DIGITAL assumes no responsibility for the use or reliability
! of its software on equipment which is not supplied by
! DIGITAL.
!
!++
! FACILITY: MCBDA - MCB Dump Analyzer
!
! ABSTRACT:
!
! Display the task image for given TCB.
!
! ENVIRONMENT: ANY
!
! AUTHOR: ALAN D. PECKHAM , CREATION DATE: 19-SEP-78
!
! MODIFIED BY:
!
! Alan D. Peckham, 10-Jul-80: VERSION 3
! 01 - Update RSX symbol references.
!--
!
! TABLE OF CONTENTS:
!
FORWARD ROUTINE
TASK : NOVALUE; !Dump a task.
!
! INCLUDE FILES:
!
LIBRARY 'MDACOM'; !MDA common definitions.
LIBRARY 'RSXLIB'; !RSX definitions.
!
! MACROS:
!
!
! EQUATED SYMBOLS:
!
! None
!
! OWN STORAGE:
!
!
! EXTERNAL REFERENCES:
!
EXTERNAL ROUTINE
GETBYT, !Get a byte from the dump file.
GETWRD, !Get a word from the dump file.
PUTWND : NOVALUE, !Display the window blocks.
PHYAD : NOVALUE, !Display an 18 bit address.
MEMDMP : NOVALUE, !Display a window into memory.
SKIP : NOVALUE, !Put a blank line on the listing file.
SBTTL : NOVALUE; !Set the listing sub-title.
GLOBAL ROUTINE TASK (TASK_NAME) : NOVALUE =
!++
! FUNCTIONAL DESCRIPTION:
!
!
! FORMAL PARAMETERS:
!
! NONE
!
! IMPLICIT INPUTS:
!
! NONE
!
! IMPLICIT OUTPUTS:
!
! NONE
!
! ROUTINE VALUE:
!
! NONE
!
! SIDE EFFECTS:
!
! NONE
!
!--
BEGIN
MAP
TASK_NAME : REF VECTOR [2];
LOCAL
ENTRY_COUNT,
TCB_ADDRESS;
BIND
NAME_0 = .TASK_NAME [0],
NAME_1 = .TASK_NAME [1];
SBTTL (CH$ASCIZ ('TASK DUMP'));
IF NOT SYMBOL_TABLE ('RSX11S') THEN RETURN;
ENTRY_COUNT = RSX_MAX_STD;
TCB_ADDRESS = SYMBOL ($TSKHD) - FL$OFFSET (T_TCBL);
WHILE GETWRD ((TCB_ADDRESS = GETWRD (.TCB_ADDRESS + FL$OFFSET (T_TCBL))) + FL$OFFSET (T_TCBL)) NEQ 0 DO
BEGIN
IF (ENTRY_COUNT = .ENTRY_COUNT - 1) LSS 0
THEN
RETURN PUTLN (1,
CH$ASCIZ (WARNING,
'TCB LIST TOO LONG'));
IF GETWRD (.TCB_ADDRESS + FL$OFFSET (T_NAM) + 0) EQL NAME_0 AND GETWRD (.TCB_ADDRESS + FL$OFFSET (
T_NAM) + 2) EQL NAME_1
THEN
BEGIN
IF NOT FL$SET (GETWRD (.TCB_ADDRESS + FL$OFFSET (T_STAT)), TS_OUT)
THEN
BEGIN
LOCAL
HEADER,
WINDOW_BLK_ADR,
NUM_WINDOWS,
WINDOW_NUM;
HEADER = GETWRD (GETWRD (.TCB_ADDRESS + FL$OFFSET (T_PCB)) + SYMBOL ('P.HDR'));
PUTLN (3, CH$ASCIZ ('%29STASK DUMP OF %2R'), NAME_0, NAME_1);
PUTLN (0, CH$ASCIZ ('%29S-------------------'));
PUTLN (2, CH$ASCIZ ('%14STCB ADDRESS = %P HEADER ADDRESS = %P'), .TCB_ADDRESS, .HEADER);
PUTWND (2, .HEADER);
WINDOW_BLK_ADR = GETWRD (.HEADER + FL$OFFSET (H_WND)) + 2;
IF (.WINDOW_BLK_ADR NEQ 2) AND ((NUM_WINDOWS = MINU (GETWRD (.WINDOW_BLK_ADR - 2),
RSX_MAX_WND)) NEQ 0)
THEN
INCR WINDOW_NUM FROM 1 TO .NUM_WINDOWS DO
BEGIN
LOCAL
PCB_ADDRESS;
IF (PCB_ADDRESS = GETWRD (.WINDOW_BLK_ADR + FL$OFFSET (W_BPCB))) NEQ 0
THEN
BEGIN
LOCAL
WBLVR,
WBHVR,
BIAS,
SIZE,
VIRTUAL_ADDRESS : VECTOR [2],
LOW_PHYSICAL : VECTOR [2],
HIGH_PHYSICAL : VECTOR [2];
WBLVR = GETWRD (.WINDOW_BLK_ADR + FL$OFFSET (W_BLVR));
WBHVR = GETWRD (.WINDOW_BLK_ADR + FL$OFFSET (W_BHVR));
PUTLN (2, CH$ASCIZ ('%4SWINDOW #%D -- TASK VIRTUAL LIMITS %P-%P'), .WINDOW_NUM,
.WBLVR, .WBHVR);
PUTLN (0, CH$ASCIZ ('%4S----------------------------------------------'));
VIRTUAL_ADDRESS [0] = 0;
VIRTUAL_ADDRESS [1] = .WBLVR;
BIAS = GETWRD (.PCB_ADDRESS + FL$OFFSET (P_REL)) + GETWRD (.WINDOW_BLK_ADR +
FL$OFFSET (W_BOFF));
LOW_PHYSICAL [0] = .BIAS<10, 2>;
LOW_PHYSICAL [1] = .BIAS<0, 10>^6;
BIAS = .BIAS + (SIZE = .WBHVR - .WBLVR)^-6;
HIGH_PHYSICAL [0] = .BIAS<10, 2>;
HIGH_PHYSICAL [1] = .BIAS<0, 10>^6 + .SIZE<0, 6>;
PUTLN (1, CH$ASCIZ ('%6SPHYSICAL STARTING ADDRESS = %@'), PHYAD, LOW_PHYSICAL);
PUTLN (0, CH$ASCIZ ('%6S----------------------------------'));
SKIP (2);
MEMDMP (VIRTUAL_ADDRESS, LOW_PHYSICAL, HIGH_PHYSICAL);
END;
WINDOW_BLK_ADR = .WINDOW_BLK_ADR + W_BLGH^1;
END;
END
ELSE
PUTLN (5, CH$ASCIZ ('%6S> > > > > TASK "%2R" NOT IN MEMORY'), NAME_0, NAME_1);
EXITLOOP;
END;
END;
END; !End of TASK
END !End of module
ELUDOM