Skip to content
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

Replace O(N) lookup with O(1) for task outputs (master) #3351

Merged
merged 2 commits into from
Sep 7, 2019
Merged
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
7 changes: 6 additions & 1 deletion CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ variable `ISODATETIMEREF` (reference time for the `isodatetime` command from
[metomi-isodatetime](https://github.com/metomi/isodatetime/)) in task jobs to
have the same value as `CYLC_TASK_CYCLE_POINT`.

[#3286](https://github.com/cylc/cylc-flow/pull/3249) -
[#3286](https://github.com/cylc/cylc-flow/pull/3286) -
Removed the `cylc check-triggering` command.
Changed the `suite.rc` schema:
* Removed `[cylc]log resolved dependencies`
Expand All @@ -173,6 +173,11 @@ Changed the `suite.rc` schema:
`[cylc][[events]]abort if any task fails` so it lives with the other
`abort if/on ...` settings.

[#3351](https://github.com/cylc/cylc-flow/pull/3351) - sped up suite validation
(which also affects responsiveness of suite controllers during suite startup,
restarts, and reloads). Impact of the speedup is most noticeable when dealing
with suite configurations that contain tasks with many task outputs.

### Fixes

[#3308](https://github.com/cylc/cylc-flow/pull/3308) - fix a long-standing bug
Expand Down
3 changes: 1 addition & 2 deletions cylc/flow/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -1590,8 +1590,7 @@ def generate_taskdefs(self, orig_expr, left_nodes, right, seq):

# Record custom message outputs.
for item in self.cfg['runtime'][name]['outputs'].items():
if item not in taskdef.outputs:
taskdef.outputs.append(item)
taskdef.outputs.add(item)

def generate_triggers(self, lexpression, left_nodes, right, seq,
suicide, task_triggers):
Expand Down
2 changes: 1 addition & 1 deletion cylc/flow/taskdef.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ def __init__(self, name, rtcfg, run_mode, start_point, spawn_ahead):
self.expiration_offset = None
self.namespace_hierarchy = []
self.dependencies = {}
self.outputs = []
self.outputs = set()
self.param_var = {}
self.external_triggers = []
self.xtrig_labels = {} # {sequence: [labels]}
Expand Down