Wednesday, June 13, 2007

I Will Break Your Unit Testes (tm)

How much does it cost to develop a debugger? I ran SLOC Count on the source tree of my ZeroBUGS debugger for Linux, which I have been developing single-handedly since 2003 (late Fall).

I have removed some of the third party components, such as libdwarf and Google's sparsehash, but I kept all experimental and support code (you can subtract the ansi C lines though, they represent some old tests).


SLOC Directory SLOC-by-Language (Sorted)
38470 plugin cpp=35578,asm=1485,python=1258,sh=149
26576 engine cpp=21091,sh=5409,ansic=76
12115 interp cpp=11475,yacc=450,lex=190
9300 zdk cpp=9300
9101 unmangle cpp=5402,ansic=3692,sh=7
8147 dwarfz cpp=8147
5592 typez cpp=5592
4648 stabz cpp=4648
4353 dharma cpp=4353
4289 zero_python cpp=4289
2967 elfz cpp=2967
2813 misc cpp=2093,python=629,ansic=91
2357 symbolz cpp=2357
2151 minielf cpp=2151
949 readline cpp=949
798 top_dir python=477,sh=237,ansic=84
376 tools python=296,sh=80
362 bench cpp=362
176 make sh=176
61 zrt cpp=61
0 docs (none)
0 help (none)


Totals grouped by language (dominant language first):
cpp: 120815 (89.10%)
sh: 6058 (4.47%)
ansic: 3943 (2.91%)
python: 2660 (1.96%)
asm: 1485 (1.10%)
yacc: 450 (0.33%)
lex: 190 (0.14%)


Total Physical Source Lines of Code (SLOC) = 135,601
Development Effort Estimate, Person-Years (Person-Months) = 34.67 (415.99)
(Basic COCOMO model, Person-Months = 2.4 * (KSLOC**1.05))
Schedule Estimate, Years (Months) = 2.06 (24.73)
(Basic COCOMO model, Months = 2.5 * (person-months**0.38))
Estimated Average Number of Developers (Effort/Schedule) = 16.82
Total Estimated Cost to Develop = $ 4,682,930
(average salary = $56,286/year, overhead = 2.40).
SLOCCount, Copyright (C) 2001-2004 David A. Wheeler
SLOCCount is Open Source Software/Free Software, licensed under the GNU GPL.
SLOCCount comes with ABSOLUTELY NO WARRANTY, and you are welcome to
redistribute it under certain conditions as specified by the GNU GPL license;
see the documentation for details.

I don't know what else to read into this, other than I am a badass.

You think that cowboy programming is bad?

I believe that agile is well suited for developers with small unit testes.

1 comment:

Max Lybbert said...

If I'm reading correctly, the important numbers are:

> Development Effort Estimate, Person-Years = 34.67
(I misread this originally as person-months)

> Schedule Estimate, Years = 2.06
> Estimated Average Number of Developers = 16.82

As for the $4 million figure, that includes "your" base salary of $56,286 times 2.4 for office supply costs, benefits costs, etc. But it must be nice to have a tool say that you, in your spare time, have implemented what a 17 developer team ought to be able to do in just under three years.