bidezones.com /System programming/SYSTEMS PROGRAMMING MCQ SET 2 Sample Test,Sample questions

Question:
	
A compiler for a high level language that runs on one machine and produces code for a different machine is called:

1. Optimizing

2.One pass compiler

3.Cross compiler

4. Multipass compiler

Posted Date:-2022-06-05 02:32:50


Question:
	
A single instruction in an assembly language program contains:

1.one micro operation

2.one macro operation

3.one instruction to be completed in a single pulse

4.one machine code instruction

Posted Date:-2022-06-05 02:22:51


Question:
	
A Top-down Parse generates:

1.Right-most derivation

2.Right-most derivation in reverse

3.Left-most derivation

4.Left-most derivation in reverse

Posted Date:-2022-06-05 02:28:08


Question:
	
An operating system is:

1.Collection of hardware components

2.Collection of input-output devices

3.Collection of software routines

4.All of the above

Posted Date:-2022-06-05 02:35:14


Question:
	
If you want to execute more than one program at a time, the systems software that are used must be capable of:

1.word processing

2.virtual memory

3.compiling

4.multitasking

Posted Date:-2022-06-05 02:47:30


Question:
	
In a two pass compiler, during the first pass:

1.user defined address symbols are correlated with their binary equivalent

2.the syntax of the statement is checked and mistakes, if any, are listed

3.object program is generated

4.semantic of the source program is elucidated

Posted Date:-2022-06-05 02:21:52


Question:
	
Match the description of several parts of a classic optimizing compiler in List - I, with the names of those parts in List - II:

List - I
(a) A part of a compiler that is responsible for recognizing syntax.
(b) A part of a compiler that takes as input a stream of characters and produces as output a stream of words along with their associated syntactic categories.
(c) A part of a compiler that understand the meanings of variable names and other symbols and checks that they are used in ways consistent with their definitions.
(d) An IR-to-IR transformer that tries to improve the IR program in some way (Intermediate representation).

List - II
(i) Optimizer
(ii) Semantic Analysis
(iii) Parser
(iv) Scanner

Code:
(a) (b) (c) (d)

1.(iii) (iv) (i) (ii)

2.(iv) (iii) (ii) (i)

3. (ii) (iv) (i) (iii)

4.(ii) (iv) (iii) (i)

Posted Date:-2022-06-05 03:04:21


Question:
	
Not an assembler directive

1.XCHG

2.ASSUME

3.SHORT

4. DB

Posted Date:-2022-06-05 02:58:07


Question:
	
Symbol table can be used for:

1.Checking type compatibility

2.Suppressing duplication of error message

3.Storage allocation

4.All of these above

Posted Date:-2022-06-05 02:30:02


Question:
	
The ‘K’ in LR (K) cannot be:

1.0

2.1

3.2

4.None of These

Posted Date:-2022-06-05 02:33:40


Question:
	
Which of the following are Assembler Directives?

(i) EQU
(ii) ORIGIN
(iii) START
(iv) END

1. (ii), (iii) and (iv)

2.(i), (iii) and (iv)

3.(iii) and (iv)

4.(i), (ii), (iii) and (iv)

Posted Date:-2022-06-04 17:30:12


Question:
	
YACC builds up ................. parsing table.

1. LALR

2.LR

3.SLR

4.LLR

Posted Date:-2022-06-05 02:41:12


Question:
A general macro processor is an in built function of:

1.Loader

2.Linker

3.Editor

4.Assembler

Posted Date:-2022-06-05 02:44:24


Question:
A parse tree is an annotated parse tree if:

1.it shows attribute values at each node.

2. there are no inherited attributes.

3.it has synthesized nodes as terminal nodes.

4.every non-terminal nodes is an inherited attribute.

Posted Date:-2022-06-05 02:20:57


Question:
A permanent database of a general model of compiler is................

1.Identifier table

2.Page map table

3.Literal table

4.Terminal table

Posted Date:-2022-06-05 02:36:23


Question:
Absolute loader demands that the programmer needs to know the:

1.start address of the available main memory

2.total size of the program

3.actual address of the data location

4.absolute values of the operands used

Posted Date:-2022-06-05 02:23:42


