Using the HiTech compiler this gave a total of 263 words, of which 19 are used for ram initialisation etc. giving 244 words of ROM and 12 bytes of RAM. Six words more ROM and one word less RAM, pretty close I think. The ASM list file is a bit messy (and long). Do any of you hitech users know if it's possible to just get an assembly listing without all the C code in it? I'll post it if you want though. BTW there's an unused variable Local4 in the TestIf function. Regards Mike Rigby-Jones > -----Original Message----- > From: anders.widgren@gewab.se [SMTP:anders.widgren@gewab.se] > Sent: Monday, June 07, 1999 10:09 AM > To: PICLIST@MITVMA.MIT.EDU > Subject: RE: "New" optimizing PIC C-compiler: > > >Anders made sweeping claims. I would also like to see an example of his > research findings. > >So, how about it, Anders? Let's have a look and see... > >Friendly Regards /"\ > >Tjaart van der Walt X ASCII RIBBON CAMPAIGN > > The last time I did a more serious comparison between PIC C-compilers was > in 1995. The problem was to come up with code that would work under > several of these rather simple C-compilers. It would be much more > interesting to use code from an actual "typical" project. I might do > something like that during the summer. The code below compiled by CC5X for > a 16C67 device resulted in 238 instructions and 13 RAM bytes. How much > code does your compiler generate for the same code? Of course, in a real > project I would probably use a look-up table instead of a case structure. > (CC5X has a skip() instructions that automatically generates checked > look-up tables.) > > -AW >