Blog

Keep up to date with the latest news

Up To Date Introduction to VHDL ( VHDL ) MCQs – VHDL MCQs

Up To Date Introduction to VHDL ( VHDL ) MCQs – VHDL MCQs

Latest VHDL MCQs

By practicing these MCQs of Introduction to VHDL ( VHDL ) MCQs – Latest Competitive MCQs , an individual for exams performs better than before. This post comprising of objective questions and answers related to Introduction to VHDL ( VHDL ) Mcqs “. As wise people believe “Perfect Practice make a Man Perfect”. It is therefore practice these mcqs of VHDL to approach the success. Tab this page to check ” Introduction to VHDL ( VHDL )” for the preparation of competitive mcqs, FPSC mcqs, PPSC mcqs, SPSC mcqs, KPPSC mcqs, AJKPSC mcqs, BPSC mcqs, NTS mcqs, PTS mcqs, OTS mcqs, Atomic Energy mcqs, Pak Army mcqs, Pak Navy mcqs, CTS mcqs, ETEA mcqs and others.

VHDL MCQs – Introduction to VHDL ( VHDL ) MCQs

The most occurred mcqs of Introduction to VHDL ( ) in past papers. Past papers of Introduction to VHDL ( VHDL ) Mcqs. Past papers of Introduction to VHDL ( VHDL ) Mcqs . Mcqs are the necessary part of any competitive / job related exams. The Mcqs having specific numbers in any written test. It is therefore everyone have to learn / remember the related Introduction to VHDL ( VHDL ) Mcqs. The Important series of Introduction to VHDL ( VHDL ) Mcqs are given below:

EDA Tools

1. What is the full form of VHDL?
a) Verilog Hardware Description Language
b) Very High speed Description Language
c) Variable Hardware Description Language
d) Very high speed Hardware Description Language
Answer: d
Explanation: Most people confuse Verilog Hardware Description Language with VHDL but, VHDL means VHSIC Hardware Description Language where VHSIC is the acronym for Very High Speed Integrated Circuits.

2. What is the basic use of EDA tools?
a) Communication of Electronic devices
b) Fabrication of Electronics hardware
c) Electronic circuits simulation and synthesis
d) Industrial automation
Answer: c
Explanation: EDA expands to Electronic Design Automation and these tools are used for synthesis, implementation and simulation of Electronic circuits on the software itself.

3. After compiling VHDL code with any EDA tool, we get __________
a) Final device
b) FPGA
c) Optimized netlist
d) Netlist
Answer: d
Explanation: After entering the code into any EDA tool, we need to compile the code. When the compilation is complete, then we get the complete netlist of the system designed by using VHDL. After which optimization process is used to optimize the netlist and then by placement and routing we get final Physical device.

4. Which of the following is not an EDA tool?
a) Visual C++
b) Quartus II
c) Xilinx ISE
d) MaxPlus II
Answer: a
Explanation: Quartus II EDA tool is used for Altera CPLD and FPGA devices. Similarly, Xilinx ISE is used for Xilinx CPLD/FPGA devices. MaxPlus is also an advanced EDA tool for Altera CPLDs. Visual C++ is the compiler for C and C++ languages.

5. The process of transforming a design entry information of the circuit into a set of logic equations in any EDA tool is known as _________
a) Simulation
b) Synthesis
c) Optimization
d) Verification
Answer: b
Explanation: Synthesis means to generate netlist, i.e. describing the circuit by the relation between inputs and outputs by using logic equations. Simulation is whereas to check the correctness of VHDL code and Optimization is to optimize the netlist; optimization is performed after the synthesis. Verification similarly uses different EDA tool to perform gate level verification.

6. Place and Route EDA tools are used to take the design netlist and implement the design in the device.
a) True
b) False
Answer: a
Explanation: Place and Route tools are used to take the netlist and implement it on the target device by taking various factors into consideration like Timing constraints and some device information.

7. An Antifuse programming technology is associated with _________
a) CPLDs
b) FPGAs
c) SPLDs
d) ASICs
Answer: b
Explanation: Antifuse technology is used to burn the information, from place and route tools, into appropriate fuses in the FPGAs.

