ARM_CM7 Instruction set present ARM_CM4F core, which leads to Hard Fault Exception/ reset of the controller

Hi Team,

We are working on an application in which we are using the NXP S32146 Evaluation board to integrate the FreeRTOS into our application.

We have integrated the whole folder structure into out software stack. The problem arises at line #57 of the core file port.asm (stmdb r0!, {r4-r11, r14}), #77 (ldmia r0!, {r4-r11, r14}).

The hardware supports ARM_CM4F but the instruction set used in the file mentioned above relates to ARM_CM7 which causes a problem.

To proceed further with my implementation I have changed the core from ARM_CM4F to ARM_CM3 the issue is resolved, but going further the application demands FPU, but VFP instruction is not supported by ARM_CM3. Can you please suggest an solution for the same

Version of the FreeRTOS port used is FreeRTOS Kernel V10.2.1.


There is no difference between the Cortex-M4F port and the Cortex-M7 port. You don’t show the compiler warnings or errors, but I would be 95% confident your issue is either:

  1. caused by incorrect command line options being passed to the compiler if this is the Cortex-M4 core of that part. If you don’t tell the compiler the device has a floating point unit then the assembler will output errors around those lines (but not on those lines, which should be in both the M3 and M4F ports).

  2. caused by building the wrong source files if this is the Cortex-M0 core of that part, as the M0 does not have instructions to access the high registers in that way.