Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

STANDARD or EXTENDED edition of CC5X Compiler

Status
Not open for further replies.

petro_Mejia

Banned
Newbie level 4
Joined
Feb 11, 2012
Messages
6
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Visit site
Activity points
0
I ported one of my PIC-14 projects to few C Compilers & here are the results--

PICC(3.249) - ROM: 2492 Words, RAM: 91-114, Stack 7+1
WIZ-C(14) - ROM: 2444 Words, RAM: 123, Stack 6+1
HT-PIC(9.50 PL2)- ROM: 1959 Words, RAM: 113, Stack 5+2
CC5X(3.2N RED) - ROM: 1593 Words, RAM: 94, Stack 4+2

All the compilers were configured for maximum optimization level.
Though CC5X has some limitations like single dim array, simplified math expressions etc, it seems that when all other things are equal, CC5X is clearly a winner.
 
Last edited by a moderator:

I ported one of my PIC-14 projects to few C Compilers & here are the results--
All the compilers were configured for maximum optimization level.
Though CC5X has some limitations like single dim array, simplified math expressions etc, it seems that when all other things are equal, CC5X is clearly a winner.

I have ported a project to several compilers too, and found out the same. CC5X is clearly the winnner, even its free edition! Comparing the free edition with the test edition of CC5X, one finds out that the latter optimises even more. By studying the difference between the code generated by the two editions, one can find out what the most frequent extra instructions in the code generated by the free edition are. (These instructions are not present in the code generated by the test edition.)

Having found out what these instructions are and carefully studying the documentation, one can discover a method to improve the code generated by the free edition so that very few extra instructions remain. These can also be removed by studying the documentation further, and slightly changing the code in the respective places where these extra instructions are generated. So the code generated by the free edition can be made identical to the code generated by the test edition, and hence by the standard and extended editions!

The code generated by CC5X is so good that an assembly programmer could hardly code it better. So we owe huge thanks to Bengt Knudsen for making this marvelous compiler! :)
 
Last edited:
Even in December 2013 when the message was posted, Wiz-C was up to version 17.02 so perhaps a comparison with latest versions would be useful. Strange that Microchip's own XC8 compiler wasn't tested as well.

Brian.
 

Even in December 2013 when the message was posted, Wiz-C was up to version 17.02 so perhaps a comparison with latest versions would be useful. Strange that Microchip's own XC8 compiler wasn't tested as well.Brian.

As far as I remember, WIZ-C lacks a command-line compiler. Instead, the compiler is integrated with the GUI environment. I don't like this, so I didn't test it. Tests done by the original poster show that it doesn't optimise very well anyway. As to XC8, this is simply the new name of HI-TECH C, after Microchip bought it. :)
 

You can use WIZ-C from the CLI, it has it's own 'make' utility like most othe compilers. I find it easier to work from the GUI though, even if only to add the files to the project window without using the other GUI facilities. WIZ wins hands down when it comes to debugging, it's by far the fastest and most comprehensive debugger I've ever used. The new 'MX' version has even more debugging functionality but seems to be less user friendly in the GUI department.

XC8 is the replacement for Hi-TECH but has a number of significant differences, I'm not sure it would produce the same code as before, in fact even the different versions of XC8 seem to produce different code from each other!

Brian.
 

You can use WIZ-C from the CLI, it has it's own 'make' utility like most othe compilers.

Sorry, I didn't know that. I remember that I tested the free version and it didn't seem to have a command-line compiler. Perhaps only the professional version has one? The manual (http://www.fored.co.uk/html/Manual.pdf) mentions only it in Chapter 16 "Command Line interface" on page 152. Or maybe there is a single executable file which can work both with CLI and GUI?

XC8 is the replacement for Hi-TECH but has a number of significant differences, I'm not sure it would produce the same code as before, in fact even the different versions of XC8 seem to produce different code from each other!

That's true. I've tested XC8 and found out that it generates slightly larger code than the older HI-TECH C.
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top