Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.Sign up
Reading free memory after unrolling a gen loop #1386
Author Name: Al Grant
Original Assignee: Wilson Snyder (@wsnyder)
valgrind memcheck shows a use-after-free issue.
As far as I can tell from the memcheck report and the debug trace, it looks like the unroller, when finished, deletes the 'for' node, but a later traversal then reaches something that was deleted.
This also shows up with verilator_bin_dbg, with better quality source info, but it needs --no-debug-leak.
Original Redmine Comment
This is caused by the B reference, but that's supported the code valgrind sees is actually looking for interfaces so the mis-reference is unlikely to cause real problems. Fix is non-trivial but will get to it shortly.