Out of curiosity, I wondered how small the PRO version of the XC8 compiler could make the code. ![]() So the headline so far is that CCS is 21% slower, takes up 4% more ROM and 38% more RAM than the free XC8 compiler! The free XC8 compiled code took 26329 clock cycles to configure CatTrack and run an encryption routine, whereas the CCS compiled code took 31849. I then thought that although the CCS code takes up more space, perhaps it’s compiled for speed rather than space? To cut a long story short – no, it isn’t. It appears that the free version of the XC8 compiler is creating more efficient code than the paid-for CCS compiler! Ignore the references to the PRO licence above – it was compiled in Free mode. ![]() So now the moment of truth, let’s see the Memory usage when using the free version of the XC8 compiler: It took a few hours of work to plough through the code and make all the necessary changes required to convert from CCS to XC8. This is what the Memory usage currently looks like in the PIC16LF18345, compiled with CCS C: ![]() I did begin to wonder though, just how much bigger would my code be, and how much slower would it run if I used the free version of Microchip’s XC8 compiler? As I previously mentioned, I am using the CCS C compiler, basically because the ‘paid for’ version of their compiler is significantly cheaper than Microchip’s XC8 ‘paid-for’ version. Now that I’ve got CatTrack working, I’ve been having a look at refining the code.
0 Comments
Leave a Reply. |