WHAT IS ASSEMBLY LANGUAGE - Leo Tutorials

                                                         Assembly Language 
A programming language is defined by a set of rules. Users must conform with all format rules of the language if they want their programs to be translate correctly. Almost every commercial computer has its own particular assembly language. The rules for writing assembly language programs are documented and published in manual which are usually available from the computer manufacture.
               The basic unit of an assembly language program is a line of code. The specific language is defined by a set of rules that specify the symbols that can be used and how they may be combined to form a line of code. We will now formulate the rules of an assembly language for writing symbolic programs the basic computer.
              The following are the requirements for an effective assembly language programming:
         Programming model of the processor, complete instruction set details of the processors, memory map and I/O map of the language. Programs model specifies the program accessible registers. The assembler converts the assembly language into machine language for execution.

Rules of the Language 

Each line of an assembly language program is arranged in three column called fields. The fields specify the following information.


  1. The label field may be empty or it may specify a symbolic address.
  2. The instruction field specifies a machine instruction or a pseudo-instruction 
  3. The comment field may be empty or it may include a comment.
             A symbolic address consists of one, two, or three, but not more than three alphanumeric characters. The first character must be a letter; the next two may be letters or numerical. The symbol can be chosen arbitrarily by the programmer. A symbolic address in the label by the assembler.
          The instruction field in an assembly language program may specify of the following items :
  1. A memory-reference instruction (MRI)
  2. A register-reference or input-output instruction (NON-MRI)
  3. A pseudo-instruction with or without an operand  
            A memory-reference instruction occupies two or three symbols separated by spaces. The fist must be a three-letter symbol defining an MRI operation code. The second is a symbolic address. The third symbol, which may or may not be present, is the letter I.If I is missing, the liine denotes a direct address instruction. The presence of the symbol I denotes an indirect address instruction.
           A non-MRI  is defined as an instruction that does not have an address part. A non-MRI is defined is recognized in the instruction field of a program by any one of the three-letters symbols listed for the register-reference and input-output instructions.


         

Post a comment

0 Comments