Skip to content

Default to using self.cancellation_manager #115

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Sep 7, 2022
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
3 changes: 3 additions & 0 deletions compiler_opt/rl/inlining/inlining_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,9 @@ def compile_fn(
cancelled work.
RuntimeError: if llvm-size produces unexpected output.
"""
if cancellation_manager is None:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why even pass it as an arg, why not we remove it from the arglist and use self._cancellation_manager?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

changed it, prob should check with yundi@ to see if that's an ok thing to do

cancellation_manager = self._cancellation_manager

working_dir = tempfile.mkdtemp()

log_path = os.path.join(working_dir, 'log')
Expand Down
3 changes: 3 additions & 0 deletions compiler_opt/rl/regalloc/regalloc_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,9 @@ def compile_fn(
cancelled work.
RuntimeError: if llvm-size produces unexpected output.
"""
if cancellation_manager is None:
cancellation_manager = self._cancellation_manager

working_dir = tempfile.mkdtemp()

log_path = os.path.join(working_dir, 'log')
Expand Down