message: Skip duplication check for inserting control edges in ReplicatePerReplicaNodesInFunctionGraph pass.
  Duplication check in `Graph::AddControlEdge` is expensive for the dst node with a lot of input edges, as the implementation will iterate through all the input edges.
diff: @@ -98,7 +98,10 @@ class ReplicateHelper {
  Node* dst = edge->dst();
  if (edge->IsControlEdge()) {
  for (Node* replicated_node : src_replicated_nodes) {
  - graph->AddControlEdge(replicated_node, dst);
  + // Duplication check in `Graph::AddControlEdge` is expensive for the dst
  + // node with a lot of input edges. Here each (src, dst) pair will only
  + // occur once so it is safe to skip the duplication check.
  + graph->AddControlEdge(replicated_node, dst, /*allow_duplicates=*/true);
  }
  } else {
  const string& dst_device = dst->assigned_device_name();
  