This repository has been archived by the owner on Aug 19, 2024. It is now read-only.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR is partially to demonstrate that Verilator 5.004 (and probably 5.002 but I haven't tested it) does not work with the Verilator JNA stuff. I have debugged a bit, here's what I know:
Individual tests or tests that pass seem to work, but if you have multiple tests in a row in the same JVM, it will hang when trying to close the
NativeLibrary
on this line:chiseltest/src/main/scala/chiseltest/simulator/jna/JNAUtils.scala
Line 136 in 78b0f28
Verilator 5 added support for SystemVerilog timing constructs, so my understanding is that it's a massive change to the underlying threading implementation.
My suspicion is that something has changed about how we should terminate the simulation--that there's some child thread running that isn't being stopped and is preventing JNA from closing the shared library. This is purely conjecture though, so take it with a grain of salt.