Skip to content

Commit 6600ac3

Browse files
Merge branch 'develop' into _update-deps/runtimeverification/llvm-backend
2 parents 81be237 + a3dcde1 commit 6600ac3

File tree

2 files changed

+26
-0
lines changed

2 files changed

+26
-0
lines changed

pyk/src/pyk/ktool/krun.py

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,8 @@ def run_process(
7878
pipe_stderr: bool = True,
7979
bug_report: BugReport | None = None,
8080
debugger: bool = False,
81+
save_temps: bool = False,
82+
statistics: bool = False,
8183
) -> CompletedProcess:
8284
with self._temp_file() as ntf:
8385
pgm.write(ntf)
@@ -94,6 +96,8 @@ def run_process(
9496
pmap=pmap,
9597
term=term,
9698
temp_dir=self.use_directory,
99+
save_temps=save_temps,
100+
statistics=statistics,
97101
no_expand_macros=not expand_macros,
98102
search_final=search_final,
99103
no_pattern=no_pattern,
@@ -113,6 +117,8 @@ def run_proof_hint(
113117
parser: str | None = None,
114118
term: bool = False,
115119
temp_dir: Path | None = None,
120+
save_temps: bool = False,
121+
statistics: bool = False,
116122
depth: int | None = None,
117123
expand_macros: bool = True,
118124
search_final: bool = False,
@@ -137,6 +143,8 @@ def run_proof_hint(
137143
cmap=cmap,
138144
term=term,
139145
temp_dir=temp_dir,
146+
save_temps=save_temps,
147+
statistics=statistics,
140148
no_expand_macros=not expand_macros,
141149
search_final=search_final,
142150
no_pattern=no_pattern,
@@ -216,6 +224,8 @@ def run(
216224
check: bool = False,
217225
pipe_stderr: bool = True,
218226
bug_report: BugReport | None = None,
227+
save_temps: bool = False,
228+
statistics: bool = False,
219229
debugger: bool = False,
220230
) -> None:
221231
result = self.run_process(
@@ -230,6 +240,8 @@ def run(
230240
output=output,
231241
pipe_stderr=pipe_stderr,
232242
bug_report=bug_report,
243+
save_temps=save_temps,
244+
statistics=statistics,
233245
debugger=debugger,
234246
)
235247

@@ -301,6 +313,8 @@ def _krun(
301313
pmap: Mapping[str, str] | None = None,
302314
term: bool = False,
303315
temp_dir: Path | None = None,
316+
save_temps: bool = False,
317+
statistics: bool = False,
304318
no_expand_macros: bool = False,
305319
search_final: bool = False,
306320
no_pattern: bool = False,
@@ -334,6 +348,8 @@ def _krun(
334348
cmap=cmap,
335349
term=term,
336350
temp_dir=temp_dir,
351+
save_temps=save_temps,
352+
statistics=statistics,
337353
no_expand_macros=no_expand_macros,
338354
search_final=search_final,
339355
no_pattern=no_pattern,
@@ -364,6 +380,8 @@ def _build_arg_list(
364380
cmap: Mapping[str, str] | None,
365381
term: bool,
366382
temp_dir: Path | None,
383+
save_temps: bool,
384+
statistics: bool,
367385
no_expand_macros: bool,
368386
search_final: bool,
369387
no_pattern: bool,
@@ -389,6 +407,10 @@ def _build_arg_list(
389407
args += ['--term']
390408
if temp_dir:
391409
args += ['--temp-dir', str(temp_dir)]
410+
if save_temps:
411+
args += ['--save-temps']
412+
if statistics:
413+
args += ['--statistics']
392414
if no_expand_macros:
393415
args += ['--no-expand-macros']
394416
if search_final:

pyk/src/tests/unit/ktool/test_krun.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@
1919
('cmap', None),
2020
('term', False),
2121
('temp_dir', None),
22+
('save_temps', False),
23+
('statistics', False),
2224
('no_expand_macros', False),
2325
('search_final', False),
2426
('no_pattern', False),
@@ -37,6 +39,8 @@
3739
'cmap': ({'COO': 'car', 'FUZZ': 'bill'}, ['-cCOO=car', '-cFUZZ=bill']),
3840
'term': (True, ['--term']),
3941
'temp_dir': (Path('/tmp/path'), ['--temp-dir', '/tmp/path']),
42+
'save_temps': (True, ['--save-temps']),
43+
'statistics': (True, ['--statistics']),
4044
'no_expand_macros': (True, ['--no-expand-macros']),
4145
'search_final': (True, ['--search-final']),
4246
'no_pattern': (True, ['--no-pattern']),

0 commit comments

Comments
 (0)