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

Reimplement static-timing pass. #909

Merged
merged 52 commits into from
Feb 22, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
52 commits
Select commit Hold shift + click to select a range
140a277
Add in TopDownStaticTiming and start on calculate_states.
mikeurbach Feb 3, 2022
932ab5e
Make calculate_states return a result and add If handling.
mikeurbach Feb 3, 2022
326affc
Add another static test.
mikeurbach Feb 3, 2022
56a44e1
Add realize_schedule function starting with enables.
mikeurbach Feb 3, 2022
bf066f0
Add If guard condition to enables.
mikeurbach Feb 3, 2022
47fd904
Switch to returning a vector of predecessor edges.
mikeurbach Feb 3, 2022
8ef011b
Add transitions for seq, if, and enable.
mikeurbach Feb 3, 2022
b96fa69
Rework sequential transitions.
mikeurbach Feb 8, 2022
e6ed617
And the pre_guard with the port_guard in if_calculate_states.
mikeurbach Feb 8, 2022
9fb704a
Rework parallel transitions.
mikeurbach Feb 8, 2022
9ad95c2
Move helper down below.
mikeurbach Feb 8, 2022
f5d4e8e
Ensure every node in the schedule has a static timing.
mikeurbach Feb 8, 2022
21bb092
Flesh out realize_schedule to build transitions.
mikeurbach Feb 8, 2022
d833743
Reset tests, and re-enable correctness static tests.
mikeurbach Feb 9, 2022
e963d01
Add dump_fsm flag to control schedule display.
mikeurbach Feb 9, 2022
44ada5d
Use ? operator instead of match.
mikeurbach Feb 9, 2022
c4ee4cd
Spruce up dumping FSM.
mikeurbach Feb 10, 2022
d38daa4
Enable static-timing tests like tdcc tests.
mikeurbach Feb 10, 2022
740138d
Muck with schedule display more; Fix edge case in par handling.
mikeurbach Feb 10, 2022
1332939
asdf
mikeurbach Feb 10, 2022
057ddde
Enable static par test.
mikeurbach Feb 10, 2022
c441b7d
Enable static if test.
mikeurbach Feb 10, 2022
7818e9b
Remove static requirement for everything but enable.
mikeurbach Feb 10, 2022
8f92a87
Add while_calculate_states.
mikeurbach Feb 11, 2022
43b8c22
Make transition order deterministic in tests.
mikeurbach Feb 11, 2022
58d77c9
Make absence of static timing error; proceed on error.
mikeurbach Feb 11, 2022
62bffe0
clippy warnings
rachitnigam Feb 14, 2022
cb069dc
and_then for chained comparison
rachitnigam Feb 14, 2022
3a0ff8f
better error on unexpected control
rachitnigam Feb 14, 2022
6124a1e
Special case FSM comparision when lower bound is 0.
mikeurbach Feb 16, 2022
0ae82b9
Merge branch 'master' into top-down-st
mikeurbach Feb 16, 2022
d30288f
Disable infer-static-timing for correctness dynamic tests.
mikeurbach Feb 16, 2022
6ae1beb
Make static-timing tests pure unit tests of top-down-st pass.
mikeurbach Feb 16, 2022
9c472b1
Disable top-down-st for tdcc tests.
mikeurbach Feb 16, 2022
e76f6d7
Disable top-down-st for more test suites.
mikeurbach Feb 16, 2022
bc22ce9
Use start_* methods and rely on top-down @static annotations.
mikeurbach Feb 18, 2022
186031b
Merge branch 'master' into top-down-st
mikeurbach Feb 18, 2022
69450ca
Disable static timing for exp correctness tests.
mikeurbach Feb 18, 2022
f1c38ea
propagate error instead of unwrapping
rachitnigam Feb 20, 2022
1db5506
use icarus in flag compare
rachitnigam Feb 20, 2022
4693544
Put back interpreter.data in flag-compare.sh.
mikeurbach Feb 20, 2022
87d144a
Merge branch 'master' into top-down-st
mikeurbach Feb 20, 2022
32248bd
Disable for NTT, now that we know it's correct.
mikeurbach Feb 20, 2022
04d7d29
use get_opts to compute CLI options
rachitnigam Feb 21, 2022
4bdbee8
doc comment
rachitnigam Feb 21, 2022
bc45438
position in error message
rachitnigam Feb 21, 2022
4d34ef9
more source positions
rachitnigam Feb 21, 2022
3be9080
define state calculation methods on Schedule struct
rachitnigam Feb 21, 2022
ebe100f
Compile while statically when bound is present.
mikeurbach Feb 21, 2022
546caa0
Update expected cycles rather than disabling top-down-st.
mikeurbach Feb 21, 2022
0aab14a
Merge branch 'master' into top-down-st
mikeurbach Feb 21, 2022
806abab
Check while for bound as well.
mikeurbach Feb 21, 2022
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
10 changes: 8 additions & 2 deletions calyx/src/default_passes.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ use crate::passes::{
InferStaticTiming, LowerGuards, MergeAssign, MinimizeRegs, Papercut,
ParToSeq, RegisterUnsharing, RemoveCombGroups, ResetInsertion,
ResourceSharing, SimplifyGuards, SynthesisPapercut, TopDownCompileControl,
WellFormed, WireInliner,
TopDownStaticTiming, WellFormed, WireInliner,
};
use crate::{
errors::CalyxResult, ir::traversal::Named, pass_manager::PassManager,
Expand Down Expand Up @@ -36,6 +36,7 @@ impl PassManager {
// Compilation passes
pm.register_pass::<CompileInvoke>()?;
pm.register_pass::<RemoveCombGroups>()?;
pm.register_pass::<TopDownStaticTiming>()?;
pm.register_pass::<TopDownCompileControl>()?;

// Lowering passes
Expand Down Expand Up @@ -76,7 +77,12 @@ impl PassManager {
register_alias!(
pm,
"compile",
[CompileInvoke, CompileEmpty, TopDownCompileControl]
[
CompileInvoke,
CompileEmpty,
TopDownStaticTiming,
TopDownCompileControl
]
);
register_alias!(
pm,
Expand Down
2 changes: 2 additions & 0 deletions calyx/src/passes/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ mod sharing_components;
mod simplify_guards;
mod synthesis_papercut;
mod top_down_compile_control;
mod top_down_static_timing;
mod well_formed;
mod wire_inliner;

Expand Down Expand Up @@ -59,5 +60,6 @@ pub use sharing_components::ShareComponents;
pub use simplify_guards::SimplifyGuards;
pub use synthesis_papercut::SynthesisPapercut;
pub use top_down_compile_control::TopDownCompileControl;
pub use top_down_static_timing::TopDownStaticTiming;
pub use well_formed::WellFormed;
pub use wire_inliner::WireInliner;
Loading