diff options
author | tgingold <tgingold@users.noreply.github.com> | 2022-12-31 13:53:58 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-12-31 13:53:58 +0100 |
commit | 9521df67d938896f71c2ca284720b131879406d6 (patch) | |
tree | 0dfa358d3e7eb78393518395e3b3ebcc066be8e8 /pyGHDL/cli | |
parent | da0cd6274648094a7ab8876cc59f7ac05b8d56e7 (diff) | |
parent | 882563d217d364d38a362d39bc34b7a6f16ce726 (diff) | |
download | ghdl-9521df67d938896f71c2ca284720b131879406d6.tar.gz ghdl-9521df67d938896f71c2ca284720b131879406d6.tar.bz2 ghdl-9521df67d938896f71c2ca284720b131879406d6.zip |
Merge pull request #2289 from Paebbels/paebbels/pyVHDLModel-updates
Updates due to pyVHDLModel Enhancements
Diffstat (limited to 'pyGHDL/cli')
-rwxr-xr-x | pyGHDL/cli/dom.py | 25 |
1 files changed, 16 insertions, 9 deletions
diff --git a/pyGHDL/cli/dom.py b/pyGHDL/cli/dom.py index 68bd33c34..442ad6688 100755 --- a/pyGHDL/cli/dom.py +++ b/pyGHDL/cli/dom.py @@ -280,11 +280,11 @@ class Application(LineTerminal, ArgParseMixin): ) ) elif args.Directory is not None: - d: Path = args.Directory + d: Path = args.Directory.resolve() if not d.exists(): self.WriteError(f"Directory '{d!s}' does not exist.") - for file in d.glob("**/*.vhd?"): + for file in d.glob("**/*.vhd*"): self.WriteNormal(f"Parsing file '{file!s}'") document = self.addFile(file, "pretty") self.WriteInfo( @@ -299,16 +299,23 @@ class Application(LineTerminal, ArgParseMixin): ) ) - for library in self._design.Libraries.values(): - for entityName, architectures in library.Architectures.items(): - for entity in library.Entities: - if entity.Identifier == str(entityName): - for architecture in architectures: - entity.Architectures.append(architecture) - if not self._design.Documents: self.WriteFatal("No files processed at all.") + self._design.LoadDefaultLibraries() + self._design.Analyze() + self.WriteInfo( + dedent( + """\ + default library load time: {:5.3f} us + dependency analysis time: {:5.3f} us + """ + ).format( + self._design._loadDefaultLibraryTime * 10**6, + self._design._analyzeTime * 10**6, + ) + ) + PP = PrettyPrint() buffer = [] |