8. Which of the following is not a back end EDA tool?
a) Floor planning tools
b) Placement tools
c) Routing tools
d) Simulators
Answer: d
Explanation: Simulators are the tools which are used at the front end and all other tools are used at the back end.

9. What are the differences between simulation tools and synthesis tool?
a) Simulators are used to check the performance of circuit and Synthesis tools are for the fabrication of circuits
b) Simulators and Synthesis tools works exactly same
c) Simulators are used just to check basic functionality of the circuit and Synthesis tools includes timing constraints and other factors along with simulation
d) Simulation finds the error in the code and Synthesis tool corrects the code
Answer: c
Explanation: Simulators test basic logic and working of the circuit described in the code and Synthesis allows to take timing factor and other factors into consideration while simulation.

10. What is the extension of the netlist file; input to the place and route EDA tools?
a) EIDF
b) SDF
c) TXT
d) CPP
Answer: a
Explanation: EDIF and XNF are the netlist files; whereas SDF is the file of timing information.TXT is the extension of a simple text file and CPP is the C++ source file.

Need of HDLs

1. In what aspect, HDLs differ from other computer programming languages?
a) No aspect; both are same
b) HDLs describe hardware rather than executing a program on a computer
c) HDLs describe software and not hardware
d) Other computer programming languages have more complexity
Answer: b
Explanation: HDLs (Hardware Description Languages) are used to describe hardware for any electronic circuit or system; whereas other computer programming languages execute a program on the computer itself.

2. Which of the following HDLs are IEEE standards?
a) VHDL and Verilog
b) C and C++
c) Altera and Xilinx
d) Quartus II and MaxPlus II
Answer: a
Explanation: VHDL and Verilog are the only two HDLs endorsed by IEEE. C andC++ are not HDLs. Altera and Xilinx are devices on which these HDLs can be used. Quartus II and MaxPlus II are the platforms for simulation of hardware described by HDLs.

3. Why we needed HDLs while having many traditional Programming languages?
a) Traditional programming languages are complex
b) HDLs are complementary to traditional programming languages to complete the design process
c) Some characteristics of digital hardware couldn’t be captured by traditional languages
d) HDLs offer more complexity than traditional programming languages.
Answer: c
Explanation: Digital systems are very complex and this complexity is increasing day by day. Some characteristics like propagation delay, concurrent processing and interconnection of parts can’t be captured with traditional languages.

4. An HDL can’t describe Hardware at Gate level as well as switch level?
a) True
b) False
Answer: b
Explanation: An HDL supports the hierarchical design process. It can describe the circuit or hardware at every possible level, whether it is gate level or switch level or RTL level.

5. Why do we need concurrent processing for describing digital systems in HDLs?
a) Faster processing than conventional programming languages
b) Concurrent processing is easier than sequential processing
c) It allows taking timing constraints into consideration
d) Complexity of digital systems needs concurrent processing
Answer: d
Explanation: Due to the complexity of digital circuits, we need to process all the instructions at the same time. For example, current can flow in the two branches at the same time which can affect the output of the system, if sequentially processed.

6. An ASIC can be correctly designed by using programming languages like C or Assembly.
a) True
b) False
Answer: b
Explanation: By using HDL, we specify what we need. We can optimize the circuit by using HDLs. ASIC(Application Specific IC) is a very complex which may consist of millions of transistors. So, we need concurrent execution first of all. Apart from that, we need timing information and other complex features of the digital system too.

7. VHDL is based on which of the following programming languages?
a) ADA programming language
b) C
c) Assembly
d) PHP
Answer: a
Explanation: The syntax and whole structure of VHDL code is based upon ADA programming language whereas Verilog HDL finds its origin from C language.

8. What is the advantage of using VHDL instead of any other HDL?
a) Week typing
b) Based on ADA
c) Portability
d) Easy to code
Answer: c
Explanation: A circuit specified in VHDL can be implemented in different chips and is compatible with CAD tools provided by all companies. Therefore, without any modification, we can use VHDL code anywhere. This is the biggest advantage because digital circuit technology changes rapidly.

