delton@pro-carolina.cts.com (Don Elton) (03/13/89)
Larry Virden wrote that ORCA's Small C generates p code. Actually it will produce either 6502 native code or p code. Problem is though that the native code programs are a good bit larger and aren't much faster than p code anyway so for most applications p code makes more sense. Unlike the p code most of us are probably familiar with (such as used by Apple Pascal), the ORCA p code interpreter is relocatable by the linker so you can ORG your Small C programs anywhere in memory where they'll fit and the 'runtime' is just linked in and isn't really that big (actually it's smaller than the increase in size you get for using native code). Since the p codes are just indexes into a jump list to assembler routines your programs really perform pretty well under p code. The first releases of the SQueeze utilities I wrote were written in Small C and they eventually migrated to be mixes of Small C and Assembler and are currently 100% Assembler. The 6502 just isn't really cut out for native code compilers and there's lots of overhead in creating pseudo-stacks in software that kills the performance of them compared to native compilers for other CPU's such as the 65816 or Z-80 for example. UUCP: [ sdcsvax nosc ] !crash!pro-carolina!delton ARPA: crash!pro-carolina!delton@nosc.mil INET: delton@pro-carolina.cts.com Pro-Carolina: 803-776-3936 (300-2400 baud, login as 'register') US Mail: 3207 Berkeley Forest Drive, Columbia, SC 29209-4111
brianw@microsoft.UUCP (Brian Willoughby) (03/19/89)
In article <8903140616.AA16780@crash.cts.com>, delton@pro-carolina.cts.com (Don Elton) writes: > The 6502 just isn't really cut out for native code compilers and there's lots > of overhead in creating pseudo-stacks in software that kills the performance > of them compared to native compilers for other CPU's such as the 65816 or Z-80 > for example. > I agree (I have ORCA's Small C). So why isn't there a full C compiler that will take advantage of the 65C802 in my II+ ? Brian Willoughby microsoft!brianw@uunet.UU.NET or uw-beaver!microsoft!brianw or just microsoft!brianw