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

Internal error when doing V3Simulate on for loop inside for loop #1044

Closed
veripoolbot opened this issue Mar 4, 2016 · 6 comments
Closed

Internal error when doing V3Simulate on for loop inside for loop #1044

veripoolbot opened this issue Mar 4, 2016 · 6 comments
Assignees

Comments

@veripoolbot
Copy link
Contributor

@veripoolbot veripoolbot commented Mar 4, 2016


Author Name: Jie Xu (@jiexu)
Original Redmine Issue: 1044 from https://www.veripool.org

Original Assignee: Wilson Snyder (@wsnyder)


Error: Internal Error: xxx.sv:472: ../V3Simulate.h:177: No value found for node.
%Error: Internal Error: See the manual and http://www.veripool.org/verilator for more assistance.

Not able to reproduce this with a small test case yet. But in our code, we have two embedded for-loop where the error occurs when try to simulate the condition of inner loop.

@veripoolbot
Copy link
Contributor Author

@veripoolbot veripoolbot commented Mar 4, 2016


Original Redmine Comment
Author Name: Johan Bjork
Original Date: 2016-03-04T18:41:47Z


Probably caused by my patch:
Fix unrolling complicated for-loop bounds, #�. [Johan Bjork]
Please let me know if you can find a way to reproduce it, otherwise a run with debug for V3Simulate might help as well.

@veripoolbot
Copy link
Contributor Author

@veripoolbot veripoolbot commented Mar 7, 2016


Original Redmine Comment
Author Name: Jie Xu (@jiexu)
Original Date: 2016-03-07T08:32:43Z


We have something like this

    always @(posedge clk) begin
        int i;
        int j;
        for (i = 0; i < MASK_NUM; i ++)
        begin
        for (j = 0; j < MASK[i]; j ++)   // the line which causes the internal error
        begin
            out[i*4+j] <= in[i*4+j];
        end
        end
    end

In the log of V3Simulate, it first reports

V3Simulate.h:112:   Clear optimizable: Language violation: reference to non-function-local variable: VARREF

for variable @j@, then it report the internal error.

Hope this helps for your debugging.

@veripoolbot
Copy link
Contributor Author

@veripoolbot veripoolbot commented May 7, 2016


Original Redmine Comment
Author Name: Wilson Snyder (@wsnyder)
Original Date: 2016-05-07T12:04:44Z


I took a look at this, is this still an issue? The attached doesn't seem to break, can you modify it to fail?

@veripoolbot
Copy link
Contributor Author

@veripoolbot veripoolbot commented Nov 29, 2016


Original Redmine Comment
Author Name: Jan Egil Ruud
Original Date: 2016-11-29T11:56:18Z


We've finally set aside some time to create a small test case for this issue. It all seems to be related to the size of the signals. If we reduce the size to 64 bits the error disappear.

@veripoolbot
Copy link
Contributor Author

@veripoolbot veripoolbot commented Nov 30, 2016


Original Redmine Comment
Author Name: Wilson Snyder (@wsnyder)
Original Date: 2016-11-30T01:42:59Z


Thanks for the test case, straight forward now that I know where to look.

Fixed in git towards 3.891.

@veripoolbot
Copy link
Contributor Author

@veripoolbot veripoolbot commented Apr 2, 2017


Original Redmine Comment
Author Name: Wilson Snyder (@wsnyder)
Original Date: 2017-04-02T13:04:13Z


Fixed back in 3.892.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.