English 中文(简体)
VHDL - When does a process() run for the first time?
原标题:

Consider : process(a) According to the text i have :

A process is first entered at the time of simulation, at which time it is executed until it suspends itself due to a wait statement or a sensitivity list.

Am i right in inferring that a process WILL have to run once even without any events on the sensitivity list? Also, what if there are multiple processes inside an architecture, are they all executed once?

问题回答

AFAIK, the sensitivity list (eg, process (x,y) )is just a shorthand for wait on x,y; just before the end process of a procedure (pg 152, "A Designer s Guide to VHDL" 3rd edition). So all procedures will run at least once.

There are 3 stages involved in running a VHDL simulation. These are elaboration, initialisation and simulation.

At the beginning of the initialisation phase, the current time is set to 0. The simulation kernel then places all of the simulation processes in the active processes queue. Each simulation process is then taken from this queue and executed until it suspends. The order of execution of simuation processes during initialisation is not important. The initial execution of each simulation process ensures that all initial transactions are scheduled so that the simulation can continue.

A simulation process is suspended either implicity or explicity. A process with a sensitivity list is suspended implicity after its sequential statements have been executed to the end of the process. A process with one or more wait statements is suspended explicitly when its first wait statement is executed.

When the active processes queue is empty, the initialisation phase is complete.

So to answer your question, all processes will run once during the initialisation phase.





相关问题
Using Java to retrieve the CPU Usage for Window s Processes

I am looking for a Java solution to finding the CPU usage for a running process in Windows. After looking around the web, there seems to be little information on a solution in Java. Keep in mind, I am ...

What resources are shared between threads?

Recently, I have been asked a question in an interview what s the difference between a process and a thread. Really, I did not know the answer. I thought for a minute and gave a very weird answer. ...

Run a program from PowerShell with timeout

I ll write a script that runs a program and wait for it finished. But if the program is not finished within a specified time I want that the program is killed.

Bring window to foreground after Mutex fails

I was wondering if someone can tell me what would be the best way to bring my application to the foreground if a mutex was not able to be created for a new instance. E.g.: Application X is running ...

Limit the Number of Created Processes

I have two classes: Action class, that has a method for executing VBScript files, and Item class that contains a list of Action instances. My problem is that I want to limit the number of VBScript ...

if-statement always evaluates to TRUE

Is there any reason why this script always returns "running", regardless of whether my process is started or stopped? if ps ax | grep -v grep | grep "processName" > /dev/null then echo $"...

Python library for Linux process management [closed]

Through my web interface I would like to start/stop certain processes and determine whether a started process is still running. My existing website is Python based and running on a Linux server, so ...

热门标签