Dynamic Memory Allocated in which memory in i.MX7 Wince


We are developing a c/c++ wince application program in Visual studio 8.0.
We have saved this application program in \Flash and run from there. This application is allocating memory dynamically(using calloc() ) of size 90MB.

I want to know the program allocates this memory in which memory area - on Flash or DDR3 RAM or i.MX7 Internal RAM ?

As our program frequently read and write data in this dynamically allocated area, how does it affect the endurance of memory area used ?

How does OS decide which memory area to use ?


All dynamic memory allocation use RAM, that for imx7 means the DDR RAM.
Flash is used to store the OS image, configuration (bootloader configuration and registry) and persistent filesystem. Inside Windows CE you write on flash every time you write into a permanent folder or save the registry.
Internal RAM is normally not accessible, is reserved for special uses (ex: using it for the M4 core or store data during suspend/resume).
DD3 RAM does not have a limited number of write cycles (as flash does), so allocating data there is perfectly safe.

Thanks for the response Valter.

You are welcome.