The SDRAM is located at 0x80000000 and is configured thus:
/* Region 7 setting: Memory with Normal type, not shareable, outer/inner write back */
MPU->RBAR = ARM_MPU_RBAR(7, 0x80000000U);
MPU->RASR = ARM_MPU_RASR(0, ARM_MPU_AP_FULL, 0, 0, 1, 1, 0, ARM_MPU_REGION_SIZE_32MB);
This has the same settings as the ITCM, DTCM and OCRAM, which are configured thus:
I thought my problem might be eXecute Never related, as this is meant to be supported from ARM v6 onwards, but the header "mpu_armv7.h" I am using does not seem to cater for XN in the ARM_MPU_RASR macro (though the header "mpu_armv8.h" does, though operates differently in that it seems to do it all in ARM_MPU_RBAR).
I have managed to get the code I am benchmarking into SDRAM, but have to use the following pragma coupled with an ICF file "place" directive.
#pragma default_function_attributes = @ "BENCHMARKS"
So, this isn't really holding me up any more, but it would still be nice to understand why the problem occurs.