Other Parts Discussed in Thread: SYSBIOS
Hi,
I have questions about MAR configuration. I`m running OpenMP runtime (delivered from ProcSDK release 03.03.00) on C6678 EVM. It works fine, but I need to confirm MAR configuration.
It seems MAR12 is configured as 0x0000000D by default. When I use OpenMP runtime, MAR12 is configured as 0x0000000B before reaching to main() function.
About MAR configuration. Please take a look at
4.4.5 Memory Attribute Register (MARn) Definition
It says bit1 and 2 of MAR is reserved. If you see the configuration of 0x0000000B, that means OpenMP runtime sets MAR12 bit0 for enabling cache, bit1 for some unknown purposes, and bit3 for enabling prefetch.
Why does OpenMP set MAR12 bit1 even if this is reserved.
Also, I noticed we should not get MAR12 configured as prefechable. Please take a look at
Advisory 28 Read Exception and Data Corruption Issue
So now I`m wondering if we should configure MAR12 as 0x00000003 rather than 0x0000000B. Do you have any comment on this ? FYI, I tried to override MAR12 configuration at the beginning of main() (like below) and found it still worked for my OpenMP app.
marVal = Cache_getMar((Ptr)0x0c020000); marVal &= ~(1 << 3); Cache_wbInvAll(); Cache_setMar((Ptr)0x0c020000, 0x003e0000, marVal);
Best Regards,
Naoki