State the term- use a define function, Computer Engineering

Assignment Help:

State the term- Use a define function

This is almost exactly the same approach as #define and -D compiler arg that C programs use. In your  Verilog  code,  use  a  'define  to  define  the  variable  condition  and  then  use  Verilog preprocessor directives such as 'ifdef. Use the '+define+' Verilog command line option. For an illustration:

... to run the simulation ..

verilog testbench.v cpu.v +define+USEWCSDF

... in your code ...

'ifdef USEWCSDF

initial $sdf_annotate (testbench.cpu, "cpuwc.sdf");

'endif

+define+ can also be filled in from your Makefile invocation, which in turn, can be finally filled in your UNIX prompt command line.

Defines are a blunt weapon since they are very global and you can only do so much with them asthey are a pre-processor trick. Consider the subsequent approach before resorting to defines.

 


Related Discussions:- State the term- use a define function

First-order logic - artificial intelligence, First-Order Logic We, as h...

First-Order Logic We, as humans, have always prided ourselves on our ability to think things through for this reason things are out and come to the only conclusion possible in

What is layer, What is layer? A layered system is ordered set of virtua...

What is layer? A layered system is ordered set of virtual worlds. Every build-in terms of one's below it and providing the execution basis for one above it. The objects in ever

Network for digital methods in the arts and humanities, Network for Digital...

Network for Digital Methods in the Arts and Humanities: Europe has seen a signifi cant investment in the digitisation of its cultural heritage as part of the worldwide establi

Dfa, design a dfa which accept all the string over a and b ending with ab o...

design a dfa which accept all the string over a and b ending with ab or ba

Units of artificial neural networks, Units of artificial neural networks: ...

Units of artificial neural networks: However the input units simply output the value that was input to them from the example to be propagated. So every other unit in a network

Define a formal system, Q. Define a Formal System? A Formal System is o...

Q. Define a Formal System? A Formal System is one which is planned in advance and is used according to schedule. In this system procedures and policies are documented well in a

What are the steps in executing the program, What are the steps in executin...

What are the steps in executing the program? 1.Fetch 2.Decode 3.Execute 4.Store

Select statements linked to a logical database, One cannot use SELECT state...

One cannot use SELECT statements in a report program linked to a Logical Database   False. You can use th SELECT statements.

Result extends to functions - perceptrons, Result extends to functions - pe...

Result extends to functions - perceptrons: Thus the dotted lines can be seen as the threshold in perceptrons: whether the weighted sum, S, falls below it, after then the perce

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd