ITPEC FE Morning April 2018 Question 20

Topic: Software

Which of the following is the appropriate function of a linker?

Explanation

Resolving cross references to make one load module — the linker joins separately compiled object modules into a single executable.

The compiler translates each source file into an object module that still contains unresolved references to routines and data in other modules and libraries. The linker (linkage editor) fills in those addresses and combines the modules into one load module, which the loader then places in main memory to run.

Answer (a)

Why not others:

  • •(b) — loading a load module into main memory before execution is the loader's job
  • •(c) — monitoring execution and recording the results of each step is what a tracer does, a debugging tool
  • •(d) — registering a finished program in a library is done by a librarian

Key rule: Compiler, then linker, then loader: object modules become one load module, which is then loaded into memory and run.

Software · AI-written, may contain errors

This question comes from an official ITPEC past paper. ITPEC Practice is an independent study tool and is not affiliated with ITPEC. See the official FE past-paper collection or Report an issue.