openfpga/src/utils/pb_type_utils.cpp
/********************************************************************
 * This function will try to find an interconnect defined under a mode
 * of pb_type with a given name.
 * If not found, return null pointer
 *******************************************************************/
This function will try to find an interconnect defined under a mode
of pb_type with a given name.
If not found, return null pointer
This function will try to find an interconnect defined under a mode of pb_type with a given name . If not found return null pointer
t_interconnect* find_pb_mode_interconnect(t_mode* pb_mode, const char* interc_name) {
  for (int i = 0; i < pb_mode->num_interconnect; ++i) {
    if (std::string(interc_name) == std::string(pb_mode->interconnect[i].name)) {
      return &(pb_mode->interconnect[i]);
    }
  } 
  return nullptr;
}
t_interconnect * find_pb_mode_interconnect ( t_mode * pb_mode , const char * interc_name ) { for ( int i = 0 ; i < pb_mode -> num_interconnect ; ++ i ) { if ( std :: string ( interc_name ) == std :: string ( pb_mode -> interconnect [ i ] . name ) ) { return & ( pb_mode -> interconnect [ i ] ) ; } } return nullptr ; }
This function will try to find an interconnect defined under a mode
 of pb_type with a given name.
This function will try to find an interconnect defined under a mode of pb_type with a given name .
/* Reach here, it means we find nothing */