Codegen always runs scheduling twice when pipelining
- Dominant language
- C++
- Stars
- 1.9k
- Forks
- 283
- Avg merge
- 2d 10h
- Merged PRs (30d)
- 135
Description
https://github.com/google/xls/blob/main/xls/scheduling/scheduling_pass_pipeline.cc
The compound pass for scheduling runs these sub-passes:
```
MutualExclusionPass
SimplificationPass
LiteralUncommoningPass
PipelineSchedulingPass
DeadCodeEliminationPass
MutualExclusionPass
DeadCodeEliminationPass
PipelineSchedulingPass
```
The second scheduling pass was added at commit 746c992be4d1429e374daa7e0fb0297e80138e0e with this comment:
> Mutual exclusion currently does not preserve the validity of the schedule,
since it adds nodes without specifying which cycle they go into. This change
causes mutual exclusion to erase the schedule, and adds a scheduling pass
after mutual exclusion in the scheduling pass pipeline.
The pipeline scheduling pass can potentially be runtime intensive, so if we can avoid rerunning it, that would help reduce runtime concerns.
FYI @ericastor
Contributor guide
Assessment
This issue has not been assessed yet.