Benjamin Schubert pushed to branch bschubert/optimize-sort at BuildStream / buildstream
Commits:
-
b2aa707e
by Benjamin Schubert at 2019-01-30T14:10:36Z
1 changed file:
Changes:
... | ... | @@ -152,7 +152,7 @@ class Loader(): |
152 | 152 |
profile_start(Topics.SORT_DEPENDENCIES, target)
|
153 | 153 |
junction, name, loader = self._parse_name(target, rewritable, ticker,
|
154 | 154 |
fetch_subprojects=fetch_subprojects)
|
155 |
- loader._sort_dependencies(name)
|
|
155 |
+ #loader._sort_dependencies(name)
|
|
156 | 156 |
profile_end(Topics.SORT_DEPENDENCIES, target)
|
157 | 157 |
# Finally, wrap what we have into LoadElements and return the target
|
158 | 158 |
#
|
... | ... | @@ -273,15 +273,6 @@ class Loader(): |
273 | 273 |
self._elements[filename] = element
|
274 | 274 |
|
275 | 275 |
def sort_deps(dep_a, dep_b):
|
276 |
- if dep_a.index is not None:
|
|
277 |
- if dep_b.index is not None:
|
|
278 |
- return dep_a - dep_b
|
|
279 |
- else:
|
|
280 |
- return -1
|
|
281 |
- |
|
282 |
- if dep_b.index is not None:
|
|
283 |
- return 1
|
|
284 |
- |
|
285 | 276 |
if dep_a.dep_type != dep_b.dep_type:
|
286 | 277 |
if dep_a.dep_type == Symbol.RUNTIME:
|
287 | 278 |
return 1
|