|
DataMuseum.dkPresents historical artifacts from the history of: RC4000/8000/9000 |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about RC4000/8000/9000 Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - download
Length: 3840 (0xf00) Types: TextFile Names: »tcatstat«
└─⟦667bb35d6⟧ Bits:30007480 RC8000 Dump tape fra HCØ. └─⟦4334b4c0b⟧ └─⟦this⟧ »tcatstat«
;ali catstat=set 60 lookup catlist if ok.yes catstat=algol list.yes catstat=algol catstat ;1981-02-11 begin zone cat(2*128,2,stderror); integer field segm,head; array field raf; long array field doc; integer array field tail; real r,time; integer array ctail(1:10),slices,sort(1:1025), catkey,catent,catarea(0:3); long array docn(1:2); integer i,j,k,cats,s,cno,tno,st,cmax,entries,smax,key, totsegm,sts,sa,so,slicel,segsl; raf:=0; doc:=2; open(cat,4,<:catalog:>,0); inrec(cat,128); lookuptail(<:catalog:>,ctail); cats:=ctail(1); cleararray(sort); readsfp(<:doc:>,docn.raf,<::>); readifp(<:smax:>,smax,1024); if smax>1024 or smax<1 then smax:=1024; totsegm:=entries:=0; cleararray(catkey); cleararray(catent); cleararray(catarea); cleararray(slices); readifp(<:sts:>,sts,20); readifp(<:slicelength:>,slicel,14); cmax:=50; for cno:=2 step 1 until cats do begin tail:=14; head:=2; for tno:=1 step 1 until 15 do begin key:=cat.head extract 3; s:=cat.tail(1); if docn(1)=0 or (cat.tail.doc(1)=docn(1)) then begin if s>0 and key<4 then begin catkey(key):=catkey(key)+s; catarea(key):=catarea(key)+1; end else if key<4 then catent(key):=catent(key)+1; if key>1 and cat.head>0 then begin entries:=entries+1; if s>0 then begin totsegm:=totsegm+s; if s<=smax then sort(s):=sort(s)+s else sort(smax+1):=sort(smax+1)+s; segsl:=(s//slicel+(if s mod slicel=0 then 0 else 1)); slices(segsl):=slices(segsl)+1; end; end; end; tail:=tail+34; head:=head+34; end; if cno<cats then inrec(cat,128); end; write(out,<:<12><10>catalog statistics, permanent entries<10><10>:>); if docn(1)<>0 then write(out,"nl",1,<:document = :>,docn); write(out,"nl",1,<:total no of bs-entries :>,entries,<:<10>:>); systime(1,0,time); write(out,<< dd dd dd>,systime(4,time,r),r); write(out,<:<10>:>); sa:=0; for i:=1 step 1 until smax do begin s:=sort(i); if s>0 then begin if s//sts>cmax then st:=cmax else st:=s//sts; sa:=sa+s*i; j:=write(out,<:<10>s=:>,<<ddd>,i,<: :>,false add 42,st); write(out,false add 32,cmax-st+2,<<dddd>,s,<:= :>,s*i,<: , :>,sa); end; end; write(out,<:<10>greater than :>,smax,<: = :>,sort(smax+1), <:<10>total permanent segments :>,totsegm,<:<10>:>); sa:=0; write(out,"nl",2,<:slice distribution:>); for i:=1 step 1 until smax+1 do begin s:=slices(i); if s>0 then begin sa:=sa+s*slicel*i; j:=write(out,"nl",1,<:slices=:>,<<ddd>,i,"*",s//5); write(out,"sp",40-j,<< dddddd>,s,sa); end; end loop; write(out,<:<10>with slicelength :>,slicel,<: total permanet segments :>, sa); outendcur(12); for key:=0 step 1 until 3 do write(out,<:<10>key :>,<<dd>,key,<: = :>,<<dddd>,catkey(key), <: segments, :>,catarea(key),<: area entries:>, catent(key),<: other entries:>); s:=sa:=so:=0; for i:=0 step 1 until 3 do begin s:=s+catkey(i); sa:=sa+catarea(i); so:=so+catent(i); end; write(out,<:<10>total used segments :>,s, <:<10>total used area entries :>,sa, <:<10>total used other entries :>,so); outendcur(10); outendcur(12); end; catstat doc.disc catstat doc.disc3 slicelength.63 finisb mode list.no ▶EOF◀