This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Cortex M3 compilers and benchmarks

Note: This was originally posted on 20th January 2009 at http://forums.arm.com

Please help me identify the best compiler for CortexM3.
I currently use armcc from ARM, but curious if that is the best option on the market. So far, I found a couple of options for Cortex M3 compilers: GCC, armcc (RVCT 3.1) and IAR. What I cannot find is the benchmarking results or comparison between those compilers. Are there any other notable compilers/linkers for Cortex M3 that I missed?
I am mainly interested in code density and run time efficiency of the compiled image.

Thank you in advance!

Andrey
Parents
  • Note: This was originally posted on 22nd January 2009 at http://forums.arm.com

    "GCC is free - and you get what you paid for" - I heard from some people.
    But this was just one opinion I got.
    Is that a common opinion that commercial compilers are generally better then
    GCC for ARM CPU's?

    Common, maybe. Whether or not it's justified, I don't know. GCC for ARM has improved dramatically over the last few years and its output now is pretty good.

    The other issue is the technical support side of things. For example, the technical support for commercial compilers tends to be quite good, and the documentation is usually very complete. When trying to use GCC in similar ways I tend to find myself scouring Google for a few hints that might point me at some obscure command line switch which isn't really explained anywhere. That is the problem with GCC (and most other open source projects, come to think of it).

    It is hard to give anything other than a vague answer, so I apologize for that. If you're really interested in getting the best out of your compiler, then write some benchmarks and actually test it with the kind of code and configurations that you will need to use.

    To be honest though, I doubt you'll see any significant improvement and you're probably best off just sticking with what you've got. RVCT is certainly a very good compiler suite, and it is certainly much easier to use than GCC just for its documentation. The biggest influence on a program's size and speed is the design of the software and the algorithms that you're using.

    I hope that's helpful,
    Jacob
Reply
  • Note: This was originally posted on 22nd January 2009 at http://forums.arm.com

    "GCC is free - and you get what you paid for" - I heard from some people.
    But this was just one opinion I got.
    Is that a common opinion that commercial compilers are generally better then
    GCC for ARM CPU's?

    Common, maybe. Whether or not it's justified, I don't know. GCC for ARM has improved dramatically over the last few years and its output now is pretty good.

    The other issue is the technical support side of things. For example, the technical support for commercial compilers tends to be quite good, and the documentation is usually very complete. When trying to use GCC in similar ways I tend to find myself scouring Google for a few hints that might point me at some obscure command line switch which isn't really explained anywhere. That is the problem with GCC (and most other open source projects, come to think of it).

    It is hard to give anything other than a vague answer, so I apologize for that. If you're really interested in getting the best out of your compiler, then write some benchmarks and actually test it with the kind of code and configurations that you will need to use.

    To be honest though, I doubt you'll see any significant improvement and you're probably best off just sticking with what you've got. RVCT is certainly a very good compiler suite, and it is certainly much easier to use than GCC just for its documentation. The biggest influence on a program's size and speed is the design of the software and the algorithms that you're using.

    I hope that's helpful,
    Jacob
Children
No data