Skip to content

Commit 44a1e63

Browse files
author
Andrija Kolic
committed
[GR-60459] Add file existence check after 'instrument-run' stage
PullRequest: graal/19593
2 parents 6579e43 + fb98635 commit 44a1e63

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

vm/mx.vm/mx_vm_benchmark.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1240,6 +1240,13 @@ def run_stage_instrument_run(self):
12401240
with self.get_stage_runner() as s:
12411241
exit_code = s.execute_command(self, image_run_cmd)
12421242
if exit_code == 0:
1243+
if not self.config.profile_path.exists():
1244+
# The shutdown hook does not trigger for certain apps (GR-60456)
1245+
mx.abort(
1246+
f"Profile file {self.config.profile_path} does not exist "
1247+
f"even though the instrument run terminated successfully with exit code 0. "
1248+
f"A workaround might be possible by setting the 'ProfilingDumpPeriod' runtime option."
1249+
)
12431250
print(f"Profile file {self.config.profile_path} sha1 is {mx.sha1OfFile(self.config.profile_path)}")
12441251
self._ensureSamplesAreInProfile(self.config.profile_path)
12451252
else:

0 commit comments

Comments
 (0)