cancel
Showing results for 
Search instead for 
Did you mean: 

Code running slow on M4 CPU of a STM32H747 DISCO board

Ss.9
Associate II

I'm using a STM32H747 DISCO boad and I just want to use the M4 CPU. When start, the M7 configs the Clock and does nothing since then. There is only a simple case running on the M4 CPU. The case takes 200ms on M4 while it took only 20ms on a Risc-v@300Mhz CPU.

I use the "-O2" and hardfloat during compiling. But I have no idea what should I do next.

Any Ideas?

The codes are arrays multiply operation with data of float type.

1 ACCEPTED SOLUTION

Accepted Solutions

Turns out I was using the AXISRAM implicitly allocated to M7. Now It is much faster. But The Dhrystone is 0.37 DMIPS/MHz, which is still not a good number for me. The CPU clock is 200Mhz and ahb is the same.

View solution in original post

3 REPLIES 3
KnarfB
Principal III

Are you sure that the compiler uses hard fp and issues floating point instructions? M4 is single precision only? What is the M4 clock?

Turns out I was using the AXISRAM implicitly allocated to M7. Now It is much faster. But The Dhrystone is 0.37 DMIPS/MHz, which is still not a good number for me. The CPU clock is 200Mhz and ahb is the same.

Piranha
Chief II

For M4 core to run at decent speeds from the FLASH, one has to enable the ART.