Assembler code for the central copy loop of the ancestor (80aaa) and decendant after fifteen billion instructions (72etq). Within the loop, the ancestor does each of the following operations once: copy instruction (51), decrement cx (52), increment ax (59) and increment bx (60). The decendant performs each of the following operations three times within the loop: copy instruction (15, 22, 26), increment ax (20, 24, 31) and increment bx (21, 25, 32). The decrement cx operation occurs five times within the loop (16, 17, 19, 23, 27). Instruction 28 flips the low order bit of the cx register. Whenever this latter instruction is reached, the value of the low order bit is one, so this amounts to a sixth instance of decrement cx. This means that there are two decrements for every increment. The reason for this is related to another adaptation of this creature. When it calculates its size, it shifts left (12) before allocating space for the daughter (13). This has the effect of allocating twice as much space as is actually needed to accomodate the genome. The genome of the creature is 36 instructions long, but it allocates a space of 72 instructions. This occurred in an environment where the slice size was set equal to the size of the cell. In this way the creatures were able to garner twice as much energy. However, they had to compliment this change by doubling the number of decrements in the loop.
nop_1 ; 01 47 copy loop template COPY LOOP OF 80AAA nop_0 ; 00 48 copy loop template nop_1 ; 01 49 copy loop template nop_0 ; 00 50 copy loop template mov_iab ; 1a 51 move contents of [bx] to [ax] (copy instruction) dec_c ; 0a 52 decrement cx if_cz ; 05 53 if cx = 0 perform next instruction, otherwise skip it jmp ; 14 54 jump to template below (copy procedure exit) nop_0 ; 00 55 copy procedure exit compliment nop_1 ; 01 56 copy procedure exit compliment nop_0 ; 00 57 copy procedure exit compliment nop_0 ; 00 58 copy procedure exit compliment inc_a ; 08 59 increment ax (point to next instruction of daughter) inc_b ; 09 60 increment bx (point to next instruction of mother) jmp ; 14 61 jump to template below (copy loop) nop_0 ; 00 62 copy loop compliment nop_1 ; 01 63 copy loop compliment nop_0 ; 00 64 copy loop compliment nop_1 ; 01 65 copy loop compliment (10 instructions executed per loop) shl ; 000 03 12 shift left cx COPY LOOP OF 72ETQ mal ; 000 1e 13 allocate daughter cell nop_0 ; 000 00 14 top of loop mov_iab ; 000 1a 15 copy instruction dec_c ; 000 0a 16 decrement cx dec_c ; 000 0a 17 decrement cx jmpb ; 000 15 18 junk dec_c ; 000 0a 19 decrement cx inc_a ; 000 08 20 increment ax inc_b ; 000 09 21 increment bx mov_iab ; 000 1a 22 copy instruction dec_c ; 000 0a 23 decrement cx inc_a ; 000 08 24 increment ax inc_b ; 000 09 25 increment bx mov_iab ; 000 1a 26 copy instruction dec_c ; 000 0a 27 decrement cx or1 ; 000 02 28 flip low order bit of cx if_cz ; 000 05 29 if cx == 0 do next instruction ret ; 000 17 30 exit loop inc_a ; 000 08 31 increment ax inc_b ; 000 09 32 increment bx jmpb ; 000 15 33 go to top of loop (6 instructions per copy) nop_1 ; 000 01 34 bottom of loop (18 instructions executed per loop)