Skip to content
Open
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
19 changes: 9 additions & 10 deletions benchexec/tools/coastal.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,20 +5,19 @@
#
# 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 COASTAL
"""

REQUIRED_PATHS = ["coastal", "coastal-sv-comp"]

def executable(self):
return util.find_executable("coastal-sv-comp")
def executable(self, tool_locator):
return tool_locator.find_executable("coastal-sv-comp")

def name(self):
return "COASTAL"
Expand All @@ -31,15 +30,15 @@ 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, task, rlimits):
options = options + ["--propertyfile", task.property_file]
return [executable] + options + list(task.input_files_or_identifier)

def determine_result(self, returncode, returnsignal, output, isTimeout):
def determine_result(self, run):
# parse output
status = result.RESULT_UNKNOWN

for line in output:
for line in run.output:
if "UNSAFE" in line:
status = result.RESULT_FALSE_PROP
elif "SAFE" in line:
Expand Down
19 changes: 9 additions & 10 deletions benchexec/tools/java-ranger.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,17 @@
#
# 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 Java Ranger that is based on the symbolic extension (SPF) of Java PathFinder (JPF)
"""

def executable(self):
return util.find_executable("jr-sv-comp")
def executable(self, tool_locator):
return tool_locator.find_executable("jr-sv-comp")

def name(self):
return "Java Ranger"
Expand All @@ -29,15 +28,15 @@ 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, task, rlimits):
options = options + ["--propertyfile", task.property_file]
return [executable] + options + list(task.input_files_or_identifier)

def determine_result(self, returncode, returnsignal, output, isTimeout):
def determine_result(self, run):
# parse output
status = result.RESULT_UNKNOWN

for line in output:
for line in run.output:
if "UNSAFE" in line:
status = result.RESULT_FALSE_PROP
elif "SAFE" in line:
Expand Down
21 changes: 10 additions & 11 deletions benchexec/tools/jdart.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,17 @@
#
# 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 JDart modified by TU Dortmund
"""

def executable(self):
return util.find_executable("run-jdart.sh")
def executable(self, tool_locator):
return tool_locator.find_executable("run-jdart.sh")

def version(self, executable):
return self._version_from_tool(executable, arg="-v")
Expand All @@ -27,18 +26,18 @@ def name(self):
def project_url(self):
return "https://github.com/tudo-aqua/jdart"

def cmdline(self, executable, options, tasks, propertyfile, rlimits):
def cmdline(self, executable, options, task, rlimits):
cmd = [executable]
if options:
cmd = cmd + options
if propertyfile:
cmd.append(propertyfile)
return cmd + tasks
if task.property_file:
cmd.append(task.property_file)
return cmd + list(task.input_files_or_identifier)

def determine_result(self, returncode, returnsignal, output, isTimeout):
def determine_result(self, run):
# parse output
status = result.RESULT_UNKNOWN
for line in output:
for line in run.output:
if "== ERROR" in line:
status = result.RESULT_FALSE_PROP
elif "== OK" in line:
Expand Down
19 changes: 9 additions & 10 deletions benchexec/tools/jpf.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,17 @@

import os

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 (plain jpf-core)
"""

def executable(self):
return util.find_executable("bin/jpf-core-sv-comp")
def executable(self, tool_locator):
return tool_locator.find_executable("bin/jpf-core-sv-comp")

def version(self, executable):
jpf = os.path.join(os.path.dirname(executable), "jpf")
Expand All @@ -32,15 +31,15 @@ def name(self):
def project_url(self):
return "https://github.com/javapathfinder/jpf-core/"

def cmdline(self, executable, options, tasks, propertyfile, rlimits):
options = options + ["--propertyfile", propertyfile]
return [executable] + options + tasks
def cmdline(self, executable, options, task, rlimits):
options = options + ["--propertyfile", task.property_file]
return [executable] + options + list(task.input_files_or_identifier)

def determine_result(self, returncode, returnsignal, output, isTimeout):
def determine_result(self, run):
# parse output
status = result.RESULT_UNKNOWN

for line in output:
for line in run.output:
if "UNSAFE" in line:
status = result.RESULT_FALSE_PROP
elif "SAFE" in line:
Expand Down