Application Development using Assembler
Part Three - Challenge #07


Assembler = Speed. There are a number of cases in large enterprises where speed is paramount over ease of programming.

Your challenge:

ASMPGM assembler program counts from 1 to 10 using a loop. The incremented number is in register 3. The assembler mnemonic (A) is the add instruction. The assembler program will PUT "Hi! I can count fast." before entering the loop. Modify the assembler program to PUT each newly incremented number. If done correctly, P3.OUTPUT(#07) will include:

Hi! I can count very fast.

Several load statements in this assembler program have absolutely no impact on anything. The reason they are in the program is to show how assembler uses CPU registers for CPU operations in a later challenge. So, please do not remove them. The load instructions that have no impact are:

L     6,=C'abc ' 
L     7,=F'1234'
L     8,=C'1234'
LA    9,10

tso submit jcl(asmpgm)

The ASMPGM program output is written to P3.OUTPUT(#07)

edit jcl(asmpgm) and modify the in-stream source code to PUT each newly incremented number. submit , then review JCL job output and P3.OUTPUT(#07) for success.

Hint: A single line is needed in this program to PUT the count. A PUT exists in the program that can copied to the correct location in the assembler logic.

Next: Challenge #08