9. Which of the following is a characteristic of VHDL?
a) Case sensitive
b) Use of simple data types
c) Based on C programming language
d) Strongly typed language
Answer: d
Explanation: VHDL is a strongly typed language i.e. we have to write a long code to define operations.

10. Which of the following is a characteristic of Verilog HDL?
a) Strongly typed language
b) Case sensitive
c) Better library
d) Not portable
Answer: b
Explanation: Verilog HDL is a case sensitive language which means ‘a’ and ‘A’ means different if you are coding in Verilog.

Common Terms used in VHDL

1. Which of the following is the basic building block of a design?
a) Architecture
b) Entity
c) Process
d) Package
Answer: b
Explanation: Entity is the basic building block; all the information regarding input and output of the circuit to be designed is declared in Entity.

2. A package in VHDL consists of _________
a) Commonly used architectures
b) Commonly used tools
c) Commonly used data types and subroutines
d) Commonly used syntax and variables
Answer: c
Explanation: Package is a collection of all the commonly used data types and subroutines so that programmers can easily use them in their design without defining the same functions again and again.

3. Complete description of the circuit to be designed is given in _________
a) Architecture
b) Entity
c) Library
d) Configurations
Answer: a
Explanation: Architecture completely describes the circuit; while entity describes just the input and output of the design. Architecture may describe the behavior of the circuit or its structure.

4. An entity can have more than one architecture.
a) True
b) False
Answer: a
Explanation: Yes, An entity can have more than one architecture. One may define its behaviour and other may define its structure or dataflow. But, the converse of this statement is not true i.e. One architecture can’t define more than one entities.

5. What is the use of the Configuration statement?
a) To configure the components exactly in design
b) To complete the design process by adding libraries
c) To add more than one entities into a single architecture
d) To add some component in any entity architecture pair
Answer: d
Explanation: Configuration statement is used to bind any component instance with entity architecture pair. It is used to describe the behavior, which is used in almost each entity.

6. In VHDL, Bus is a type of ________
a) Signal
b) Constant
c) Variable
d) Driver
Answer: a
Explanation: Bus is a special kind of signal. It may have its drivers turned off.

7. What is the use of Generics in VHDL?
a) To turn on and off the drivers
b) To pass information to the entity
c) To describe architecture
d) To divide code into small processes
Answer: b
Explanation: Generics are used to pass the information to entity through parameters. In short, Generics are parameters which passes information to entity. For example, entity has variables for rise time and fall time delay; then the values for both delays can be passed by using Generics.

8. Driver can be seen as a _______ of the signal.
a) Part
b) Type
c) Final value
d) Source
Answer: d
Explanation: Driver is a source on the signal. All of the signals are driven by their Drivers. Any signal may have more than one driver too.

9. Predefined data for an VHDL object is called ________
a) Generic
b) Constant
c) Attribute
d) Library
Answer: c
Explanation: Attribute is the predefined datatype associated with any VHDL object. For example, operating temperature of any device will be its attribute.

10. A process is the basic unit of execution in VHDL.
a) True
b) False
Answer: a
Explanation: All the operations in the VHDL description are divided into processes during simulation and therefore, Process is the basic unit of execution.

11. Which of the following describes the structure of VHDL code correctly?
a) Library Declaration; Entity Declaration; Architecture Declaration; Configurations
b) Entity Declaration; Configuration; Library Declaration; Architecture Declaration
c) Configuration; Library Declaration; Entity Declaration; Architecture Declaration
d) Library Declaration; Configuration; Entity Declaration; Architecture Declaration
Answer: a
Explanation: In any VHDL code, first of all, we have to define libraries and packages we want to use. After Library Declaration part, Entities are declared. When Entities are created, then only we can describe its architecture. Last part in any VHDL code is Configuration.

12. Which of the following statement is true?
a) Package is a collection of Libraries
b) Library is a collection of Packages
c) Entity is a collection of Packages
d) Architecture is a collection of Entities
Answer: b
Explanation: A library consists of many packages which in turn is a collection of data types and subroutines. Entity is a collection of signals and variables and architecture describes the behavior or structure of Entity.

