openfpga/src/tile_direct/build_tile_direct.cpp
/***************************************************************************************
 * Top-level functions that build the point-to-point direct connections
 * between tiles (programmable blocks) 
 ***************************************************************************************/
Top-level functions that build the point-to-point direct connections
between tiles (programmable blocks)
Top - level functions that build the point - to - point direct connections between tiles ( programmable blocks )
TileDirect build_device_tile_direct(const DeviceContext& device_ctx,
                                    const ArchDirect& arch_direct,
                                    const bool& verbose) {
  vtr::ScopedStartFinishTimer timer("Build the annotation about direct connection between tiles");
  TileDirect tile_direct;
  for (int idirect = 0; idirect < device_ctx.arch->num_directs; ++idirect) {
    ArchDirectId arch_direct_id = arch_direct.direct(std::string(device_ctx.arch->Directs[idirect].name));
    if (ArchDirectId::INVALID() == arch_direct_id) {
      VTR_LOG_ERROR("Unable to find an annotation in openfpga architecture XML for <direct> '%s'!\n",
                    device_ctx.arch->Directs[idirect].name);
      exit(1);
    }
    build_inner_column_row_tile_direct(tile_direct,
                                       device_ctx.arch->Directs[idirect],
                                       device_ctx,
                                       arch_direct_id,
                                       verbose);
    build_inter_column_row_tile_direct(tile_direct,
                                       device_ctx.arch->Directs[idirect],
                                       device_ctx,
                                       arch_direct,
                                       arch_direct_id,
                                       verbose);
  } 
  VTR_LOG("Built %lu tile-to-tile direct connections\n",
          std::distance(tile_direct.directs().begin(), tile_direct.directs().end()));
  return tile_direct;
}
TileDirect build_device_tile_direct ( const DeviceContext & device_ctx , const ArchDirect & arch_direct , const bool & verbose ) { vtr :: ScopedStartFinishTimer timer ( " " ) ; TileDirect tile_direct ; for ( int idirect = 0 ; idirect < device_ctx . arch -> num_directs ; ++ idirect ) { ArchDirectId arch_direct_id = arch_direct . direct ( std :: string ( device_ctx . arch -> Directs [ idirect ] . name ) ) ; if ( ArchDirectId :: INVALID ( ) == arch_direct_id ) { VTR_LOG_ERROR ( " \n " , device_ctx . arch -> Directs [ idirect ] . name ) ; exit ( 1 ) ; } build_inner_column_row_tile_direct ( tile_direct , device_ctx . arch -> Directs [ idirect ] , device_ctx , arch_direct_id , verbose ) ; build_inter_column_row_tile_direct ( tile_direct , device_ctx . arch -> Directs [ idirect ] , device_ctx , arch_direct , arch_direct_id , verbose ) ; } VTR_LOG ( " \n " , std :: distance ( tile_direct . directs ( ) . begin ( ) , tile_direct . directs ( ) . end ( ) ) ) ; return tile_direct ; }
Top-level functions that build the point-to-point direct connections
 between tiles (programmable blocks)
Top - level functions that build the point - to - point direct connections between tiles ( programmable blocks )
/* Walk through each direct definition in the VPR arch */ /* Build from original VPR arch definition */ /* Build from OpenFPGA arch definition */