1 SUB HDDOTL(nod1%, nod2%, loop%, current.loop%, num.loops%) 2 ! 3 ! check if node combination occurs in another loop 4 ! 5 COMMON (FCSERR) err1%, err2% 6 ! TRUTH.B4S 7 .DEFINE .TRUE%=-1% 8 .DEFINE .FALSE%=0% 9 ! 10 ! {HDDDEF.B4S} 11 ! 12 .DEFINE .pipe.chan% = 21% 13 .DEFINE .node.chan% = 22% 14 .DEFINE .loop.chan% = 23% 15 .DEFINE .tf.out.chan% = 24% 16 .DEFINE .log.chan% = 25% 17 ! 18 ! 19 ! Constant definitions 20 ! 21 .DEFINE .eof% = -10% 22 .DEFINE .max.args% = 21% 23 .DEFINE .tf.bufsiz% = 128% 24 .DEFINE .cmd.line.siz% = 128% 25 .DEFINE .node.buf.siz% = 52% 26 .DEFINE .pipe.buf.siz% = 30% 27 .DEFINE .loop.buf.siz% = 42% ! must be (2 * .max.nodes% + 2) 28 ! 29 .DEFINE .max.nodes% = 20% 30 ! 31 MAP (LOOP1) loop1$ = .loop.buf.siz% 32 MAP (LOOP1) loop1%, l1.node%(.max.nodes%) 33 ! 34 loop.found% = .false% 35 i% = 0% 36 ! 37 WHILE((i% < num.loops%) AND (NOT (loop.found%))) 38 ! 39 i% = i% + 1% 40 n1.found%, n2.found% = .false% ! start with both false at beginning of each loop tested 41 CALL GET.(.loop.chan%, loop1$, i%) 42 ! 43 IF ((loop1% > 0%) AND (loop1% <> current.loop%)) ! i.e. it is not an undefined loop or the current loop & THEN nod% = 0% & \ WHILE l1.node%(nod%) & \ n1.fd% = (l1.node%(nod%) = nod1%) & \ n2.fd% = (l1.node%(nod%) = nod2%) & \ n1.found% = n1.found% OR n1.fd% & \ n2.found% = n2.found% OR n2.fd% & \ nod% = nod% + 1% & \ NEXT & \ loop.found% = (n1.found% AND n2.found%) & ! 44 NEXT 45 ! 46 IF loop.found% & THEN loop% = i% & ELSE loop% = 0% 47 ! 48 ! 49 ! print "HDDOTL: i, nod%, l1.node(nod), nod1, nod2, n1.f, n2.f " 50 ! print i%; nod%; l1.node%(nod%), nod1%; nod2%, n1.found%; n2.found% 51 ! print 52 ! print "before the NEXT" 53 ! print "after the NEXT" 54 ! print "HDDOTL: i, loop found "; i%, loop.found% 55 ! 56 SUBEND