wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

CD_quiz2

Total questions: 25

Worksheet time: 13mins

Name
Class
Date
1.

cross compiler runs on machine a and generates code for machine a

a)

true

b)

false

2.

interpreter should be used during program development stage

a)

true

b)

false

3.

compiler always generate machine code

a)

true

b)

false

4.

transpiler is a compiler that translates program in

a)

HLL to another HLL

b)

HLL to assembly language

c)

HLL to machine language

5.

compiled code execution is slower than interpretation

a)

true

b)

false

6.

Interpreter generates object file

a)

true

b)

false

7.

compiler is characterised by __ languages

a)

3

b)

2

c)

1

8.

flex /lex/jflex are

a)

scanner generator

b)

parser generator

c)

none

9.

binary translation is a process where

a)

binary code for one machine gets translated to another

b)

assembly code to machine for the same machine

c)

assembly code to machine code for different machine

10.

yet another compiler compiler is

a)

scanner generator

b)

lexical analyzer generator

c)

intermediate code generator

d)

parser generator

11.

input to scanner generator is

a)

patterns of tokens

b)

structure of programming language constructs

c)

none

12.

Hardware synthesizer tool translates RTL description to gates

a)

true

b)

false

13.

program slicing is grouping of program statements that does not affect value of variable of interest

a)

true

b)

false

14.

profiling is used to study non busy regions of program

a)

yes

b)

no

15.

to develop compilers for 5 languages on 3 machines no of frontend and backends are

a)

5+5

b)

5+3

c)

3+5

d)

none

16.

compiler structure is divided into analysis part and

a)

front end

b)

backend

17.

type check is done during

a)

syntax analysis

b)

lexical analysis

c)

semantic analysis

18.

coercion is automatically carried out during semantic analyzer to

a)

convert narrow type to wider type

b)

convert wider to narrow

19.

input to code generator generator is set of rules for translating each operation of source language into machine language for a target machine

a)

true

b)

false

20.

bootstrapping is a used to construct more complex compiler from existing ones or simpler once

a)

true

b)

false

21.

in the following bootstrapping process ,identify the language that can replace X?,Y?,Z? and W?

here in first compiler L1 is source,mb target & ma implementation language

L1mamb -> X? ma mb ->Y? Z? W?

a)

ma,L1,mb,mb

b)

ma,L1,mb,ma

c)

ma,L1,ma,mb

22.

Native compiler runs on machine a and generates machine code for machine b

a)

true

b)

false

23.

analysis part consists of

a)

lexical,syntax,semantic,Intermediate code generation

b)

Lexical ,syntax,semantic

c)

lexical,syntax,semantic,Intermediate code generation, & machine independent code optimization

24.

Lexical analyzer ignores

a)

blanks

b)

comments

c)

both

25.

choose most appropriate one

software that translates source program in one highlevel language to another high level language are called as

a)

source to source compiler

b)

transpiler

c)

transcompiler

d)

all the mentioned