GHC code size
Hécate
hecate at glitchbra.in
Fri Jun 10 16:43:42 UTC 2022
If you don't have a nix shell handy, here is what I'm getting:
❯ cloc compiler rts driver
1148 text files.
1137 unique files.
108 files ignored.
github.com/AlDanial/cloc v 1.88 T=1.31 s (794.3 files/s, 431269.4 lines/s)
---------------------------------------------------------------------------------------
Language files blank
comment code
---------------------------------------------------------------------------------------
Haskell 635 68541 140216
231567
C 158 10529 16953
51162
C/C++ Header 209 4329 8984
14536
yacc 2 971 10 5024
Logos 3 530 0 3642
Pascal 1 661 936 2312
make 14 252 409 850
Windows Module Definition 7 27 0 489
Assembly 5 76 269 478
Puppet 1 106 0 445
Python 1 32 19 162
D 1 16 42 60
YAML 1 6 10 18
Lisp 1 2 4 7
Windows Resource File 1 0 0 1
---------------------------------------------------------------------------------------
SUM: 1040 86078 167852
310753
---------------------------------------------------------------------------------------
Le 10/06/2022 à 18:29, chessai a écrit :
> You might be able to do something with cloc and a shell script for a
> rough estimate.
>
> ```
> $ cd ghc
> $ nix-shell -p clock --run "cloc ."
> ```
>
> will output a detailed report of the loc and language breakdown of the
> top level ghc directory (it is comment-aware and aware of many
> languages). there might be a way to get cloc or a similar tool to
> output something more inspect able (eg json), and then use a shell
> script to gather everything from the appropriate directories/files.
>
> I suspect something could be hacked up in less than a day, but it
> would require a bit of research. Hopefully this is helpful and gets
> you going - I'd be happy to hear of better solutions.
>
> Thanks
>
> On Fri, Jun 10, 2022, 11:20 Simon Peyton Jones
> <simon.peytonjones at gmail.com> wrote:
>
> Dear GHC devs
>
> Is it possible to get a "lines-of-code" summary of GHC these
> days? Like the one below, from 2011.
>
> It needs more than `wc` because it's helpful to split lines of
> code from lines of comments and notes.
>
> We used to have `count_lines` but I'm not sure whether it is still
> extant.
>
> I'm giving a talk at Zurihac on Sunday morning, about the
> internals of GHC. Any data before then, preferably in a form
> comparable to that below, would be terrific.
>
> But you have a lot else to do. This isn't do-or-die, just nice to
> have.
>
> Thanks
>
> Simon
>
> image.png
>
> _______________________________________________
> ghc-devs mailing list
> ghc-devs at haskell.org
> http://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-devs
>
>
> _______________________________________________
> ghc-devs mailing list
> ghc-devs at haskell.org
> http://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-devs
--
Hécate ✨
🐦: @TechnoEmpress
IRC: Hecate
WWW:https://glitchbra.in
RUN: BSD
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-devs/attachments/20220610/f70f5ed9/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image.png
Type: image/png
Size: 336143 bytes
Desc: not available
URL: <http://mail.haskell.org/pipermail/ghc-devs/attachments/20220610/f70f5ed9/attachment-0001.png>
More information about the ghc-devs
mailing list