DataMuseum.dkPresents historical artifacts from the history of: Rational R1000/400 Tapes |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about Rational R1000/400 Tapes Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - downloadIndex: ┃ P T ┃
Length: 21138 (0x5292) Types: TextFile Names: »PEAB_INTERPROGRAM_COMMUNICATION_LIST«
└─⟦afbc8121e⟧ Bits:30000532 8mm tape, Rational 1000, MC68020_OS2000 7_2_2 └─ ⟦77aa8350c⟧ »DATA« └─⟦f794ecd1d⟧ └─⟦24d1ddd49⟧ └─⟦this⟧
;============================================================================= ; Copyright (C) 1989 PHILIPS ELEKTRONIKINDUSTRIER AB , SWEDEN 3.0 ;============================================================================= ; ; ; UNIT NAME : ; PEAB_INTERPROGRAM_COMMUNICATION_ASM ; ; KEYWORDS ; IPCO ; ; CONTENTS ; ; Creation information: ; ; CI-Element-Id : 15/SOURCE-100132 ; Programmer : CURT STR\M/CUST ; Creation date : 1989-01-02 ; Department : DGG ; Project : BS2000 ; ; Revision history: ; 1.0/CUST/1989-01-02/First release ; ; Unit function: ; Support for Ada runtime. IPC-specific operations required by ART ; to handle IPC messages in rendezvous. The actual code is contained ; in OS2000 and this unit is just the interface. ; ; N.B. This unit is ONLY referenced by ART and is logically an ; extension of ART. ; ; Dependencies: ; MC68020/OS2000/CDF ; ; Improvements: ; No suggestions ; ;============================================================================= .module "PEAB_INTERPROGRAM_COMMUNICATION_ASM" .gbl.l __ipc_handle_protocol .gbl.l __ipc_release_buffer .gbl.l __ipc_evacuate_queue ; ; Miscellaneous definitions ; cct_start equ 16#400# a32_size equ 16#0200_0000# ; ; CCT offsets ; pi_cpt equ 88 ; ; CPT offsets ; os2000svcptr equ 72 ; ; OS2000 svc offsets ; ipc$handle_protocol equ 79 ipc$release_buffer equ 80 ipc$evacuate_queue equ 81 ;------------------------------------------------------------------- ; General parameter offsets in stack ; P1 is the first parameter in the list, P2 is the second and so on. ; Link A6,xx is supposed to have been performed and the offsets ; are valid from the resulting A6 frame pointer. P1 equ 8 P2 equ P1+4 P3 equ P2+4 P4 equ P3+4 P5 equ P4+4 P6 equ P5+4 ;------------------------------------------------------------------------ .sect ada_code,code,relocatable,alignment:=2 ;---------------------------------------------------------------- ; ; Macro _$setup_svc_in_a1 ; ; Set up a1 to point to the svc table ; ; Destroys: d1 ; ;---------------------------------------------------------------- .macro setup_svc_in_a1 move.l sp,d1 andi.l #(-a32_size),d1 movea.l ([cct_start+pi_cpt,d1.l],os2000svcptr),a1 ;a1 -> svc .endmacro ;------------------------------------------------------------------------ ; ; procedure Handle_Protocol (Buffer : in out Buffer_Address; P1 ; Slot_Data : in Message_Slot_Data; P2 ; Queue_Data : in Associated_Data; P3 ; Parameters : out Parameter_Address; P4 ; Ignore_Message : out Boolean); P5 ; ; Shared C interface: ; ; status IPC$Handle_Protocol (Buffer,Slot_Data,Queue_Data,Parameters) ; ; uchar **Buffer; /* in out Pointer to buffer address d0 */ ; ulong Slot_Data; /* in Third word in IPC token d1 */ ; uchar *Queue_Data; /* in User data of current queue sp+4 */ ; uchar **Parameters;/* in out Pointer to parameter address sp+8 */ ; ; ; Stack layout before call to IPC$Handle_Protocol: ; ; sp -> Queue_Data ; +4 *Parameters ------------+ ; a6 -> Old a6 ! ; a6+4 Return address ! ; a6+8 Buffer (=> d0) ! ; a6+12 Slot_Data (=> d1) ! ; a6+16 Queue_Data ! ; a6+20 Parameters <------------+ ; a6+24 Ignore_Message ; ; Function: ; Process an incoming message and produce a parameter block which ; is suitable for a rendezvous call to the receiver. Also manage ; virtual channels on a low level for a receiver. This format is ; depending on the actual parameter profile for a receiver. The incoming ; message buffer may be exchanged by this procedure! If a message is ; not qualified to be passed to the receiver then Ignore_Message is ; True and the buffer is deallocated. If Ignore_Message is False then ; the buffer is NOT deallocated. ; ; This procedure is called by ART when it has retreived an IPC token ; from the queue but before the actual "rendezvous". ; ;------------------------------------------------------------------------ 00000000 __ipc_handle_protocol: .local 00000000 4E560000 link a6,#0 setup_svc_in_a1 00000004 220F move.l sp,d1 00000006 0281FE000000 andi.l #(-a32_size),d1 0000000C 227019A204580048 movea.l ([cct_start+pi_cpt,d1.l],os2000svcptr),a1 ;a1 -> svc 00000014 42AE0018 clr.l (p5,a6) ; Ignore_Message = False 00000018 7008 moveq.l #p1,d0 0000001A D08E add.l a6,d0 ; d0 := *Buffer 0000001C 222E000C move.l (p2,a6),d1 ; D1 = Slot_Data 00000020 486E0014 pea (p4,a6) ; -(sp) = *Parameters 00000024 2F2E0010 move.l (p3,a6),-(sp) ; -(sp) = Queue_Data 00000028 4EB10161013C jsr ([IPC$Handle_Protocol*4,a1]) ; Call shared library 0000002E 4A80 tst.l d0 ; D0=status 00000030 6700 beq.s $exit 00000032 1D7C0001001B $ignore:move.b #1,(p5+3,a6) ; Ignore_Message = True 00000038 4E5E $exit: unlk a6 0000003A 4E75 rts ;------------------------------------------------------------------------ ; ; procedure Release_Buffer (The_Buffer : in Buffer_Address; P1 ; Slot_Data : in Message_Slot_Data); P2 ; ; Shared C interface: ; ; status IPC$Release_Buffer (Buffer,Slot_Data) ; ; uchar *Buffer /* in The buffer address d0 */ ; ulong Slot_Data /* in Third longword in IPC token d1 */ ; ; Function: ; Release a buffer (deallocate). Use the proper method which is ; controlled by the Slot_Data parameter. ; ; This procedure is called by ART after a "rendezvous" is made to ; free the message buffer. ; ;------------------------------------------------------------------------ 0000003C __ipc_release_buffer: .local 0000003C 4E560000 link a6,#0 setup_svc_in_a1 00000040 220F move.l sp,d1 00000042 0281FE000000 andi.l #(-a32_size),d1 00000048 227019A204580048 movea.l ([cct_start+pi_cpt,d1.l],os2000svcptr),a1 ;a1 -> svc 00000050 202E0008 move.l (p1,a6),d0 ; D0 = Buffer 00000054 222E000C move.l (p2,a6),d1 ; D1 = Slot_Data 00000058 4EB101610140 jsr ([IPC$Release_Buffer*4,a1]) ; Call shared library 0000005E 4E5E unlk a6 00000060 4E75 rts ;------------------------------------------------------------------------ ; ; procedure Evacuate_Queue (The_Queue : in out Message_Queue.Queue; P1 ; Queue_Data : in Associated_Data); P2 ; ; Shared C interface: ; ; status IPC$Evacuate_Queue (Queue,Delete_Queue) ; ; q_address_t *Queue /* in out The queue pointer d0 */ ; ulong *Delete_Queue /* in TRUE/FALSE d1 */ ; ; N.B. The Queue_Data parameter is discarded in this interface! ; ; Function: ; Close a queue and deallocate all resources tied to it. Also abort ; any open channels, "group_off" any multicast subscriptions and ; undefine any name in the name server. The queue is emptied but ; NOT deleted! ; ; This procedure is called by ART as a result of a "Detach_Queue" call ; from IPC ; OR by ART when a task is terminating and the entry is still ; attached to IPC. ; ;------------------------------------------------------------------------ 00000062 __ipc_evacuate_queue: .local 00000062 4E560000 link a6,#0 setup_svc_in_a1 00000066 220F move.l sp,d1 00000068 0281FE000000 andi.l #(-a32_size),d1 0000006E 227019A204580048 movea.l ([cct_start+pi_cpt,d1.l],os2000svcptr),a1 ;a1 -> svc 00000076 202E0008 move.l (p1,a6),d0 ; D0 = The_Queue 0000007A 4281 clr.l d1 ; D1 = FALSE (<=> keep q) 0000007C 4EB101610144 jsr ([ipc$evacuate_queue*4,a1]) ; Call shared library 00000082 4E5E unlk a6 00000084 4E75 rts .end Program Section Name Kind Length Patches Fixups -------------------------------- ---- ---------- ------- ------- ADA_CODE Rel 134 1 0 Standard include file: <none> Object module version: 11 Assembled 256 lines in 3.589 elapsed, 2.406 CPU. 4280 lines per elapsed minute. 6384 lines per CPU minute. 79 disk waits for this job. 69813 bytes of heap used by this job.