Can RealView compiler generate SMLAL/UMLAL instructions?

Is there any way the RealView compiler can take advantage of the multiply-and-accumulate instructions of the Cortex M3?

I wrote a simple MAC loop and the compiler didn't generate any SMLAL or UMLAL instructions, which was disappointing.

Thanks,
Andrew Queisser
HP

Parents
  • When you use a High-Level Language (HLL) - any HLL - you delegate the choice of machine instructions to the compiler.

    If the use of specific machine instructions is important to you, then you should not be using an HLL - any HLL!

    While you might be happen to stumble upon some specific HLL construct that just happens to generate certain machine instructions under certain conditions, you cannot rely upon it to always continue to do so!
    You will always have to re-check the generated code to be sure.

    Therefore, if it really is important, write an assembler module to call from the HLL.

    See: http://www.keil.com/forum/17991/

Reply
  • When you use a High-Level Language (HLL) - any HLL - you delegate the choice of machine instructions to the compiler.

    If the use of specific machine instructions is important to you, then you should not be using an HLL - any HLL!

    While you might be happen to stumble upon some specific HLL construct that just happens to generate certain machine instructions under certain conditions, you cannot rely upon it to always continue to do so!
    You will always have to re-check the generated code to be sure.

    Therefore, if it really is important, write an assembler module to call from the HLL.

    See: http://www.keil.com/forum/17991/

Children
More questions in this forum