-
Bug
-
Resolution: Cannot Reproduce
-
Not Prioritized
-
Code Generation Tools
-
CODEGEN-11609
-
C2000_22.6.0.LTS
-
default
-
The attached file has these lines ...
__attribute__((far)) volatile tsVar Global; ... Global.var = (tsArray) { .array = {0, 1, 2, 3, 4} };
Build it, then search the assembly code for the instruction PREAD.
$ cl2000 -s -o --unified_memory file.c $ findstr PREAD file.asm || PREAD *XAR4++,*XAR7 ; [CPU_ALU] |19| || PREAD *XAR4++,*XAR7 ; [CPU_ALU] |19|
The compiler manual states a volatile far data object like Global should not be accessed with the instructions like PREAD, even if --unified_memory is used.