C
Chris Torek
Well I guess it depends how you count them: by implementations or by
programming seats.
There are other ways to count as well (e.g., "number of binaries
used" or "number of invocations of binaries generated"), although
your two here are probably the best. Of course, if you are going
to count "total implementations", you also have to pin down whether
to count implementations that were never used in any sort of
production capacity, such as student projects in compiler classes,
or alpha and/or beta releases of commercial compilers.
I havent done a marketing survey, but just by weighing the questions
on the internet, I suspect the ones I've listed above cover at
least 80% of the seats. Just gcc and Microsoft Visual C prolly
cover 75%.
Here at Wind River, we would hope that Diab gets a few more.
On another note: while we are mentioning ancient, strange
implementations, there is one I am curious about, and another I
will mention.
I never used this first one myself: Leor Zolman's "BDS C" for CP/M.
A friend of mine had it and used it, but I never asked whether it
had an equivalent of a "bss" section. (I would be unsurprised
whether it had it or not.)
Whitesmiths C for the Z80 (also CP/M): this one was particularly
obnoxious in that there was no "uninitialized global data". If
you compiled, e.g.:
bar.c: int global; f() { global = 2; }
main.c: main() { f(); exit(0); }
you would get an "undefined symbol" error at link-time for "global".
You had to explicitly initialize "global" to 0, which of course
put it in the data segment.
(I remmber this problem because it was so aggravating. It took me
hours, maybe even a whole day, to figure out why certain globals
were "undefined" and others were not. The documentation said that
the compiler used the def/ref model, so I had carefully written
the code this way, rather than relying on the Unix-style "common"
model, and yet it still did not link. The documentation simply
failed to mention that a "def" was not a "def" unless it was
initialized! The "extern" keyword was simply ignored.)