Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions src/dvsim/job/deploy.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
from dvsim.job.time import JobTime
from dvsim.launcher.base import Launcher
from dvsim.logging import log
from dvsim.sim_utils import get_cov_summary_table
from dvsim.tool.utils import get_sim_tool_plugin
from dvsim.utils import (
clean_odirs,
find_and_substitute_wildcards,
Expand Down Expand Up @@ -813,7 +813,11 @@ def callback(status: str) -> None:
if self.dry_run or status != "P":
return

results, self.cov_total = get_cov_summary_table(self.cov_report_txt, self.sim_cfg.tool)
plugin = get_sim_tool_plugin(tool=self.sim_cfg.tool)

results, self.cov_total = plugin.get_cov_summary_table(
cov_report_path=self.cov_report_txt,
)

colalign = ("center",) * len(results[0])
self.cov_results = tabulate(
Expand Down
14 changes: 5 additions & 9 deletions src/dvsim/launcher/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

from dvsim.job.time import JobTime
from dvsim.logging import log
from dvsim.sim_utils import get_job_runtime, get_simulated_time
from dvsim.tool.utils import get_sim_tool_plugin
from dvsim.utils import clean_odirs, mk_symlink, rm_path

if TYPE_CHECKING:
Expand Down Expand Up @@ -339,11 +339,10 @@ def _find_patterns(patterns: Sequence[str], line: str) -> Sequence[str] | None:
# since it is devoid of the delays incurred due to infrastructure and
# setup overhead.

plugin = get_sim_tool_plugin(tool=self.job_spec.tool)

try:
time, unit = get_job_runtime(
log_text=lines,
tool=self.job_spec.tool,
)
time, unit = plugin.get_job_runtime(log_text=lines)
self.job_runtime.set(time, unit)

except RuntimeError as e:
Expand All @@ -354,10 +353,7 @@ def _find_patterns(patterns: Sequence[str], line: str) -> Sequence[str] | None:

if self.job_spec.job_type == "RunTest":
try:
time, unit = get_simulated_time(
log_text=lines,
tool=self.job_spec.tool,
)
time, unit = plugin.get_simulated_time(log_text=lines)
self.simulated_time.set(time, unit)

except RuntimeError as e:
Expand Down
282 changes: 0 additions & 282 deletions src/dvsim/sim_utils.py

This file was deleted.

Loading
Loading