-
Notifications
You must be signed in to change notification settings - Fork 268
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
failed to find a primary design unit 'all' #857
Comments
@asicnet This is something that we've discussed before but I failed to find where. When you know what package the file depends on then you also know what file it depends on (the one defining the package) and then you have a dependency = compile order between those files. When you depend on everything in a library you can't simply find out what files you depend on and what a correct compile order is. That requires a much better parser than the regexp analysis VUnit is using. |
Hi |
When VUnit sees use ieee.std_logic_1144; -- This is legal
...
signal foo : std_logic_1164.std_logic; -- but forces you to be more explicit when things are used from std_logic_1164 Without any support for When you say "prevent" do you mean preventing this specific warning from ever be produced or do you mean VUnit shouldn't allow you to have such references at all? I guess you mean the first as the second wouldn't solve the problem. Generally speaking we recognize that there are legal VHDL styles that we do not support because it requires too much parsing. We do not forbid them because they are legal. Instead we provide workarounds to deal with those situations, in this case the workaround is to use the Another approach would be to automatically create a dependency between the file containing Suppression would be an option (once the problem has been dealt with) but this is too much corner case-ish to be awarded an option in the command line. In that case it would be a configuration that can be set in the run script. |
Hi In an other case i define a dict within init , count the same warnings and suppress this warning after 3 occurrences, because I then know the problem and do not overlook other important warnings. Maybe this is an acceptable implementation for you. Example:
|
What about this solution. The logger in project.py is public (although not documented) so you can apply a logger filter with an arbitrary rule for message suppression. For example: from logging import Filter
from vunit.project import LOGGER
class MyFilter(Filter):
def __init__(self):
self._warning_count = 0
def filter(self, record):
if "failed to find a primary design unit 'all'" in record.getMessage():
self._warning_count += 1
if self._warning_count > 3:
return False
return True
LOGGER.addFilter(MyFilter()) |
See #1080 |
Hi
we have big designs with a lot of this warnings
the syntax is
use library_name.package_name.all;
but a lot of designer use it for the library itself
use library_name.all;
For the compiler is this no problem. I think no desinger create a " package all is ...."
so is it possible to change within the project.py
The text was updated successfully, but these errors were encountered: