Skip to content

tri-state merge seems to always increase the number of nodes, sometimes substantially. #7

@cdkersey

Description

@cdkersey

Say we define a special mux like this:

  template <typename T> T Mux(bvec<10> sel, const vec<1024, T> &in) {
    bus<sz<T>::value> b;
    for (unsigned i = 0; i < 1024; ++i)
      b.connect(Flatten(in[i]), sel == Lit<10>(i));
    return b;
  }

and we build roms by attaching literals to the inputs. It becomes quite larger after tri-state merge, creating a network for all cases in which the bus will be driven 1 and another network for all cases in which the output will be driven 0. There should be some way to recognize these kinds of buses and leave them undisturbed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions