From 3b552c54d429e2af464dad53a9ef2994f9853f60 Mon Sep 17 00:00:00 2001 From: Henrik Wachowitz Date: Tue, 17 Dec 2024 22:29:58 +0100 Subject: [PATCH 1/3] update spf to BaseTool2 --- benchexec/tools/spf.py | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/benchexec/tools/spf.py b/benchexec/tools/spf.py index 297b9b8d9..0a9eb763b 100644 --- a/benchexec/tools/spf.py +++ b/benchexec/tools/spf.py @@ -5,12 +5,11 @@ # # SPDX-License-Identifier: Apache-2.0 -import benchexec.util as util -import benchexec.tools.template import benchexec.result as result +import benchexec.tools.template -class Tool(benchexec.tools.template.BaseTool): +class Tool(benchexec.tools.template.BaseTool2): """ Tool info for JPF with symbolic extension (SPF) """ @@ -25,8 +24,8 @@ class Tool(benchexec.tools.template.BaseTool): "jpf-sv-comp", ] - def executable(self): - return util.find_executable("jpf-sv-comp") + def executable(self, tool_locator): + return tool_locator.find_executable("jpf-sv-comp") def name(self): return "SPF" @@ -39,11 +38,12 @@ def version(self, executable): first_line = output.splitlines()[0] return first_line.strip() - def cmdline(self, executable, options, tasks, propertyfile, rlimits): - options = options + ["--propertyfile", propertyfile] - return [executable] + options + tasks + def cmdline(self, executable, options, tasks, rlimits): + options = options + ["--propertyfile", tasks.property_file] + return [executable] + options + list(tasks.input_files_or_identifier) - def determine_result(self, returncode, returnsignal, output, isTimeout): + def determine_result(self, run): + output = run.output # parse output status = result.RESULT_UNKNOWN From dd61ae1cee64acc6315f859712841d4062eede02 Mon Sep 17 00:00:00 2001 From: Henrik Wachowitz Date: Wed, 18 Dec 2024 11:15:52 +0100 Subject: [PATCH 2/3] remove support for identifier --- benchexec/tools/spf.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchexec/tools/spf.py b/benchexec/tools/spf.py index 0a9eb763b..dc2480340 100644 --- a/benchexec/tools/spf.py +++ b/benchexec/tools/spf.py @@ -40,7 +40,7 @@ def version(self, executable): def cmdline(self, executable, options, tasks, rlimits): options = options + ["--propertyfile", tasks.property_file] - return [executable] + options + list(tasks.input_files_or_identifier) + return [executable] + options + list(tasks.input_files) def determine_result(self, run): output = run.output From dc0c97db730f4a5576ebabb6deea2f0413c2c341 Mon Sep 17 00:00:00 2001 From: Philipp Wendler <2545335+PhilippWendler@users.noreply.github.com> Date: Wed, 18 Dec 2024 13:55:25 +0100 Subject: [PATCH 3/3] Rename parameter in benchexec/tools/spf.py --- benchexec/tools/spf.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/benchexec/tools/spf.py b/benchexec/tools/spf.py index dc2480340..c92905132 100644 --- a/benchexec/tools/spf.py +++ b/benchexec/tools/spf.py @@ -38,9 +38,9 @@ def version(self, executable): first_line = output.splitlines()[0] return first_line.strip() - def cmdline(self, executable, options, tasks, rlimits): - options = options + ["--propertyfile", tasks.property_file] - return [executable] + options + list(tasks.input_files) + def cmdline(self, executable, options, task, rlimits): + options = options + ["--propertyfile", task.property_file] + return [executable] + options + list(task.input_files) def determine_result(self, run): output = run.output