Contact us Heritage collections Image license terms
HOME ACL Associates Technology Literature Applications Society Software revisited
Further reading □ CONTENTS1. Basic Facilities2. Further Facilities3. Matrix Operations4. Programme LibraryA1. Punching ServiceA2. Running YourselfA3. Interpretation of Machine OrdersA4. At ManchesterA5. Library Programmes
ACD C&A INF CCD CISD Archives Contact us Heritage archives Image license terms

Search

   
ACLLiteratureOther manualsMercury Autocode :: Mercury Autocode Manual
ACLLiteratureOther manualsMercury Autocode :: Mercury Autocode Manual
ACL ACD C&A INF CCD CISD Archives
Further reading

CONTENTS
1. Basic Facilities
2. Further Facilities
3. Matrix Operations
4. Programme Library
A1. Punching Service
A2. Running Yourself
A3. Interpretation of Machine Orders
A4. At Manchester
A5. Library Programmes

Appendix 3: Interpretation of Machine Orders

Facilities are provided for writing part of an Autocode programme in conventional machine instructions in order to speed up inner loops, etc. The instructions must be written in the form

function and b-digits and address digits

and may be written with the address either in the conventional form or in the symbolic form described below. The function and b-digits are in both cases written in the conventional way. These instructions may be labelled in the same way as Autocode instructions.

Conventional addresses.

Conventional addresses are written in terms of medium length register numbers with a comma between the functional part and the address part, e. g.

200, 15.10+ 
407, 2

The usual facilities for writing the address in any consistent page-and-line form and for the use of the symbols ≠ = with instructions of the n,b type still apply.

Only fixed addresses are allowed with this facility: no forms of relative addresses are possible.

Care must be taken when using conventional addresses that no vital part of Autocode is overwritten; their use is therefore deprecated apart from the possible use of a few functions such as 620 etc., since all the facilities can be obtained by means of the symbolic form.

Symbolic addresses.

In the symbolic form the address 1s written in brackets and is interpreted as follows:

            Instruction                  Interpretation of the address
            (i)   400 (x)                  address of x
            (ii)  200 (i)                  address of i 
            (iii) 590 (3)                  address of the instruction labelled 3.

The first example applies to any of the accumulator codes 40 to 45 and 50 to 55. The quantity in the brackets can be a variable such as xl, x3, xi, x(i-3) or any signed or unsigned numerical constant. In the case of xi, x(i-3) the b-digit must always be a zero.

The second example applies to any of the machine codes 00 to 07, 20 to 27. In this case the quantity in brackets can be an index or a signed or unsigned integer.

The third example applies to all jump instructions.

Machine codes of the type n,B are not allowed in symbolic address form, thus 300(3) should be written in the form 300,3 etc.

As an illustration of the way time can be saved by the use of conventional machine orders in an inner loop, consider the following example. The problem is the summation of the polynomial

y = a0 + a1x + a2x2 + a10x10
         

and the AUTOCODE programme is as follows:

u = a10 
r = 9(-1)0 
u = ux + ar 
repeat 

The number of instructions can be almost halved by writing them directly in the symbolic form described above. Thus:

   300, 10               sets B7 
   407 (a0)              transfers a10 to the accumulator 
1) 330, 1                reduces B7 
   500 (x)            
   427 (a0)              forms ux + ar 
   280 (1)               tests B7 and jumps to 1) if not finished 
   410 (u)               plants u 

This could be shortened still further if the polynomial were arranged in the form:

a0 x10 +a1 x9 + .. + a10

for then the cycle could be re-written

   400 (a0)
   300, -9
1) 500 (x)
   380 (1)
   410 (u)

The times for the three methods are respectively 185, 105 and 95 micromins. This example is one of the worst possible, but serves to stress that Autocode is generally much less than a factor of 2 slower than the conventional method.

In general it will not be possible to interpret Autocode programmes involving Mercury machine instructions correctly on the Atlas and Orion computers. As already explained, however, special provision will be made in the case of the "592,0" instruction, the "620" instruction, which is used for alpha-numeric output, and the instructions needed for generating pseudo-random numbers.

⇑ Top of page
© Chilton Computing and UKRI Science and Technology Facilities Council webmaster@chilton-computing.org.uk
Our thanks to UKRI Science and Technology Facilities Council for hosting this site