tensorflow / networking
Unit Size

The distribution of size of units (measured in lines of code).

Intro
  • Unit size measurements show the distribution of size of units of code (methods, functions...).
  • Units are classified in four categories based on their size (lines of code): 1-20 (small units), 20-50 (medium size units), 51-100 (long units), 101+ (very long units).
  • You should aim at keeping units small (< 20 lines). Long units may become "bloaters", code that have increased to such gargantuan proportions that they are hard to work with.
Learn more...
Unit Size Overall
  • There are 409 units with 5,662 lines of code in units (59.1% of code).
    • 5 very long units (591 lines of code)
    • 20 long units (1,358 lines of code)
    • 48 medium size units (1,568 lines of code)
    • 63 small units (923 lines of code)
    • 273 very small units (1,222 lines of code)
10% | 23% | 27% | 16% | 21%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
cc11% | 23% | 27% | 16% | 19%
h0% | 33% | 25% | 4% | 36%
py0% | 16% | 26% | 17% | 40%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
tensorflow_networking/mpi_collectives33% | 25% | 11% | 9% | 19%
tensorflow_networking/mpi_collectives/kernels37% | 28% | 12% | 6% | 14%
tensorflow_networking/gdr14% | 40% | 30% | 4% | 11%
tensorflow_networking/seastar0% | 19% | 26% | 20% | 33%
tensorflow_networking/verbs0% | 13% | 44% | 27% | 14%
tensorflow_networking/mpi0% | 48% | 8% | 9% | 32%
ROOT0% | 22% | 37% | 12% | 27%
tensorflow_networking/mpi_collectives/python0% | 0% | 0% | 0% | 100%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
void BackgroundThreadLoop()
in tensorflow_networking/mpi_collectives/mpi_ops.cc
140 19 0
void BackgroundThreadLoop()
in tensorflow_networking/mpi_collectives/kernels/mpi_ops.cc
140 19 0
MPIResponse ConstructMPIResponse()
in tensorflow_networking/mpi_collectives/mpi_ops.cc
104 19 2
MPIResponse ConstructMPIResponse()
in tensorflow_networking/mpi_collectives/kernels/mpi_ops.cc
104 19 2
void GdrMemoryManager::TensorFromTransportOptions()
in tensorflow_networking/gdr/gdr_memory_manager.cc
103 18 6
void InitSeastarClientTag()
in tensorflow_networking/seastar/seastar_client_tag.cc
96 8 5
void MPIRendezvousMgr::AddRequest()
in tensorflow_networking/mpi/mpi_rendezvous_mgr.cc
88 10 2
void GdrWorker::GrpcRecvTensorAsync()
in tensorflow_networking/gdr/gdr_worker.cc
83 12 4
void GdrMemoryManager::Run()
in tensorflow_networking/gdr/gdr_memory_manager.cc
83 19 0
void RdmaAdapter::Process_CQ()
in tensorflow_networking/verbs/rdma.cc
81 14 0
void PerformCollectiveOp()
in tensorflow_networking/mpi_collectives/mpi_ops.cc
80 19 2
void PerformCollectiveOp()
in tensorflow_networking/mpi_collectives/kernels/mpi_ops.cc
80 19 2
seastar::future SeastarClient::Connection::Read()
in tensorflow_networking/seastar/seastar_client.cc
73 14 0
Status GdrMemoryManager::Init()
in tensorflow_networking/gdr/gdr_memory_manager.cc
71 8 0
void MPIRemoteRendezvous::RecvFromRemoteAsync()
in tensorflow_networking/mpi/mpi_rendezvous_mgr.cc
65 4 3
void RdmaMgr::SetupChannels()
in tensorflow_networking/verbs/rdma_mgr.cc
64 7 0
void RdmaTensorResponse::RecvHandler()
in tensorflow_networking/verbs/rdma.cc
60 9 5
void SeastarWorker::RecvTensorAsync()
in tensorflow_networking/seastar/seastar_worker_service.cc
60 8 4
void ComputeAsync()
in tensorflow_networking/mpi_collectives/mpi_ops.cc
54 6 2
void ComputeAsync()
in tensorflow_networking/mpi_collectives/kernels/mpi_ops.cc
54 6 2