All Exams Test series for 1 year @ ₹349 only
Question

Pseudo instruction is given to___________.

The correct answer is
A ssembler

Understanding Pseudo Instructions and the Assembler

Pseudo instructions are special directives that are given to the assembler. Unlike actual machine instructions, pseudo instructions do not translate directly into executable machine code that the CPU understands. Instead, they tell the assembler how to perform its task, such as defining data, allocating memory, or controlling the assembly process itself.

Let's examine the roles of the different options provided to understand which one interacts with pseudo instructions.

Analyzing the Options

  • Loader: The loader is responsible for loading the executable program from secondary storage (like a hard drive) into the main memory so that it can be executed by the CPU. The loader works with the final executable code, not the source assembly code or assembler directives like pseudo instructions.
  • Linker: The linker combines one or more object files (generated by the assembler from assembly source code) and libraries into a single executable program. It resolves external references between different code modules. The linker operates on object code, not assembly source code containing pseudo instructions.
  • C Compiler: A C compiler translates source code written in the C programming language into machine code or assembly code. While compilers have their own directives (like preprocessor directives starting with '#'), pseudo instructions are specific to assembly language and are understood by the assembler, not a C compiler.
  • Assembler: The assembler is a program that translates assembly language code into machine code. Assembly language consists of mnemonics (like MOV, ADD) that correspond to machine instructions, as well as pseudo instructions (directives) that control the assembly process. Pseudo instructions tell the assembler things like how to define data (e.g., DB, DW, DD), reserve memory space (e.g., RESB, RESW, RESD), define symbols, or specify the start and end of the program. Therefore, pseudo instructions are specifically given to the assembler.

Conclusion on Pseudo Instructions

Based on the analysis, pseudo instructions are commands or directives meant for the assembler to guide it during the translation of assembly code into machine code. They do not generate executable instructions but rather help manage the assembly process, define data, and structure the program.

Therefore, pseudo instruction is given to the assembler.

Component Primary Function Interacts with Pseudo Instructions?
Loader Loads program into memory No
Linker Combines object files No
C Compiler Translates C code No (Has compiler directives, not pseudo instructions)
Assembler Translates assembly code to machine code Yes (Pseudo instructions are directives for the assembler)

Revision Table: Software Development Tools

Tool Input Output Role in Development
Compiler High-level source code (C, C++, Java, etc.) Assembly code or machine code (object code) Translates human-readable code to machine-executable code.
Assembler Assembly language code (mnemonics, pseudo instructions) Machine code (object code) Translates assembly language into binary machine instructions.
Linker Object files, libraries Executable program Combines object files and resolves external references.
Loader Executable program Program loaded into memory Loads the executable file into main memory for execution.

Additional Information: Directives vs. Instructions

It's important to distinguish between instructions and directives (like pseudo instructions) in assembly language:

  • Instructions: These correspond directly to operations performed by the CPU (e.g., adding numbers, moving data). The assembler translates each instruction mnemonic into a specific machine code opcode and operands.
  • Directives (Pseudo Instructions): These are commands for the assembler itself. They control how the assembler processes the assembly code, define data types, reserve memory, set up segments, or control listing output. They do not translate into executable machine code but influence the content or structure of the output object file or the assembly process. Examples include .DATA, .CODE, DW (Define Word), RESB (Reserve Byte), END.

Understanding the role of the assembler and its interaction with pseudo instructions is fundamental to understanding how assembly language programs are processed.

Was this answer helpful?

Important Questions from Miscellaneous

  1. Which of the following is NOT a state function or state variable in a thermodynamic system?

  2. What is the full form for "BPL" in Socio-economic aspects?
  3. In October 2024, which of the following companies was awarded the contract for design, manufacturing and commissioning of two high-speed trainsets by Integral Coach Factory (ICF) to be used in India's first bullet train between Mumbai and Ahmedabad?
  4. Which of the following methods of reproduction simply involves the splitting of the parent cell into two daughter cells in the bacteria?
  5. A, B, C and D opened shopping complexes in the same city. The shopping complex of A is 6 km west of the shopping complex of B. The shopping complex of C is 4 km north of the shopping complex of B. The shopping complex of D is 6 km west of the shopping complex of C. In which direction is the shopping complex of D from the shopping complex of A?
Need Expert Advice?

Start Your Preparation with Prepp Mobile App

Download the app from Google Play & App Store
Download the app from Google Play & App Store
Prepp Mobile App