13. Which of the following is used at the end of a statement?
a) ; (Semicolon)
b) — ( double hyphen)
c) _ (underscore)
d) No sign is used at the end of statement
Answer: a
Explanation: Semicolon is the sign used at the end of any statement. Double hyphen is used for writing a comment which means wherever we have a sign of double hyphen(–), the simulator will skip that line and start compiling from the next line.

14. Which of the following is correctly declared library for VHDL code?
a)

LIBRARY library_name;
USE package_name.parts;

b)

LIBRARY package_name.parts;
LIBRARY library_name;

c)

USE library_name;
LIBRARY library_name.package_name.parts

d)

LIBRARY library_name;
USE library_name.package_name.parts

Answer: d
Explanation: Library declaration is completed in two lines. First line declares the library and in second line we use ‘USE’ clause to define the package name we want to use from the respective library and the parts we want to use. For example, LIBRARY ieee; USE ieee.std_logic_1164.all; In this declaration, ieee is library and std_logic_1164 package is used; all in package part section specifies that all parts of package are used.

15. One can’t use more than one library in the VHDL code.
a) True
b) False
Answer: b
Explanation: There is no restriction on the number of libraries we want to use. One can define more than one library in VHDL code.

Entity and Its Declaration

1. Which of the following is not defined by the entity?
a) Direction of any signal
b) Names of signal
c) Different ports
d) Behavior of the signals
Answer: d
Explanation: Entity specifies the name of the entity, the ports of the entity and all the information related to that entity. All designs are created using one or more entities. Declaration of ports in an entity includes the name of signals and there directions.

2. Which of the following can be the name of an entity?
a) NAND
b) Nand_gate
c) Nand gate
d) AND
Answer: b
Explanation: The name of entity can be basically any name, except VHDL reserved words. NAND is reserved for nand operation and same applies for AND. The name of entity can’t contain any space character. Therefore, only option b is the only legal word.

3. Which of the following is correct syntax for entity declaration?
a)

ENTITY entity_name IS
    PORT( signal_names : signal_modes;
    signal_names : signal_modes);
   END entity_name;

b)

 ENTITY entity_name
    PORT( signal_names : signal_modes;
    signal_names : signal_modes);
   END ENTITY;

c)

ENTITY entity_name IS
    PORT port_name
    ( signal_names : signal_modes signal_type;
    signal_names : signal_modes signal_type);
   END entity_name;

d)

ENTITY entity_name
    PORT port_name
    (signal_names : signal_modes;
    signal_names : signal_modes);
   END ENTITY;

Answer: a
Explanation: The correct syntax for declaring an entity block starts with reserve word ENTITY followed by name of entity and the next is reserve word IS. Name of entity can contain letters, numbers and underscore character. After this, PORT declaration is used. PORT declaration is used to declare the interface signals for the entity and to assign mode and type of data. The declaration is completed by using END operator and the entity name.

4. Refer to the VHDL code given below, how many input-output pins are there in MUX entity?

ENTITY mux IS
Port ( a,b : IN STD_LOGIC;
Y : OUT STD_LOGIC);
END mux;

a) 5
b) 4
c) 3
d) 2
Answer: c
Explanation: In the given declaration, entity has 3 I/O pins. The signals a and b are Input signals and y is the output signal. So, we can say that the declaration is for 2:1 MUX. In this way, we can find the number of I/O pins from the entity declaration.

5. The entity name ‘xyz’ and ‘XYZ’ will be treated the same.
a) True
b) False
Answer: a
Explanation: VHDL is a strongly typed language which means that there are very strict rules regarding the data types. But, there is no difference between names of entity. VHDL is not case sensitive therefore, ‘xyz’ and ‘XYZ’ are same.

6. Which of the following mode of the signal is bidirectional?
a) IN
b) OUT
c) INOUT
d) BUFFER
Answer: c
Explanation: INOUT is the only bidirectional mode for any signal. IN, OUT and BUFFER are unidirectional mode since they specifies the type to be either input or output. INOUT can be used as both an input to an entity and as an output of the entity. We can read as well as assign the value for INOUT type signal.

