Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

task call problem #78

Closed
veripoolbot opened this issue Apr 8, 2009 · 3 comments
Closed

task call problem #78

veripoolbot opened this issue Apr 8, 2009 · 3 comments
Assignees
Labels
resolution: fixed Closed; fixed

Comments

@veripoolbot
Copy link
Contributor


Author Name: Andrea Foletto
Original Redmine Issue: 78 from https://www.veripool.org
Original Date: 2009-04-08
Original Assignee: Wilson Snyder (@wsnyder)


Hi I got an error using the task and passing the data. It seems verilator doesn't like the structure that I used.
The file aoa.v contain the basic task (it's cut from a bigger source file) and here the error that I got:

verilator -cc aoa.v
%Error: aoa.v:34: Assigning to input variable: DDIFF_B
%Error: aoa.v:34: Assigning to input variable: DDIFF_B
%Error: aoa.v:34: Assigning to input variable: DDIFF_B
%Error: aoa.v:34: Assigning to input variable: DDIFF_B
%Error: Exiting due to 4 warning(s)
%Error: Command Failed verilator_bin -cc aoa.v

I modified the code assigning some operation to temporary register (tmp in file aoa_2.v) and now I got another error that I don't understand (blocked and non-blocking assigments):

verilator -cc aoa_2.v
%Warning-WIDTH: aoa_2.v:35: Operator DIV expects 9 bits on the RHS, but RHS's CONST generates 5 bits.
%Warning-WIDTH: Use "/* verilator lint_off WIDTH */" and lint_on around source to disable this message.
%Warning-WIDTH: aoa_2.v:36: Operator TASKREF expects 8 bits on the Function Argument, but Function Argument's VARREF generates 9 bits.
%Error-BLKANDNBLK: aoa_2.v:22: Unsupported: Blocked and non-blocking assignments to same variable: AOA_B
%Error: Exiting due to 3 warning(s)
%Error: Command Failed verilator_bin -cc aoa_2.v

Can you help me ?
Thanks Andrea

@veripoolbot
Copy link
Contributor Author


Original Redmine Comment
Author Name: Wilson Snyder (@wsnyder)
Original Date: 2009-04-08T15:55:15Z


I'll look at the error case.

The BLKANDNBLK is because you have this:

        always @(posedge CLK)
	         AOA_B <=
        always @*
       		AOA_B = // from inside the task

IE both a flop and gate driving the same net, which makes no sense.

@veripoolbot
Copy link
Contributor Author


Original Redmine Comment
Author Name: Wilson Snyder (@wsnyder)
Original Date: 2009-04-08T18:33:52Z


BTW ignore my last comment, I read what was a input and output backwards.

Both errors were due to the same bug, having the "output" first in the task list triggered a bug which eventually resulted in either error.

This is fixed in the git version.

@veripoolbot
Copy link
Contributor Author


Original Redmine Comment
Author Name: Wilson Snyder (@wsnyder)
Original Date: 2009-05-02T11:58:07Z


In 3.703.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
resolution: fixed Closed; fixed
Projects
None yet
Development

No branches or pull requests

2 participants