[Coco] Which version of C?

Gene Heskett gheskett at wdtv.com
Mon Jan 12 10:44:21 EST 2015


On Monday, January 12, 2015 05:08:39 AM K. Pruitt did opine
And Gene did reply:
> >> On Sunday, January 11, 2015 11:32:37 PM K. Pruitt did opine
> >> 
> >> And Gene did reply:
> >>> There seems to be a couple of different versions of C floating
> >>> around out there.  On a coco 3 with a 6809 running NitrOS9 level
> >>> 2, which version of C should I be running?
> >>> 
> >>> I remember not really caring for the first C that Tandy had for
> >>> OS9. And that was my first exposure to C so it kind of soured me
> >>> on C for a long time. I used Turbo C from Borland for a bit. That
> >>> was pretty fun. And I meddled with GCC a bit and it wasn't too
> >>> disastrous. So I am thinking maybe I'll give C on the Coco
> >>> another shot.
> >>> 
> >>> Thanks.
> >> 
> >> That Tandy C compiler, written my Microware, has a generally good
> >> code generator, but some of the support functions were broken. We
> >> now have a much better c.prep I had a hand in, and Willard Goosey
> >> has since improved even more, and that c.prep v19b should be
> >> considered as a total replacement for the tandy supplied version. 
> >> Several others have supplied additional translators and code
> >> optimizers.  If you want to feed it normal ansi C, with void's and
> >> such, then you will run the output of c.prep thru ansifront.13,
> >> which translates the voids to something the compiler in c.comp or
> >> the chained c.pass1 and c.pass2 can understand. Then we've an
> >> improved c.opt2, and your choice of driving scripts, there are
> >> several for sequencing the whole maryann.
> >> 
> >> But the best optimizer is the human brain. By interrupting the
> >> compiler and inspecting the assembly code as it would be sent to
> >> c.asm (or rma today) and spend some time looking for bit shift
> >> loops that shift by 8 one way or the other, nuke that code and sub
> >> a tfr, clear statement pair in its place. That is one of the
> >> tricks that took rzsz from just barely keeping up with a 2400 baud
> >> modem, aka 240 bytes a second to nearly 720 bytes a second running
> >> on a 6309. That, and changing to a table lookup crc which is much
> >> faster than calculating it.
> >> 
> >> Cheers, Gene Heskett
> > 
> > Wow, Gene, I almost understood about 80% of that.  I normally only
> > understand about half of what you're saying.  But I always flag your
> > messages as important because even understanding only half of what
> > you're talking about is like walking through a gold mine with
> > nuggets strewn about just waiting to be picked up.  Eventually I'll
> > understand even more of the gems you share here.  Thanks for doing
> > so.  I wrote an Xmodem CRC utility for OS-9 years ago and the math
> > was so extensive and honestly way above my head (polynomials?) and
> > that actually helped me understand your code optimization comments.
> > I'm still very fond of using tables instead of cycle-eating math
> > when I can.
> > 
> > By the way, my thanks also goes out to Robert Gault and a quite a
> > few others here for all the great help you guys share here.
> 
> Ah!  I had to consult Leventhal's book, but I now get what you're
> saying.  I don't think I've ever used the TFR instruction before. You
> can bet I'll be playing with it now.

The somewhat funny part of that was that before I started building rzsz 
for coco's, a fellow named Paul Jerkatis was trying to do it, and 
failing.

Our discussions about that got pretty heated because at that time I had 
taken Mathew Thompson's school project  of re-writing c.prep from v1.5 to 
v1.7 or v1.8 already. The MW version falls over silently when the size of 
the source code exceeds about 9k, building stuff that crashes. My 
enhanced version of Matthews code was good to a source code size of 
around 36k, and now Willard Goosey has worked on it some more.  But Paul 
refused to use the better tools so all he could do was make code that 
crashed. I finally talked him into sending me the sources, and I gave 
this group back working code of version 3.16 2 days later. Later versions 
I did, up to 3.36, contained those "improvements" and gained speed 
because of them. But because I succeeded where he, with a CS degree 
didn't, he bought a Sun workstation, left the group and never came back.  
Life was good. :) The Peter Principle confirmed yet again. ;)

No clue what Paul is doing now.  But one of the former members of this 
group, a fellow names Michael Sweet, who did an an os9 version of BRU 
that I subsequently fine tuned a bit but its basic method of doing a 
backup/recovery is so slow that with floppies it took a week to write 
about 100 720k floppies, and three weeks to recover, just what I had on 
my then Maxtor 7120s hard drive. That TBT is why I have not promoted its 
use.

Michael wrote cups, the common unix printing system, and just about 3 
years ago sold it all to apple and took the chair of the printing group 
at apple.  But he is still just Mike, I have exchanged messages with him 
just this past week. So several of our "alumni" have gone on to do bigger 
& better things. The FreeRadius server for all platforms, is Alan Dekok's 
for instance.

FWIW, I have only an 8th grade education, but the tested IQ of 147 some 
65+ years back is close to genius.  To restrict ones learning to a 
schoolroom environment is silly, and a waste of the mental powers given. 
School was something I didn't need as I could do my owen reading and 
learning, and still am at 80 yo. Poor short term memory is beginning to 
have its effects though, darnit. That results in increased use of the 
printers here as I print out something that is useful and go write code 
to use it.  Keeps me out of the bars don'tcha know. ;-)

Cheers, Gene Heskett
-- 
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
Genes Web page <http://geneslinuxbox.net:6309/gene>
US V Castleman, SCOTUS, Mar 2014 is grounds for Impeaching SCOTUS


More information about the Coco mailing list