7. In an assignment statement, OUT signal can be used only to the ___________
a) Left of <= operator
b) Right of <= operator
c) Any side of <= operator
d) Right of := operator
Answer: a
Explanation: OUT signal is used to take an output from any entity. Therefore, we can assign it any value but can’t read any value from this type of signal. So, in an assignment statement, OUT type signal can be used on the left side of <= operator.

8. On which side of assignment operator, we can use the IN type signal?
a) Left
b) Right
c) Both
d) Can’t be used
Answer: b
Explanation: IN signal is for input only. We can read the value from IN signal. Therefore, it can be placed only on the right side of assignment.

9. What is the difference between OUT and BUFFER?
a) BUFFER can’t be used inside the entity for reading the value and OUT can be
b) BUFFER can only be read whereas OUT can only be assigned a value
c) BUFFER can be read as well as assigned a value but OUT can only be assigned
d) Both are same
Answer: c
Explanation: BUFFER is a unidirectional mode used as an output from the entity. But, the value of BUFFER can be used inside the entity i.e. it can appear on both sides of assignment operator whereas the value of OUT can’t be used inside the entity and can appear on the left side of assignment operator.

10. GENERICs are not declared in the entity.
a) True
b) False
Answer: b
Explanation: The declaration of GENERICs is also done in the entity itself. It is used to declare the constants that can be used to control the structure of behavior of the entity. The Generics are declared before port declarations.

11. Which of the following is an entity declared for a full adder?
a)

ENTITY full_adder IS
    PORT(a, b, c : IN BIT;
    s, co : OUT BIT);
   END full_adder;

b)

ENTITY full_adder IS
    PORT (a ,b : IN BIT;
    s, c : OUT BIT);
    END full_adder;

c)

ENTITY full_adder
    PORT(a, b, c : IN BIT;
    s, co : OUT BIT);
   END full_adder;

d)

ENTITY full_adder IS
    PORT (a, b, c, s, co : BIT);
    END full_adder;

Answer: a
Explanation: A full adder has three inputs and two outputs. Inputs are two bits to be added and some carry. Outputs are sum and carry. Therefore, option a shows the correct declaration of entity full_adder. In this, a and b are the bits to be added and c is the input carry whereas, s is the sum output and co is the carry output.

12. How to control the structure and timing of the entity can be changed?
a) By using TIME variable in the entity
b) By changing the entity declaration from time to time
c) By using some special code
d) By using GENERICS
Answer: d
Explanation: The structure and timing constraints can be changed by declaring some constant using GENERICS declaration. For example, in the full adder example, number of bits to be added can be declared as array with its size N. this N can be declared as a constant in the GENERIC declaration part of entity. By changing N only, one can change number of bits for the addition.

13. Which of the following can have more than one driver?
a) IN
b) OUT
c) INOUT
d) BUFFER
Answer: c
Explanation: INOUT is the only bidirectional signal. This mode can have more than one driver. Therefore, INOUT can be driven by more than one drivers. All other modes like IN, OUT, BUFFER can have only one driver.

14. Which of the following is the default mode for a port variable?
a) IN
b) OUT
c) INOUT
d) BUFFER
Answer: a
Explanation: IN is the default mode for a port variable. If the mode of any signal is not specified in the port declaration, then it is considered as IN type signal. All other types are needed to be specified at the time of declaration.

Architecture

1. What does the architecture of an entity define?
a) External interface
b) Internal functionality
c) Ports of the entity
d) Specifications
Answer: b
Explanation: Basically, entity describes the interface to the VHDL model and its architecture describes the internal view of that entity. It describes the functionality and contains the statements which describe the behavior of entity.

2. Which of the following is the correct syntax for architecture declaration and definition?
a)

ARCHITECTURE architecture_type OF entity_name IS
     Declarations_for_architecture;
     BEGIN
     Code;
     ….
    END architecture_name;

b)

