aboutsummaryrefslogtreecommitdiff
path: root/test/passes/expand-whens/reg-dwoc.fir
diff options
context:
space:
mode:
Diffstat (limited to 'test/passes/expand-whens/reg-dwoc.fir')
-rw-r--r--test/passes/expand-whens/reg-dwoc.fir21
1 files changed, 21 insertions, 0 deletions
diff --git a/test/passes/expand-whens/reg-dwoc.fir b/test/passes/expand-whens/reg-dwoc.fir
new file mode 100644
index 00000000..521e1710
--- /dev/null
+++ b/test/passes/expand-whens/reg-dwoc.fir
@@ -0,0 +1,21 @@
+; RUN: firrtl -i %s -o %s.flo -X flo -p c | tee %s.out | FileCheck %s
+circuit top :
+ module top :
+ wire p : UInt
+ p := UInt(1)
+ reg r : UInt
+ when p :
+ on-reset r := UInt(10)
+ r := UInt(20)
+
+; CHECK: Expand Whens
+
+; CHECK: circuit top :
+; CHECK: module top :
+; CHECK: wire p : UInt
+; CHECK: reg r : UInt
+; CHECK: p := UInt(1)
+; CHECK: when p : r := mux(reset, UInt(10), UInt(20))
+
+; CHECK: Finished Expand Whens
+