| Login | | Don't have an account yet? You can create one. As a registered user you have some advantages like theme manager, comments configuration and post comments with your name. | |
| Who's Online | There are currently, 38 guest(s) and 1 member(s) that are online.
You are Anonymous user. You can register for free by clicking here | |
 | |
|
Verification Guild: Forums |
|
| View previous topic :: View next topic |
| Author |
Message |
Martin1234 Senior


Joined: Jan 27, 2004 Posts: 110
|
Posted: Wed Dec 21, 2011 4:58 pm Post subject: VMM clocking blocks and non-blocking assignments |
|
|
I am looking at the following code example from the VMM user guide:
| Code: |
foreach (bytes[i]) begin
...
@(this.sigs.mtx);
this.sigs.mtx.txd <= nibble;
...
end
|
If I want to debug something like this in the logfile, I will add `vmm_debug "statements":
| Code: |
foreach (bytes[i]) begin
...
@(this.sigs.mtx);
`vmm_debug(log,"Driving %0h",nibble);
this.sigs.mtx.txd <= nibble;
...
end
|
It looks like the timestamp in the logfile and time of the actual application of the value on the signal will be off by one clock cycle. Am I seeing this correctly? |
|
| Back to top |
|
 |
Tejasaurus Newbie


Joined: Mar 07, 2012 Posts: 4
|
Posted: Thu Mar 08, 2012 1:22 am Post subject: |
|
|
| Interesting. So if the `vmm_debug statement is executed at system-clock time 't', you saying that this.sigs.mtx.txd gets assigned at system-clock time 't+1'? Does the waveforms say this? |
|
| Back to top |
|
 |
dave_59 Senior


Joined: Jun 22, 2004 Posts: 974 Location: Fremont, CA
|
Posted: Thu Mar 08, 2012 10:29 am Post subject: |
|
|
Assuming mtx is the name of a clocking block, | Code: | | this.sigs.mtx.txd <= nibble; | is not a non-blocking assignment. It is a clocking block synchronous drive. The actual application of the assignment is defined by the clocking block. |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
| |
|
|