Give the schematic of Interpretation of HLL Program and execution of a machine language program by the CPU.

 

Answer:

 

The CPU used a program counter (PC) to note the address of next instruction to be executed. This instruction is subjected to the instruction execution cycle consisting of the following steps:

1.      Fetch the instruction.

2.      Decode the instruction to determine the operation to be performed, and also its operands.

3.      Execute the instruction.

At the end of the cycle, the instruction address in PC is updated and the cycle is repeated for the next instruction. Program interpretation can proceed in a similar manner. The PC can indicate which statement of the source program is to be interested next. This statement would be subjected to the interpretation cycle, which consists of following steps:

1.      Fetch the statement.

2.      Analyze the statement and determine its meaning, viz the computation to be performed and its operands.

3.      Execute the meaning of the statement. 

Post a Comment