Do not detect fsm state registers with init attribute
authorClifford Wolf <clifford@clifford.at>
Mon, 21 Sep 2015 09:52:40 +0000 (11:52 +0200)
committerClifford Wolf <clifford@clifford.at>
Mon, 21 Sep 2015 09:54:00 +0000 (11:54 +0200)
passes/fsm/fsm_detect.cc

index fd0ae44b96aa0cf2e4680a1f2a94911830ecba45..740113e354ce07ae98dba5129c190d8d9afc6de2 100644 (file)
@@ -110,6 +110,8 @@ static bool check_state_users(RTLIL::SigSpec sig)
 
 static void detect_fsm(RTLIL::Wire *wire)
 {
+       if (wire->attributes.count("\\init") > 0)
+               return;
        if (wire->attributes.count("\\fsm_encoding") > 0 || wire->width <= 1)
                return;
        if (sig_at_port.check_any(assign_map(RTLIL::SigSpec(wire))))