Question:
An assembly program contains:

1.imperative and declarative statements

2.imperative and assembler directives

3.imperative and declarative statements as well as assembler directives

4.declarative statements and assembler directives

Posted Date:-2022-06-04 17:28:53


Question:
An example of a compiler-compiler is:

1.JAVA

2.LEX

3.YACC

4.MATLAB

Posted Date:-2022-06-05 03:00:14


Question:
Any syntactic construct that can be described by a regular expression can also be described by 

1.Context sensitive grammar

2.Non context free grammar

3.Context free grammar

4.None of the above

Posted Date:-2022-06-04 17:27:02


Question:
Assembler program is:

1. dependent on the operating system

2.dependent on the compiler

3.dependent on the hardware

4.independent of the hardware

Posted Date:-2022-06-04 17:34:25


Question:
At the end of parsing,

1.tokens are identified.

2.the syntactic groups are identified.

3.set of instructions are identified.

4.machine instructions are identified.

Posted Date:-2022-06-04 17:37:51


Question:
Code optimization is responsibility of:

1.Application programmer

2.System programmer

3.Operating system

4.All of the above

Posted Date:-2022-06-05 02:54:21


Question:
Consider the following assembly program segment. The contents of the destination register ax (in hexadecimal) and the status of Carry Flag (CF) after the execution of above instructions are:
stc
mov al, 11010110b
mov cl, 2
rcl al, 3
rol al, 4
shr al, cl
mul cl

1.ax = 003CH; CF = 0

2.ax = 001EH; CF = 0

3.ax = 007BH; CF = 1

4.ax = 00B7H; CF = 1

Posted Date:-2022-06-05 03:02:03


Question:
Consider the following program fragment in assembly language. What is the value of ax and cx registers after the completion of the doloop?
    mov ax, 0h
    mov cx, 0A h
doloop:
    dec ax
    loop doloop

1.ax = FFF5 h and cx = 0 h

2.ax = FFF6 h and cx = 0 h

3.ax = FFF7 h and cx = 0A h

4.ax = FFF5 h and cx = 0A h

Posted Date:-2022-06-05 03:01:16


Question:
Dead-code elimination in machine code optimization refers to:

1.removal of all labels.

2.removal of values that never get used. c.

3. removal of function which are not involved.

4.removal of a module after its use.

Posted Date:-2022-06-04 17:42:44


Question:
How many states can a process be in?

1.2

2.3

3.4

4.5

Posted Date:-2022-06-05 02:26:15


Question:
In a compiler, the task of scanning the source code, to recognize and classify various elements is known as.

1.Code Optimization

2.Syntactic Analysis

3.Lexical Analysis

4.Semantic Analysis

Posted Date:-2022-06-05 02:59:15


Question:
In an absolute loading scheme, which loader function is accomplished by programmer?

1.Allocation

2.Linking

3.Reallocation

4.Both (a) and (b)

Posted Date:-2022-06-05 02:29:05


Question:
In the context of compiler design, “reduction in strength” refers to:

1.code optimization obtained by the use of cheaper machine instructions

2.reduction in accuracy of the output

3.reduction in the range of values of input variables

4.reduction in efficiency of the program

Posted Date:-2022-06-05 02:25:42


Question:
In two pass assembler the symbol table is used to store:

1.Label and value

2.Only value

3.Mnemonic

4.Memory Location

Posted Date:-2022-06-05 02:56:51


Question:
Linking

1.cannot be performed before relocation

2.cannot be performed after relocation

3.can be performed both before and after relocation

4.is not required if relocation is performed

Posted Date:-2022-06-05 02:31:02


Question:
Loading operating system from secondary memory to primary memory is called...............

1.Compiling

2.Booting

3.Refreshing

4.Reassembling

Posted Date:-2022-06-05 02:37:47


Question:
Non modifiable procedures are called:

1.Serially usable procedure

2.Concurrent procedure

3.Re-entrant procedure

4.Top down procedure

Posted Date:-2022-06-05 02:48:35


Question:
Peep-hole optimization is a form of:

1.loop optimization

2.local optimization

3.constant folding

4.data flow analysis

Posted Date:-2022-06-05 02:34:23


