diff options
author | gatecat <gatecat@ds0.me> | 2021-02-25 10:22:45 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-02-25 10:22:45 +0000 |
commit | ab8dfcfba4544c6733d074b24b0529d431b66d29 (patch) | |
tree | af212992fee7cd0a8fb27d19d0137587402fdc1b /common/exclusive_state_groups.impl.h | |
parent | e2cdaa653c805f9bfb6f0ab36295858e5dd3179d (diff) | |
parent | a30043c8da1b1cc46a2dcfb90aa3a06d4f4ed4e9 (diff) | |
download | nextpnr-ab8dfcfba4544c6733d074b24b0529d431b66d29.tar.gz nextpnr-ab8dfcfba4544c6733d074b24b0529d431b66d29.tar.bz2 nextpnr-ab8dfcfba4544c6733d074b24b0529d431b66d29.zip |
Merge pull request #591 from litghost/add_constant_network
Add constant network support to FPGA interchange arch
Diffstat (limited to 'common/exclusive_state_groups.impl.h')
-rw-r--r-- | common/exclusive_state_groups.impl.h | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/common/exclusive_state_groups.impl.h b/common/exclusive_state_groups.impl.h index 864e16c6..9946e9a6 100644 --- a/common/exclusive_state_groups.impl.h +++ b/common/exclusive_state_groups.impl.h @@ -40,14 +40,14 @@ void ExclusiveStateGroup<StateCount, StateType, CountType>::print_debug(const Co log_info("%s.%s is currently unselected\n", object.c_str(ctx), definition.prefix.c_str(ctx)); } else if (state >= 0) { log_info("%s.%s = %s, count = %d\n", object.c_str(ctx), definition.prefix.c_str(ctx), - definition.states[state].c_str(ctx), count[state]); + definition.states.at(state).c_str(ctx), count[state]); } else { NPNR_ASSERT(state == kOverConstrained); log_info("%s.%s is currently overconstrained, states selected:\n", object.c_str(ctx), definition.prefix.c_str(ctx)); for (size_t i = 0; i < definition.states.size(); ++i) { if (selected_states[i]) { - log_info(" - %s, count = %d\n", definition.states[i].c_str(ctx), count[i]); + log_info(" - %s, count = %d\n", definition.states.at(i).c_str(ctx), count[i]); } } } @@ -62,9 +62,9 @@ void ExclusiveStateGroup<StateCount, StateType, CountType>::explain_implies(cons log_info("Placing cell %s at bel %s does not violate %s.%s\n", cell.c_str(ctx), ctx->nameOfBel(bel), object.c_str(ctx), definition.prefix.c_str(ctx)); } else { - NPNR_ASSERT(next_state < definition.states.size()); - log_info("Placing cell %s at bel %s does violates %s.%s.\n", cell.c_str(ctx), ctx->nameOfBel(bel), - object.c_str(ctx), definition.prefix.c_str(ctx)); + log_info("Placing cell %s at bel %s does violates %s.%s, desired state = %s.\n", cell.c_str(ctx), + ctx->nameOfBel(bel), object.c_str(ctx), definition.prefix.c_str(ctx), + definition.states.at(next_state).c_str(ctx)); print_debug(ctx, object, definition); } } @@ -83,11 +83,10 @@ void ExclusiveStateGroup<StateCount, StateType, CountType>::explain_requires(con log_info("Placing cell %s at bel %s does violates %s.%s, because current state is %s, constraint requires one " "of:\n", cell.c_str(ctx), ctx->nameOfBel(bel), object.c_str(ctx), definition.prefix.c_str(ctx), - definition.states[state].c_str(ctx)); + definition.states.at(state).c_str(ctx)); for (const auto required_state : state_range) { - NPNR_ASSERT(required_state < definition.states.size()); - log_info(" - %s\n", definition.states[required_state].c_str(ctx)); + log_info(" - %s\n", definition.states.at(required_state).c_str(ctx)); } print_debug(ctx, object, definition); } |