CS220 Practice Quiz 1

Basic Concepts




  Answer the following questions:
  1. How do assemblers and linkers work together?
  2. How will studying assembly language enhance your understanding of operating systems?
  3. Name two types of applications that would be better suited to assembly language than a high-level language.
  4. Why would a high-level language not be an ideal tool for writing a program to directly access a particular brand of printer?
  5. Why is assembly language not usually used when writing large application programs?
  6. Why don't programmers write application programs in machine language?
  7. Explain the term LSB.
  8. Explain the term MSB.




Answers:
  1. An assembler converts source-code programs from assembly language into machine language, often referred to as object-code.
    A linker combines individual files created by an assembler into a single executable program.
  2. Assembly language is a good tool for learning how applications programs communicate with the computer's operating system via interrupt handlers, system calls, and common memory areas. Assembly language programming also helps when learning how the operating system loads and executes application programs.
  3. Applications suited to assembly language: hardware device drivers and embedded systems and computer games requiring direct hardware access.
  4. A high-level language may not provide for direct hardware access. Even if it does, awkward coding techniques must often be used, resulting in possible maintenance problems.
  5. Assembly language had minimal formal structure, so structure must be imposed by programmers who have varying levels of experience. this leads to difficulties maintaining existing code.
  6. It is very detailed and consists purely of numbers. Very difficult for humans to understand.
  7. Least significant bit (bit 0).
  8. Most significant bit ( the highest numbered bit).