Question:
Tasks done in parsing are:

1.Check the validity of a source string

2.Determine the syntactic structure of a source string

3.Both a and b

4.None of these

Posted Date:-2022-06-05 02:40:19


Question:
The action of passing the source program into the proper syntactic class is known as:

1.Syntax analysis

2.Lexical analysis

3.Interpretation analysis

4.Uniform symbol generation

Posted Date:-2022-06-05 02:42:06


Question:
The dynamic binding occurs during the:

1.Compile time

2.Run time

3.Linking time

4.Pre-processing time

Posted Date:-2022-06-05 02:42:50


Question:
The parsing technique that avoids back tracking is:

1.Top-down parsing

2.Recursive-descent parsing

3.Predictive

4. Syntax tree

Posted Date:-2022-06-05 02:27:12


Question:
The principle of Locality of reference justifies the use of:

1.Virtual memory

2.Interrupts

3.Cache memory

4.Secondary memory

Posted Date:-2022-06-05 02:52:08


Question:
Top-down parsers are predictive parsers, because:

1. next tokens are predicted

2.length of the parse tree is predicted before hand

3.lowest node in the parse tree is predicted

4.next lower level of the parse tree is predicted

Posted Date:-2022-06-05 02:24:38


Question:
When a language has the capability to produce new data types, it is said to be:

1.extensible

2.encapsulated

3.overloaded

4.None of the above

Posted Date:-2022-06-04 17:27:51


Question:
Which activity is included in the first pass of two pass assemblers?

1.Build the symbol table

2.Construct the intermediate code

3.Separate mnemonic opcode and operand fields

4.All of the above

Posted Date:-2022-06-05 02:55:21


Question:
Which activity is not included in the first pass of two pass assembler?

1.build the symbol table

2.construct the intermediate code

3.separate mnemonic opcode and operand field

4.none of these

Posted Date:-2022-06-05 02:46:30


Question:
Which activity is not included in the first pass of two pass assemblers ?

1.Build the symbol table

2.Construct the machine code

3.Separate mnemonic opcode and operand fields

4.None of these

Posted Date:-2022-06-05 02:51:22


Question:
Which activity is not included in the first pass of two pass assemblers?

1.Build the symbol table

2.Construct the intermediate code

3.Separate mnemonic opcode and operand fields

4.None of the above

Posted Date:-2022-06-05 02:53:07


Question:
Which of the following is not collision Resolution Technique?

1.Hash addressing

2.Chaining

3.Indexing

4.None of these

Posted Date:-2022-06-05 02:45:11


Question:
Which of the following is the most general phase - structured grammar ?

1.Regular

2.Context – Sensitive

3.Context free

4.None of these

Posted Date:-2022-06-05 02:50:26


Question:
Which of the following is the most general phase-structured grammar ?

1.Regular

2.Context-sensitive

3.Context free

4.Syntax tree

Posted Date:-2022-06-05 02:32:07


Question:
Which of the statements related to Compilers is wrong ?

1.Lexical analysis is breaking the input into tokens

2.Syntax analysis is for parsing the phrase

3.Syntax analysis is for analyzing the semantic

4.None of these

Posted Date:-2022-06-05 02:49:31


Question:
Which statement is wrong ?

1.If linked origin ≠ translated origin, relocation must be performed by the linker

2.If load ≠ linked origin, the loader must perform relocation

3.A linker always perform relocation, whereas some loaders do not

4.None of These

Posted Date:-2022-06-05 02:38:43


More MCQS[bidezones.com ]

  1. SYSTEMS PROGRAMMING MCQ SET 1
  2. SYSTEMS PROGRAMMING MCQ SET 2
  3. SYSTEMS PROGRAMMING /MACHINE STRUCTURE
  4. SYSTEMS PROGRAMMING /MACRO PROCESSOR
  5. SYSTEMS PROGRAMMING /LOADERS MCQ
  6. SYSTEMS PROGRAMMING /PROGRAMMING LANGUAGES MCQ SET 1
  7. SYSTEMS PROGRAMMING /PROGRAMMING LANGUAGES MCQ SET 2
  8. SYSTEMS PROGRAMMING /PROGRAMMING LANGUAGES MCQ SET 3