From: CRDGW2::CRDGW2::MRGATE::"SMTP::CRVAX.SRI.COM::RELAY-INFO-VAX" 7-DEC-1989 03:26 To: MRGATE::"ARISIA::EVERHART" Subj: $SETIMR, ASTs and 16(AP) Message-Id: <8912070825.AA13786@crdgw1.ge.com> Received: From CUNYVM.CUNY.EDU by CRVAX.SRI.COM with TCP; Thu, 7 DEC 89 00:00:54 PDT Received: from NAUVAX.BITNET by CUNYVM.CUNY.EDU (IBM VM SMTP R1.2.2MX) with BSMTP id 6818; Thu, 07 Dec 89 02:57:59 EDT Date: Wed, 6 Dec 89 13:51 MST From: (Anthony C. McCracken) Subject: $SETIMR, ASTs and 16(AP) To: INFO-VAX@SRI.COM X-Original-To: INFO-VAX@SRI.COM, ACM Someone wrote earlier that while in an AST routine, the VMS documentation says that 16(AP) holds the address that the MAIN program was at when the AST interupt was called. I tried a small test and sure enough, the VMS documentation is CORRECT. Transcript follows. $ CREATE FOO.MAR .TITLE FOO .IDENT /V1.0/ .PSECT VDATA,RD,WRT,NOEXE DELAY: .LONG 1000*100*100*5 * -1 ; EXACTLY 5 SECS. .LONG -1 .PSECT CODE,RD,NOWRT,EXE .ENTRY MAIN,^M<> $SETIMR_S DAYTIM=DELAY,ASTADR=TIMEAST LOOP: MOVL R8,R9 ; here is a LOOP1: MOVL R10,R8 ; real dumb LOOP2: MOVL R9,R10 ; do nothing loop LOOP3: BRB LOOP ; while waiting for the AST RET TIMEAST: .WORD ^X07FC ; entry mask, the hard way BK: MOVL #1,R0 $EXIT_S R0 RET .END MAIN ^Z $ MACRO/DEBUG FOO $ LINK/DEBUG FOO $ RUN FOO VAX DEBUG Version V5.0-00 MP %DEBUG-I-INITIAL, language is MACRO, module set to FOO DBG> SET BREAK BK DBG> GO break at FOO\TIMEAST\BK 18: BK: MOVL #1,R0 DBG> EXAMINE @AP+10 7FF2177C: 0000041F DBG> SYMBOLIZE 41F address 0000041F: FOO\MAIN\LOOP2 FOO\MAIN\%LINE 13 address 0000041F: (global) MAIN+1F DBG> EXIT Looks like my little program was interupted at LOOP2: MOVL R9,R10 according to the address/value at AP+10. In MACRO, the debuggers default radix is hex. 10hex = 16decimal ************************************************************************** Disclaimer: There can't be a problem, | Anthony C. McCracken it works fine for me !! | Northern Arizona University | ACM@NAUVAX.BitNet **************************************************************************