ARCHITECTURE architecture_name OF entity_name IS
     BEGIN
     Declarations_for_architecture;
     Code;
     ….
    END architecture_name;

c)

ARCHITECTURE architecture_type OF entity_name IS
     BEGIN
     Declarations_for_architecture;
     Code;
     ….
    END architecture_type;

d)

ARCHITECTURE architecture_name OF entity_name IS
     Declarations_for_architecture
     BEGIN
     Code;
     ….
     END architecture_name;

Answer: d
Explanation: Architecture has two parts which are declarative part and the code part containing concurrent and sequential statements. Declaration part is optional but the code part is essential. The declaration of architecture is started with the keyword ARCHITECTURE followed by its name and then the name of entity. Then, the declaration part is used to declare and then BEGIN keyword is used to start the code part.

3. What does the declarative part of architecture contain?
a) Declaration of another entity
b) Declaration of libraries and packages
c) Declaration of local signals, constants or subprograms
d) Declaration of Architecture type
Answer: c
Explanation: Declarative part is the optional part of architecture definition. In this section, the local signals, constants, variables or subprograms are declared which are needed in the architecture. The scope of variables declared in this region is limited to the architecture only.

4. The statements in between the keyword BEGIN and END are called _______
a) Concurrent statements
b) Netlist
c) Declaration statement
d) Entity function
Answer: a
Explanation: The proper word for the statements between BEGIN and END is Concurrent statements since they are executed concurrently. The code in between BEGIN and END describes the functionality or structure of the entity. BEGIN keyword specifies the starting of code.

5. Which of the following is the correct architecture for a simple Nand gate?
a)

ARCHITECTURE my_arch OF nand_gate IS
    BEGIN
    x <= a NAND b;
    END my_arch;

b)

BEGIN
     ARCHITECTURE my_arch OF nand_gate IS
    x <= a NAND b;
    END behavioral;

c)

BEGIN
    ARCHITECTURE behavioral OF nand_gate IS
    x <= a NAND b;
    END my_arch;

d)

ARCHITECTURE nand OF nand_gate IS
    BEGIN
    x <= a NAND b;
    END nand;

Answer: a
Explanation: For correct syntax, the word ARCHITECTURE must be followed by the name of architecture which may not contain the reserved words. After which BEGIN keyword is used to show the beginning of code section of the architecture and at last END keyword is used followed by name of architecture. Therefore, only option a is correct architecture of NAND gate explaining its functionality.

6. Which of the following can be the name of an architecture?
a) arch 1
b) 1arch
c) arch_1
d) architecture
Answer: c
Explanation: The name of architecture is its identifier and hence, it will follow the same rule as that of identifiers. It may contain alphanumeric characters and underscore character starting with alphabet always. Also, name can’t be same as any of the reserved word of VHDL.

7. An entity can’t be described by more than one architecture.
a) True
b) False
Answer: b
Explanation: It is false that an entity can’t have two or more architectures. An entity can be described by using more than one architecture. For an instance, one can define its behavior and another can explain its structure. However, the converse of the statement is not true, one architecture can describe only one entity.

8. Which of the following can’t be declared in the declaration part of the architecture?
a) Signals
b) Subprograms
c) Components
d) Libraries
Answer: d
Explanation: In the declaration part of architecture, the local data objects and subprograms are defined which can be used in the architecture only. However, a library contains packages which are generally used in every VHDL model and they are declared globally at the starting of VHDL code.

9. It is not possible to declare an entity after declaring its architecture.
a) True
b) False
Answer: a
Explanation: An entity is required first to describe its architecture. First of all, entity create an external interface of the system after which we can describe the internal view of entity. Until there is no entity, architecture declaration is not possible.

10. Which of the following statements execute faster?
a) Sequential statements
b) Concurrent statements
c) Declaration statements
d) Loop statements
Answer: b
Explanation: Concurrent statements execute faster than sequential statements. Sequential statements are those which are executed one after another whereas concurrent statements execute concurrently or simultaneously. Therefore, concurrent are faster.

Up To Date Introduction to VHDL ( VHDL ) MCQs – VHDL MCQs